1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py 2 ; RUN: llc < %s -mtriple=i686-unknown-unknown -print-schedule -mcpu=i686 | FileCheck %s --check-prefix=CHECK --check-prefix=GENERIC 3 ; RUN: llc < %s -mtriple=i686-unknown-unknown -print-schedule -mcpu=atom | FileCheck %s --check-prefix=CHECK --check-prefix=ATOM 4 ; RUN: llc < %s -mtriple=i686-unknown-unknown -print-schedule -mcpu=slm | FileCheck %s --check-prefix=CHECK --check-prefix=SLM 5 ; RUN: llc < %s -mtriple=i686-unknown-unknown -print-schedule -mcpu=sandybridge | FileCheck %s --check-prefix=CHECK --check-prefix=SANDY 6 ; RUN: llc < %s -mtriple=i686-unknown-unknown -print-schedule -mcpu=ivybridge | FileCheck %s --check-prefix=CHECK --check-prefix=SANDY 7 ; RUN: llc < %s -mtriple=i686-unknown-unknown -print-schedule -mcpu=haswell | FileCheck %s --check-prefix=CHECK --check-prefix=HASWELL 8 ; RUN: llc < %s -mtriple=i686-unknown-unknown -print-schedule -mcpu=broadwell | FileCheck %s --check-prefix=CHECK --check-prefix=BROADWELL 9 ; RUN: llc < %s -mtriple=i686-unknown-unknown -print-schedule -mcpu=skylake | FileCheck %s --check-prefix=CHECK --check-prefix=SKYLAKE 10 ; RUN: llc < %s -mtriple=i686-unknown-unknown -print-schedule -mcpu=skx | FileCheck %s --check-prefix=CHECK --check-prefix=SKX 11 ; RUN: llc < %s -mtriple=i686-unknown-unknown -print-schedule -mcpu=btver2 | FileCheck %s --check-prefix=CHECK --check-prefix=BTVER2 12 ; RUN: llc < %s -mtriple=i686-unknown-unknown -print-schedule -mcpu=znver1 | FileCheck %s --check-prefix=CHECK --check-prefix=ZNVER1 13 14 define i8 @test_aaa(i8 %a0) optsize { 15 ; GENERIC-LABEL: test_aaa: 16 ; GENERIC: # %bb.0: 17 ; GENERIC-NEXT: movb {{[0-9]+}}(%esp), %al 18 ; GENERIC-NEXT: #APP 19 ; GENERIC-NEXT: aaa 20 ; GENERIC-NEXT: #NO_APP 21 ; GENERIC-NEXT: retl 22 ; 23 ; ATOM-LABEL: test_aaa: 24 ; ATOM: # %bb.0: 25 ; ATOM-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [1:1.00] 26 ; ATOM-NEXT: #APP 27 ; ATOM-NEXT: aaa # sched: [13:6.50] 28 ; ATOM-NEXT: #NO_APP 29 ; ATOM-NEXT: retl # sched: [79:39.50] 30 ; 31 ; SLM-LABEL: test_aaa: 32 ; SLM: # %bb.0: 33 ; SLM-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [3:1.00] 34 ; SLM-NEXT: #APP 35 ; SLM-NEXT: aaa # sched: [100:1.00] 36 ; SLM-NEXT: #NO_APP 37 ; SLM-NEXT: retl # sched: [4:1.00] 38 ; 39 ; SANDY-LABEL: test_aaa: 40 ; SANDY: # %bb.0: 41 ; SANDY-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 42 ; SANDY-NEXT: #APP 43 ; SANDY-NEXT: aaa # sched: [100:0.33] 44 ; SANDY-NEXT: #NO_APP 45 ; SANDY-NEXT: retl # sched: [6:1.00] 46 ; 47 ; HASWELL-LABEL: test_aaa: 48 ; HASWELL: # %bb.0: 49 ; HASWELL-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 50 ; HASWELL-NEXT: #APP 51 ; HASWELL-NEXT: aaa # sched: [100:0.25] 52 ; HASWELL-NEXT: #NO_APP 53 ; HASWELL-NEXT: retl # sched: [7:1.00] 54 ; 55 ; BROADWELL-LABEL: test_aaa: 56 ; BROADWELL: # %bb.0: 57 ; BROADWELL-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 58 ; BROADWELL-NEXT: #APP 59 ; BROADWELL-NEXT: aaa # sched: [100:0.25] 60 ; BROADWELL-NEXT: #NO_APP 61 ; BROADWELL-NEXT: retl # sched: [6:0.50] 62 ; 63 ; SKYLAKE-LABEL: test_aaa: 64 ; SKYLAKE: # %bb.0: 65 ; SKYLAKE-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 66 ; SKYLAKE-NEXT: #APP 67 ; SKYLAKE-NEXT: aaa # sched: [100:0.25] 68 ; SKYLAKE-NEXT: #NO_APP 69 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 70 ; 71 ; SKX-LABEL: test_aaa: 72 ; SKX: # %bb.0: 73 ; SKX-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 74 ; SKX-NEXT: #APP 75 ; SKX-NEXT: aaa # sched: [100:0.25] 76 ; SKX-NEXT: #NO_APP 77 ; SKX-NEXT: retl # sched: [6:0.50] 78 ; 79 ; BTVER2-LABEL: test_aaa: 80 ; BTVER2: # %bb.0: 81 ; BTVER2-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:1.00] 82 ; BTVER2-NEXT: #APP 83 ; BTVER2-NEXT: aaa # sched: [100:0.50] 84 ; BTVER2-NEXT: #NO_APP 85 ; BTVER2-NEXT: retl # sched: [4:1.00] 86 ; 87 ; ZNVER1-LABEL: test_aaa: 88 ; ZNVER1: # %bb.0: 89 ; ZNVER1-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [8:0.50] 90 ; ZNVER1-NEXT: #APP 91 ; ZNVER1-NEXT: aaa # sched: [100:0.25] 92 ; ZNVER1-NEXT: #NO_APP 93 ; ZNVER1-NEXT: retl # sched: [1:0.50] 94 %1 = tail call i8 asm "aaa", "=r,r"(i8 %a0) nounwind 95 ret i8 %1 96 } 97 98 define void @test_aad(i16 %a0) optsize { 99 ; GENERIC-LABEL: test_aad: 100 ; GENERIC: # %bb.0: 101 ; GENERIC-NEXT: movzwl {{[0-9]+}}(%esp), %eax 102 ; GENERIC-NEXT: #APP 103 ; GENERIC-NEXT: aad 104 ; GENERIC-NEXT: aad $16 105 ; GENERIC-NEXT: #NO_APP 106 ; GENERIC-NEXT: retl 107 ; 108 ; ATOM-LABEL: test_aad: 109 ; ATOM: # %bb.0: 110 ; ATOM-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [1:1.00] 111 ; ATOM-NEXT: #APP 112 ; ATOM-NEXT: aad # sched: [7:3.50] 113 ; ATOM-NEXT: aad $16 # sched: [7:3.50] 114 ; ATOM-NEXT: #NO_APP 115 ; ATOM-NEXT: retl # sched: [79:39.50] 116 ; 117 ; SLM-LABEL: test_aad: 118 ; SLM: # %bb.0: 119 ; SLM-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [4:1.00] 120 ; SLM-NEXT: #APP 121 ; SLM-NEXT: aad # sched: [100:1.00] 122 ; SLM-NEXT: aad $16 # sched: [100:1.00] 123 ; SLM-NEXT: #NO_APP 124 ; SLM-NEXT: retl # sched: [4:1.00] 125 ; 126 ; SANDY-LABEL: test_aad: 127 ; SANDY: # %bb.0: 128 ; SANDY-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 129 ; SANDY-NEXT: #APP 130 ; SANDY-NEXT: aad # sched: [100:0.33] 131 ; SANDY-NEXT: aad $16 # sched: [100:0.33] 132 ; SANDY-NEXT: #NO_APP 133 ; SANDY-NEXT: retl # sched: [6:1.00] 134 ; 135 ; HASWELL-LABEL: test_aad: 136 ; HASWELL: # %bb.0: 137 ; HASWELL-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 138 ; HASWELL-NEXT: #APP 139 ; HASWELL-NEXT: aad # sched: [100:0.25] 140 ; HASWELL-NEXT: aad $16 # sched: [100:0.25] 141 ; HASWELL-NEXT: #NO_APP 142 ; HASWELL-NEXT: retl # sched: [7:1.00] 143 ; 144 ; BROADWELL-LABEL: test_aad: 145 ; BROADWELL: # %bb.0: 146 ; BROADWELL-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 147 ; BROADWELL-NEXT: #APP 148 ; BROADWELL-NEXT: aad # sched: [100:0.25] 149 ; BROADWELL-NEXT: aad $16 # sched: [100:0.25] 150 ; BROADWELL-NEXT: #NO_APP 151 ; BROADWELL-NEXT: retl # sched: [6:0.50] 152 ; 153 ; SKYLAKE-LABEL: test_aad: 154 ; SKYLAKE: # %bb.0: 155 ; SKYLAKE-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 156 ; SKYLAKE-NEXT: #APP 157 ; SKYLAKE-NEXT: aad # sched: [100:0.25] 158 ; SKYLAKE-NEXT: aad $16 # sched: [100:0.25] 159 ; SKYLAKE-NEXT: #NO_APP 160 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 161 ; 162 ; SKX-LABEL: test_aad: 163 ; SKX: # %bb.0: 164 ; SKX-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 165 ; SKX-NEXT: #APP 166 ; SKX-NEXT: aad # sched: [100:0.25] 167 ; SKX-NEXT: aad $16 # sched: [100:0.25] 168 ; SKX-NEXT: #NO_APP 169 ; SKX-NEXT: retl # sched: [6:0.50] 170 ; 171 ; BTVER2-LABEL: test_aad: 172 ; BTVER2: # %bb.0: 173 ; BTVER2-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [4:1.00] 174 ; BTVER2-NEXT: #APP 175 ; BTVER2-NEXT: aad # sched: [100:0.50] 176 ; BTVER2-NEXT: aad $16 # sched: [100:0.50] 177 ; BTVER2-NEXT: #NO_APP 178 ; BTVER2-NEXT: retl # sched: [4:1.00] 179 ; 180 ; ZNVER1-LABEL: test_aad: 181 ; ZNVER1: # %bb.0: 182 ; ZNVER1-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [8:0.50] 183 ; ZNVER1-NEXT: #APP 184 ; ZNVER1-NEXT: aad # sched: [100:0.25] 185 ; ZNVER1-NEXT: aad $16 # sched: [100:0.25] 186 ; ZNVER1-NEXT: #NO_APP 187 ; ZNVER1-NEXT: retl # sched: [1:0.50] 188 tail call void asm "aad \0A\09 aad $1", "r,i"(i16 %a0, i16 16) nounwind 189 ret void 190 } 191 192 define void @test_aam(i8 %a0) optsize { 193 ; GENERIC-LABEL: test_aam: 194 ; GENERIC: # %bb.0: 195 ; GENERIC-NEXT: movb {{[0-9]+}}(%esp), %al 196 ; GENERIC-NEXT: #APP 197 ; GENERIC-NEXT: aam 198 ; GENERIC-NEXT: aam $16 199 ; GENERIC-NEXT: #NO_APP 200 ; GENERIC-NEXT: retl 201 ; 202 ; ATOM-LABEL: test_aam: 203 ; ATOM: # %bb.0: 204 ; ATOM-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [1:1.00] 205 ; ATOM-NEXT: #APP 206 ; ATOM-NEXT: aam # sched: [21:10.50] 207 ; ATOM-NEXT: aam $16 # sched: [21:10.50] 208 ; ATOM-NEXT: #NO_APP 209 ; ATOM-NEXT: retl # sched: [79:39.50] 210 ; 211 ; SLM-LABEL: test_aam: 212 ; SLM: # %bb.0: 213 ; SLM-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [3:1.00] 214 ; SLM-NEXT: #APP 215 ; SLM-NEXT: aam # sched: [100:1.00] 216 ; SLM-NEXT: aam $16 # sched: [100:1.00] 217 ; SLM-NEXT: #NO_APP 218 ; SLM-NEXT: retl # sched: [4:1.00] 219 ; 220 ; SANDY-LABEL: test_aam: 221 ; SANDY: # %bb.0: 222 ; SANDY-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 223 ; SANDY-NEXT: #APP 224 ; SANDY-NEXT: aam # sched: [100:0.33] 225 ; SANDY-NEXT: aam $16 # sched: [100:0.33] 226 ; SANDY-NEXT: #NO_APP 227 ; SANDY-NEXT: retl # sched: [6:1.00] 228 ; 229 ; HASWELL-LABEL: test_aam: 230 ; HASWELL: # %bb.0: 231 ; HASWELL-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 232 ; HASWELL-NEXT: #APP 233 ; HASWELL-NEXT: aam # sched: [100:0.25] 234 ; HASWELL-NEXT: aam $16 # sched: [100:0.25] 235 ; HASWELL-NEXT: #NO_APP 236 ; HASWELL-NEXT: retl # sched: [7:1.00] 237 ; 238 ; BROADWELL-LABEL: test_aam: 239 ; BROADWELL: # %bb.0: 240 ; BROADWELL-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 241 ; BROADWELL-NEXT: #APP 242 ; BROADWELL-NEXT: aam # sched: [100:0.25] 243 ; BROADWELL-NEXT: aam $16 # sched: [100:0.25] 244 ; BROADWELL-NEXT: #NO_APP 245 ; BROADWELL-NEXT: retl # sched: [6:0.50] 246 ; 247 ; SKYLAKE-LABEL: test_aam: 248 ; SKYLAKE: # %bb.0: 249 ; SKYLAKE-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 250 ; SKYLAKE-NEXT: #APP 251 ; SKYLAKE-NEXT: aam # sched: [100:0.25] 252 ; SKYLAKE-NEXT: aam $16 # sched: [100:0.25] 253 ; SKYLAKE-NEXT: #NO_APP 254 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 255 ; 256 ; SKX-LABEL: test_aam: 257 ; SKX: # %bb.0: 258 ; SKX-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 259 ; SKX-NEXT: #APP 260 ; SKX-NEXT: aam # sched: [100:0.25] 261 ; SKX-NEXT: aam $16 # sched: [100:0.25] 262 ; SKX-NEXT: #NO_APP 263 ; SKX-NEXT: retl # sched: [6:0.50] 264 ; 265 ; BTVER2-LABEL: test_aam: 266 ; BTVER2: # %bb.0: 267 ; BTVER2-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:1.00] 268 ; BTVER2-NEXT: #APP 269 ; BTVER2-NEXT: aam # sched: [100:0.50] 270 ; BTVER2-NEXT: aam $16 # sched: [100:0.50] 271 ; BTVER2-NEXT: #NO_APP 272 ; BTVER2-NEXT: retl # sched: [4:1.00] 273 ; 274 ; ZNVER1-LABEL: test_aam: 275 ; ZNVER1: # %bb.0: 276 ; ZNVER1-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [8:0.50] 277 ; ZNVER1-NEXT: #APP 278 ; ZNVER1-NEXT: aam # sched: [100:0.25] 279 ; ZNVER1-NEXT: aam $16 # sched: [100:0.25] 280 ; ZNVER1-NEXT: #NO_APP 281 ; ZNVER1-NEXT: retl # sched: [1:0.50] 282 tail call void asm "aam \0A\09 aam $1", "r,i"(i8 %a0, i8 16) nounwind 283 ret void 284 } 285 286 define i8 @test_aas(i8 %a0) optsize { 287 ; GENERIC-LABEL: test_aas: 288 ; GENERIC: # %bb.0: 289 ; GENERIC-NEXT: movb {{[0-9]+}}(%esp), %al 290 ; GENERIC-NEXT: #APP 291 ; GENERIC-NEXT: aas 292 ; GENERIC-NEXT: #NO_APP 293 ; GENERIC-NEXT: retl 294 ; 295 ; ATOM-LABEL: test_aas: 296 ; ATOM: # %bb.0: 297 ; ATOM-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [1:1.00] 298 ; ATOM-NEXT: #APP 299 ; ATOM-NEXT: aas # sched: [13:6.50] 300 ; ATOM-NEXT: #NO_APP 301 ; ATOM-NEXT: retl # sched: [79:39.50] 302 ; 303 ; SLM-LABEL: test_aas: 304 ; SLM: # %bb.0: 305 ; SLM-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [3:1.00] 306 ; SLM-NEXT: #APP 307 ; SLM-NEXT: aas # sched: [100:1.00] 308 ; SLM-NEXT: #NO_APP 309 ; SLM-NEXT: retl # sched: [4:1.00] 310 ; 311 ; SANDY-LABEL: test_aas: 312 ; SANDY: # %bb.0: 313 ; SANDY-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 314 ; SANDY-NEXT: #APP 315 ; SANDY-NEXT: aas # sched: [100:0.33] 316 ; SANDY-NEXT: #NO_APP 317 ; SANDY-NEXT: retl # sched: [6:1.00] 318 ; 319 ; HASWELL-LABEL: test_aas: 320 ; HASWELL: # %bb.0: 321 ; HASWELL-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 322 ; HASWELL-NEXT: #APP 323 ; HASWELL-NEXT: aas # sched: [100:0.25] 324 ; HASWELL-NEXT: #NO_APP 325 ; HASWELL-NEXT: retl # sched: [7:1.00] 326 ; 327 ; BROADWELL-LABEL: test_aas: 328 ; BROADWELL: # %bb.0: 329 ; BROADWELL-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 330 ; BROADWELL-NEXT: #APP 331 ; BROADWELL-NEXT: aas # sched: [100:0.25] 332 ; BROADWELL-NEXT: #NO_APP 333 ; BROADWELL-NEXT: retl # sched: [6:0.50] 334 ; 335 ; SKYLAKE-LABEL: test_aas: 336 ; SKYLAKE: # %bb.0: 337 ; SKYLAKE-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 338 ; SKYLAKE-NEXT: #APP 339 ; SKYLAKE-NEXT: aas # sched: [100:0.25] 340 ; SKYLAKE-NEXT: #NO_APP 341 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 342 ; 343 ; SKX-LABEL: test_aas: 344 ; SKX: # %bb.0: 345 ; SKX-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 346 ; SKX-NEXT: #APP 347 ; SKX-NEXT: aas # sched: [100:0.25] 348 ; SKX-NEXT: #NO_APP 349 ; SKX-NEXT: retl # sched: [6:0.50] 350 ; 351 ; BTVER2-LABEL: test_aas: 352 ; BTVER2: # %bb.0: 353 ; BTVER2-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:1.00] 354 ; BTVER2-NEXT: #APP 355 ; BTVER2-NEXT: aas # sched: [100:0.50] 356 ; BTVER2-NEXT: #NO_APP 357 ; BTVER2-NEXT: retl # sched: [4:1.00] 358 ; 359 ; ZNVER1-LABEL: test_aas: 360 ; ZNVER1: # %bb.0: 361 ; ZNVER1-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [8:0.50] 362 ; ZNVER1-NEXT: #APP 363 ; ZNVER1-NEXT: aas # sched: [100:0.25] 364 ; ZNVER1-NEXT: #NO_APP 365 ; ZNVER1-NEXT: retl # sched: [1:0.50] 366 %1 = tail call i8 asm "aas", "=r,r"(i8 %a0) nounwind 367 ret i8 %1 368 } 369 370 define void @test_arpl(i16 %a0, i16 *%a1) optsize { 371 ; GENERIC-LABEL: test_arpl: 372 ; GENERIC: # %bb.0: 373 ; GENERIC-NEXT: movzwl {{[0-9]+}}(%esp), %eax 374 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %ecx 375 ; GENERIC-NEXT: #APP 376 ; GENERIC-NEXT: arpl %ax, (%ecx) 377 ; GENERIC-NEXT: #NO_APP 378 ; GENERIC-NEXT: retl 379 ; 380 ; ATOM-LABEL: test_arpl: 381 ; ATOM: # %bb.0: 382 ; ATOM-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [1:1.00] 383 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [1:1.00] 384 ; ATOM-NEXT: #APP 385 ; ATOM-NEXT: arpl %ax, (%ecx) # sched: [23:11.50] 386 ; ATOM-NEXT: #NO_APP 387 ; ATOM-NEXT: retl # sched: [79:39.50] 388 ; 389 ; SLM-LABEL: test_arpl: 390 ; SLM: # %bb.0: 391 ; SLM-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [4:1.00] 392 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [3:1.00] 393 ; SLM-NEXT: #APP 394 ; SLM-NEXT: arpl %ax, (%ecx) # sched: [100:1.00] 395 ; SLM-NEXT: #NO_APP 396 ; SLM-NEXT: retl # sched: [4:1.00] 397 ; 398 ; SANDY-LABEL: test_arpl: 399 ; SANDY: # %bb.0: 400 ; SANDY-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 401 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 402 ; SANDY-NEXT: #APP 403 ; SANDY-NEXT: arpl %ax, (%ecx) # sched: [100:0.33] 404 ; SANDY-NEXT: #NO_APP 405 ; SANDY-NEXT: retl # sched: [6:1.00] 406 ; 407 ; HASWELL-LABEL: test_arpl: 408 ; HASWELL: # %bb.0: 409 ; HASWELL-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 410 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 411 ; HASWELL-NEXT: #APP 412 ; HASWELL-NEXT: arpl %ax, (%ecx) # sched: [100:0.25] 413 ; HASWELL-NEXT: #NO_APP 414 ; HASWELL-NEXT: retl # sched: [7:1.00] 415 ; 416 ; BROADWELL-LABEL: test_arpl: 417 ; BROADWELL: # %bb.0: 418 ; BROADWELL-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 419 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 420 ; BROADWELL-NEXT: #APP 421 ; BROADWELL-NEXT: arpl %ax, (%ecx) # sched: [100:0.25] 422 ; BROADWELL-NEXT: #NO_APP 423 ; BROADWELL-NEXT: retl # sched: [6:0.50] 424 ; 425 ; SKYLAKE-LABEL: test_arpl: 426 ; SKYLAKE: # %bb.0: 427 ; SKYLAKE-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 428 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 429 ; SKYLAKE-NEXT: #APP 430 ; SKYLAKE-NEXT: arpl %ax, (%ecx) # sched: [100:0.25] 431 ; SKYLAKE-NEXT: #NO_APP 432 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 433 ; 434 ; SKX-LABEL: test_arpl: 435 ; SKX: # %bb.0: 436 ; SKX-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 437 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 438 ; SKX-NEXT: #APP 439 ; SKX-NEXT: arpl %ax, (%ecx) # sched: [100:0.25] 440 ; SKX-NEXT: #NO_APP 441 ; SKX-NEXT: retl # sched: [6:0.50] 442 ; 443 ; BTVER2-LABEL: test_arpl: 444 ; BTVER2: # %bb.0: 445 ; BTVER2-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [4:1.00] 446 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:1.00] 447 ; BTVER2-NEXT: #APP 448 ; BTVER2-NEXT: arpl %ax, (%ecx) # sched: [100:0.50] 449 ; BTVER2-NEXT: #NO_APP 450 ; BTVER2-NEXT: retl # sched: [4:1.00] 451 ; 452 ; ZNVER1-LABEL: test_arpl: 453 ; ZNVER1: # %bb.0: 454 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [8:0.50] 455 ; ZNVER1-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [8:0.50] 456 ; ZNVER1-NEXT: #APP 457 ; ZNVER1-NEXT: arpl %ax, (%ecx) # sched: [100:0.25] 458 ; ZNVER1-NEXT: #NO_APP 459 ; ZNVER1-NEXT: retl # sched: [1:0.50] 460 call void asm sideeffect "arpl $0, $1", "r,*m"(i16 %a0, i16 *%a1) 461 ret void 462 } 463 464 define void @test_bound(i16 %a0, i16 *%a1, i32 %a2, i32 *%a3) optsize { 465 ; GENERIC-LABEL: test_bound: 466 ; GENERIC: # %bb.0: 467 ; GENERIC-NEXT: pushl %esi 468 ; GENERIC-NEXT: .cfi_def_cfa_offset 8 469 ; GENERIC-NEXT: .cfi_offset %esi, -8 470 ; GENERIC-NEXT: movzwl {{[0-9]+}}(%esp), %eax 471 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %ecx 472 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %edx 473 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %esi 474 ; GENERIC-NEXT: #APP 475 ; GENERIC-NEXT: bound %ax, (%esi) 476 ; GENERIC-NEXT: bound %ecx, (%edx) 477 ; GENERIC-NEXT: #NO_APP 478 ; GENERIC-NEXT: popl %esi 479 ; GENERIC-NEXT: .cfi_def_cfa_offset 4 480 ; GENERIC-NEXT: retl 481 ; 482 ; ATOM-LABEL: test_bound: 483 ; ATOM: # %bb.0: 484 ; ATOM-NEXT: pushl %esi # sched: [1:1.00] 485 ; ATOM-NEXT: .cfi_def_cfa_offset 8 486 ; ATOM-NEXT: .cfi_offset %esi, -8 487 ; ATOM-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [1:1.00] 488 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [1:1.00] 489 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [1:1.00] 490 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %esi # sched: [1:1.00] 491 ; ATOM-NEXT: #APP 492 ; ATOM-NEXT: bound %ax, (%esi) # sched: [11:5.50] 493 ; ATOM-NEXT: bound %ecx, (%edx) # sched: [11:5.50] 494 ; ATOM-NEXT: #NO_APP 495 ; ATOM-NEXT: popl %esi # sched: [1:1.00] 496 ; ATOM-NEXT: .cfi_def_cfa_offset 4 497 ; ATOM-NEXT: retl # sched: [79:39.50] 498 ; 499 ; SLM-LABEL: test_bound: 500 ; SLM: # %bb.0: 501 ; SLM-NEXT: pushl %esi # sched: [1:1.00] 502 ; SLM-NEXT: .cfi_def_cfa_offset 8 503 ; SLM-NEXT: .cfi_offset %esi, -8 504 ; SLM-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [4:1.00] 505 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [3:1.00] 506 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [3:1.00] 507 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %esi # sched: [3:1.00] 508 ; SLM-NEXT: #APP 509 ; SLM-NEXT: bound %ax, (%esi) # sched: [100:1.00] 510 ; SLM-NEXT: bound %ecx, (%edx) # sched: [100:1.00] 511 ; SLM-NEXT: #NO_APP 512 ; SLM-NEXT: popl %esi # sched: [3:1.00] 513 ; SLM-NEXT: .cfi_def_cfa_offset 4 514 ; SLM-NEXT: retl # sched: [4:1.00] 515 ; 516 ; SANDY-LABEL: test_bound: 517 ; SANDY: # %bb.0: 518 ; SANDY-NEXT: pushl %esi # sched: [5:1.00] 519 ; SANDY-NEXT: .cfi_def_cfa_offset 8 520 ; SANDY-NEXT: .cfi_offset %esi, -8 521 ; SANDY-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 522 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 523 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [5:0.50] 524 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %esi # sched: [5:0.50] 525 ; SANDY-NEXT: #APP 526 ; SANDY-NEXT: bound %ax, (%esi) # sched: [100:0.33] 527 ; SANDY-NEXT: bound %ecx, (%edx) # sched: [100:0.33] 528 ; SANDY-NEXT: #NO_APP 529 ; SANDY-NEXT: popl %esi # sched: [6:0.50] 530 ; SANDY-NEXT: .cfi_def_cfa_offset 4 531 ; SANDY-NEXT: retl # sched: [6:1.00] 532 ; 533 ; HASWELL-LABEL: test_bound: 534 ; HASWELL: # %bb.0: 535 ; HASWELL-NEXT: pushl %esi # sched: [2:1.00] 536 ; HASWELL-NEXT: .cfi_def_cfa_offset 8 537 ; HASWELL-NEXT: .cfi_offset %esi, -8 538 ; HASWELL-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 539 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 540 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [5:0.50] 541 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %esi # sched: [5:0.50] 542 ; HASWELL-NEXT: #APP 543 ; HASWELL-NEXT: bound %ax, (%esi) # sched: [1:3.75] 544 ; HASWELL-NEXT: bound %ecx, (%edx) # sched: [1:3.75] 545 ; HASWELL-NEXT: #NO_APP 546 ; HASWELL-NEXT: popl %esi # sched: [6:0.50] 547 ; HASWELL-NEXT: .cfi_def_cfa_offset 4 548 ; HASWELL-NEXT: retl # sched: [7:1.00] 549 ; 550 ; BROADWELL-LABEL: test_bound: 551 ; BROADWELL: # %bb.0: 552 ; BROADWELL-NEXT: pushl %esi # sched: [2:1.00] 553 ; BROADWELL-NEXT: .cfi_def_cfa_offset 8 554 ; BROADWELL-NEXT: .cfi_offset %esi, -8 555 ; BROADWELL-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 556 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 557 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [5:0.50] 558 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %esi # sched: [5:0.50] 559 ; BROADWELL-NEXT: #APP 560 ; BROADWELL-NEXT: bound %ax, (%esi) # sched: [100:0.25] 561 ; BROADWELL-NEXT: bound %ecx, (%edx) # sched: [100:0.25] 562 ; BROADWELL-NEXT: #NO_APP 563 ; BROADWELL-NEXT: popl %esi # sched: [6:0.50] 564 ; BROADWELL-NEXT: .cfi_def_cfa_offset 4 565 ; BROADWELL-NEXT: retl # sched: [6:0.50] 566 ; 567 ; SKYLAKE-LABEL: test_bound: 568 ; SKYLAKE: # %bb.0: 569 ; SKYLAKE-NEXT: pushl %esi # sched: [2:1.00] 570 ; SKYLAKE-NEXT: .cfi_def_cfa_offset 8 571 ; SKYLAKE-NEXT: .cfi_offset %esi, -8 572 ; SKYLAKE-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 573 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 574 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [5:0.50] 575 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %esi # sched: [5:0.50] 576 ; SKYLAKE-NEXT: #APP 577 ; SKYLAKE-NEXT: bound %ax, (%esi) # sched: [100:0.25] 578 ; SKYLAKE-NEXT: bound %ecx, (%edx) # sched: [100:0.25] 579 ; SKYLAKE-NEXT: #NO_APP 580 ; SKYLAKE-NEXT: popl %esi # sched: [6:0.50] 581 ; SKYLAKE-NEXT: .cfi_def_cfa_offset 4 582 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 583 ; 584 ; SKX-LABEL: test_bound: 585 ; SKX: # %bb.0: 586 ; SKX-NEXT: pushl %esi # sched: [2:1.00] 587 ; SKX-NEXT: .cfi_def_cfa_offset 8 588 ; SKX-NEXT: .cfi_offset %esi, -8 589 ; SKX-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 590 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 591 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [5:0.50] 592 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %esi # sched: [5:0.50] 593 ; SKX-NEXT: #APP 594 ; SKX-NEXT: bound %ax, (%esi) # sched: [100:0.25] 595 ; SKX-NEXT: bound %ecx, (%edx) # sched: [100:0.25] 596 ; SKX-NEXT: #NO_APP 597 ; SKX-NEXT: popl %esi # sched: [6:0.50] 598 ; SKX-NEXT: .cfi_def_cfa_offset 4 599 ; SKX-NEXT: retl # sched: [6:0.50] 600 ; 601 ; BTVER2-LABEL: test_bound: 602 ; BTVER2: # %bb.0: 603 ; BTVER2-NEXT: pushl %esi # sched: [1:1.00] 604 ; BTVER2-NEXT: .cfi_def_cfa_offset 8 605 ; BTVER2-NEXT: .cfi_offset %esi, -8 606 ; BTVER2-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [4:1.00] 607 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:1.00] 608 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [5:1.00] 609 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %esi # sched: [5:1.00] 610 ; BTVER2-NEXT: #APP 611 ; BTVER2-NEXT: bound %ax, (%esi) # sched: [100:0.50] 612 ; BTVER2-NEXT: bound %ecx, (%edx) # sched: [100:0.50] 613 ; BTVER2-NEXT: #NO_APP 614 ; BTVER2-NEXT: popl %esi # sched: [5:1.00] 615 ; BTVER2-NEXT: .cfi_def_cfa_offset 4 616 ; BTVER2-NEXT: retl # sched: [4:1.00] 617 ; 618 ; ZNVER1-LABEL: test_bound: 619 ; ZNVER1: # %bb.0: 620 ; ZNVER1-NEXT: pushl %esi # sched: [1:0.50] 621 ; ZNVER1-NEXT: .cfi_def_cfa_offset 8 622 ; ZNVER1-NEXT: .cfi_offset %esi, -8 623 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [8:0.50] 624 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [8:0.50] 625 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %esi # sched: [8:0.50] 626 ; ZNVER1-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [8:0.50] 627 ; ZNVER1-NEXT: #APP 628 ; ZNVER1-NEXT: bound %ax, (%esi) # sched: [100:0.25] 629 ; ZNVER1-NEXT: bound %ecx, (%edx) # sched: [100:0.25] 630 ; ZNVER1-NEXT: #NO_APP 631 ; ZNVER1-NEXT: popl %esi # sched: [8:0.50] 632 ; ZNVER1-NEXT: .cfi_def_cfa_offset 4 633 ; ZNVER1-NEXT: retl # sched: [1:0.50] 634 call void asm sideeffect "bound $0, $1 \0A\09 bound $2, $3", "r,*m,r,*m"(i16 %a0, i16 *%a1, i32 %a2, i32 *%a3) 635 ret void 636 } 637 638 ; TODO - test_call 639 640 define i8 @test_daa(i8 %a0) optsize { 641 ; GENERIC-LABEL: test_daa: 642 ; GENERIC: # %bb.0: 643 ; GENERIC-NEXT: movb {{[0-9]+}}(%esp), %al 644 ; GENERIC-NEXT: #APP 645 ; GENERIC-NEXT: daa 646 ; GENERIC-NEXT: #NO_APP 647 ; GENERIC-NEXT: retl 648 ; 649 ; ATOM-LABEL: test_daa: 650 ; ATOM: # %bb.0: 651 ; ATOM-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [1:1.00] 652 ; ATOM-NEXT: #APP 653 ; ATOM-NEXT: daa # sched: [18:9.00] 654 ; ATOM-NEXT: #NO_APP 655 ; ATOM-NEXT: retl # sched: [79:39.50] 656 ; 657 ; SLM-LABEL: test_daa: 658 ; SLM: # %bb.0: 659 ; SLM-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [3:1.00] 660 ; SLM-NEXT: #APP 661 ; SLM-NEXT: daa # sched: [100:1.00] 662 ; SLM-NEXT: #NO_APP 663 ; SLM-NEXT: retl # sched: [4:1.00] 664 ; 665 ; SANDY-LABEL: test_daa: 666 ; SANDY: # %bb.0: 667 ; SANDY-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 668 ; SANDY-NEXT: #APP 669 ; SANDY-NEXT: daa # sched: [100:0.33] 670 ; SANDY-NEXT: #NO_APP 671 ; SANDY-NEXT: retl # sched: [6:1.00] 672 ; 673 ; HASWELL-LABEL: test_daa: 674 ; HASWELL: # %bb.0: 675 ; HASWELL-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 676 ; HASWELL-NEXT: #APP 677 ; HASWELL-NEXT: daa # sched: [100:0.25] 678 ; HASWELL-NEXT: #NO_APP 679 ; HASWELL-NEXT: retl # sched: [7:1.00] 680 ; 681 ; BROADWELL-LABEL: test_daa: 682 ; BROADWELL: # %bb.0: 683 ; BROADWELL-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 684 ; BROADWELL-NEXT: #APP 685 ; BROADWELL-NEXT: daa # sched: [100:0.25] 686 ; BROADWELL-NEXT: #NO_APP 687 ; BROADWELL-NEXT: retl # sched: [6:0.50] 688 ; 689 ; SKYLAKE-LABEL: test_daa: 690 ; SKYLAKE: # %bb.0: 691 ; SKYLAKE-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 692 ; SKYLAKE-NEXT: #APP 693 ; SKYLAKE-NEXT: daa # sched: [100:0.25] 694 ; SKYLAKE-NEXT: #NO_APP 695 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 696 ; 697 ; SKX-LABEL: test_daa: 698 ; SKX: # %bb.0: 699 ; SKX-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 700 ; SKX-NEXT: #APP 701 ; SKX-NEXT: daa # sched: [100:0.25] 702 ; SKX-NEXT: #NO_APP 703 ; SKX-NEXT: retl # sched: [6:0.50] 704 ; 705 ; BTVER2-LABEL: test_daa: 706 ; BTVER2: # %bb.0: 707 ; BTVER2-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:1.00] 708 ; BTVER2-NEXT: #APP 709 ; BTVER2-NEXT: daa # sched: [100:0.50] 710 ; BTVER2-NEXT: #NO_APP 711 ; BTVER2-NEXT: retl # sched: [4:1.00] 712 ; 713 ; ZNVER1-LABEL: test_daa: 714 ; ZNVER1: # %bb.0: 715 ; ZNVER1-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [8:0.50] 716 ; ZNVER1-NEXT: #APP 717 ; ZNVER1-NEXT: daa # sched: [100:0.25] 718 ; ZNVER1-NEXT: #NO_APP 719 ; ZNVER1-NEXT: retl # sched: [1:0.50] 720 %1 = tail call i8 asm "daa", "=r,r"(i8 %a0) nounwind 721 ret i8 %1 722 } 723 724 define i8 @test_das(i8 %a0) optsize { 725 ; GENERIC-LABEL: test_das: 726 ; GENERIC: # %bb.0: 727 ; GENERIC-NEXT: movb {{[0-9]+}}(%esp), %al 728 ; GENERIC-NEXT: #APP 729 ; GENERIC-NEXT: das 730 ; GENERIC-NEXT: #NO_APP 731 ; GENERIC-NEXT: retl 732 ; 733 ; ATOM-LABEL: test_das: 734 ; ATOM: # %bb.0: 735 ; ATOM-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [1:1.00] 736 ; ATOM-NEXT: #APP 737 ; ATOM-NEXT: das # sched: [20:10.00] 738 ; ATOM-NEXT: #NO_APP 739 ; ATOM-NEXT: retl # sched: [79:39.50] 740 ; 741 ; SLM-LABEL: test_das: 742 ; SLM: # %bb.0: 743 ; SLM-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [3:1.00] 744 ; SLM-NEXT: #APP 745 ; SLM-NEXT: das # sched: [100:1.00] 746 ; SLM-NEXT: #NO_APP 747 ; SLM-NEXT: retl # sched: [4:1.00] 748 ; 749 ; SANDY-LABEL: test_das: 750 ; SANDY: # %bb.0: 751 ; SANDY-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 752 ; SANDY-NEXT: #APP 753 ; SANDY-NEXT: das # sched: [100:0.33] 754 ; SANDY-NEXT: #NO_APP 755 ; SANDY-NEXT: retl # sched: [6:1.00] 756 ; 757 ; HASWELL-LABEL: test_das: 758 ; HASWELL: # %bb.0: 759 ; HASWELL-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 760 ; HASWELL-NEXT: #APP 761 ; HASWELL-NEXT: das # sched: [100:0.25] 762 ; HASWELL-NEXT: #NO_APP 763 ; HASWELL-NEXT: retl # sched: [7:1.00] 764 ; 765 ; BROADWELL-LABEL: test_das: 766 ; BROADWELL: # %bb.0: 767 ; BROADWELL-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 768 ; BROADWELL-NEXT: #APP 769 ; BROADWELL-NEXT: das # sched: [100:0.25] 770 ; BROADWELL-NEXT: #NO_APP 771 ; BROADWELL-NEXT: retl # sched: [6:0.50] 772 ; 773 ; SKYLAKE-LABEL: test_das: 774 ; SKYLAKE: # %bb.0: 775 ; SKYLAKE-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 776 ; SKYLAKE-NEXT: #APP 777 ; SKYLAKE-NEXT: das # sched: [100:0.25] 778 ; SKYLAKE-NEXT: #NO_APP 779 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 780 ; 781 ; SKX-LABEL: test_das: 782 ; SKX: # %bb.0: 783 ; SKX-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:0.50] 784 ; SKX-NEXT: #APP 785 ; SKX-NEXT: das # sched: [100:0.25] 786 ; SKX-NEXT: #NO_APP 787 ; SKX-NEXT: retl # sched: [6:0.50] 788 ; 789 ; BTVER2-LABEL: test_das: 790 ; BTVER2: # %bb.0: 791 ; BTVER2-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [5:1.00] 792 ; BTVER2-NEXT: #APP 793 ; BTVER2-NEXT: das # sched: [100:0.50] 794 ; BTVER2-NEXT: #NO_APP 795 ; BTVER2-NEXT: retl # sched: [4:1.00] 796 ; 797 ; ZNVER1-LABEL: test_das: 798 ; ZNVER1: # %bb.0: 799 ; ZNVER1-NEXT: movb {{[0-9]+}}(%esp), %al # sched: [8:0.50] 800 ; ZNVER1-NEXT: #APP 801 ; ZNVER1-NEXT: das # sched: [100:0.25] 802 ; ZNVER1-NEXT: #NO_APP 803 ; ZNVER1-NEXT: retl # sched: [1:0.50] 804 %1 = tail call i8 asm "das", "=r,r"(i8 %a0) nounwind 805 ret i8 %1 806 } 807 808 define void @test_dec16(i16 %a0, i16* %a1) optsize { 809 ; GENERIC-LABEL: test_dec16: 810 ; GENERIC: # %bb.0: 811 ; GENERIC-NEXT: movzwl {{[0-9]+}}(%esp), %eax 812 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %ecx 813 ; GENERIC-NEXT: #APP 814 ; GENERIC-NEXT: decw %ax 815 ; GENERIC-NEXT: decw (%ecx) 816 ; GENERIC-NEXT: #NO_APP 817 ; GENERIC-NEXT: retl 818 ; 819 ; ATOM-LABEL: test_dec16: 820 ; ATOM: # %bb.0: 821 ; ATOM-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [1:1.00] 822 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [1:1.00] 823 ; ATOM-NEXT: #APP 824 ; ATOM-NEXT: decw %ax # sched: [1:0.50] 825 ; ATOM-NEXT: decw (%ecx) # sched: [1:1.00] 826 ; ATOM-NEXT: #NO_APP 827 ; ATOM-NEXT: retl # sched: [79:39.50] 828 ; 829 ; SLM-LABEL: test_dec16: 830 ; SLM: # %bb.0: 831 ; SLM-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [4:1.00] 832 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [3:1.00] 833 ; SLM-NEXT: #APP 834 ; SLM-NEXT: decw %ax # sched: [1:0.50] 835 ; SLM-NEXT: decw (%ecx) # sched: [5:2.00] 836 ; SLM-NEXT: #NO_APP 837 ; SLM-NEXT: retl # sched: [4:1.00] 838 ; 839 ; SANDY-LABEL: test_dec16: 840 ; SANDY: # %bb.0: 841 ; SANDY-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 842 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 843 ; SANDY-NEXT: #APP 844 ; SANDY-NEXT: decw %ax # sched: [1:0.33] 845 ; SANDY-NEXT: decw (%ecx) # sched: [7:1.00] 846 ; SANDY-NEXT: #NO_APP 847 ; SANDY-NEXT: retl # sched: [6:1.00] 848 ; 849 ; HASWELL-LABEL: test_dec16: 850 ; HASWELL: # %bb.0: 851 ; HASWELL-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 852 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 853 ; HASWELL-NEXT: #APP 854 ; HASWELL-NEXT: decw %ax # sched: [1:0.25] 855 ; HASWELL-NEXT: decw (%ecx) # sched: [7:1.00] 856 ; HASWELL-NEXT: #NO_APP 857 ; HASWELL-NEXT: retl # sched: [7:1.00] 858 ; 859 ; BROADWELL-LABEL: test_dec16: 860 ; BROADWELL: # %bb.0: 861 ; BROADWELL-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 862 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 863 ; BROADWELL-NEXT: #APP 864 ; BROADWELL-NEXT: decw %ax # sched: [1:0.25] 865 ; BROADWELL-NEXT: decw (%ecx) # sched: [7:1.00] 866 ; BROADWELL-NEXT: #NO_APP 867 ; BROADWELL-NEXT: retl # sched: [6:0.50] 868 ; 869 ; SKYLAKE-LABEL: test_dec16: 870 ; SKYLAKE: # %bb.0: 871 ; SKYLAKE-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 872 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 873 ; SKYLAKE-NEXT: #APP 874 ; SKYLAKE-NEXT: decw %ax # sched: [1:0.25] 875 ; SKYLAKE-NEXT: decw (%ecx) # sched: [7:1.00] 876 ; SKYLAKE-NEXT: #NO_APP 877 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 878 ; 879 ; SKX-LABEL: test_dec16: 880 ; SKX: # %bb.0: 881 ; SKX-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 882 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 883 ; SKX-NEXT: #APP 884 ; SKX-NEXT: decw %ax # sched: [1:0.25] 885 ; SKX-NEXT: decw (%ecx) # sched: [7:1.00] 886 ; SKX-NEXT: #NO_APP 887 ; SKX-NEXT: retl # sched: [6:0.50] 888 ; 889 ; BTVER2-LABEL: test_dec16: 890 ; BTVER2: # %bb.0: 891 ; BTVER2-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [4:1.00] 892 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:1.00] 893 ; BTVER2-NEXT: #APP 894 ; BTVER2-NEXT: decw %ax # sched: [1:0.50] 895 ; BTVER2-NEXT: decw (%ecx) # sched: [5:1.00] 896 ; BTVER2-NEXT: #NO_APP 897 ; BTVER2-NEXT: retl # sched: [4:1.00] 898 ; 899 ; ZNVER1-LABEL: test_dec16: 900 ; ZNVER1: # %bb.0: 901 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [8:0.50] 902 ; ZNVER1-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [8:0.50] 903 ; ZNVER1-NEXT: #APP 904 ; ZNVER1-NEXT: decw %ax # sched: [1:0.25] 905 ; ZNVER1-NEXT: decw (%ecx) # sched: [5:0.50] 906 ; ZNVER1-NEXT: #NO_APP 907 ; ZNVER1-NEXT: retl # sched: [1:0.50] 908 tail call void asm "decw $0 \0A\09 decw $1", "r,*m"(i16 %a0, i16* %a1) nounwind 909 ret void 910 } 911 define void @test_dec32(i32 %a0, i32* %a1) optsize { 912 ; GENERIC-LABEL: test_dec32: 913 ; GENERIC: # %bb.0: 914 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %eax 915 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %ecx 916 ; GENERIC-NEXT: #APP 917 ; GENERIC-NEXT: decl %eax 918 ; GENERIC-NEXT: decl (%ecx) 919 ; GENERIC-NEXT: #NO_APP 920 ; GENERIC-NEXT: retl 921 ; 922 ; ATOM-LABEL: test_dec32: 923 ; ATOM: # %bb.0: 924 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [1:1.00] 925 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [1:1.00] 926 ; ATOM-NEXT: #APP 927 ; ATOM-NEXT: decl %eax # sched: [1:0.50] 928 ; ATOM-NEXT: decl (%ecx) # sched: [1:1.00] 929 ; ATOM-NEXT: #NO_APP 930 ; ATOM-NEXT: retl # sched: [79:39.50] 931 ; 932 ; SLM-LABEL: test_dec32: 933 ; SLM: # %bb.0: 934 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [3:1.00] 935 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [3:1.00] 936 ; SLM-NEXT: #APP 937 ; SLM-NEXT: decl %eax # sched: [1:0.50] 938 ; SLM-NEXT: decl (%ecx) # sched: [5:2.00] 939 ; SLM-NEXT: #NO_APP 940 ; SLM-NEXT: retl # sched: [4:1.00] 941 ; 942 ; SANDY-LABEL: test_dec32: 943 ; SANDY: # %bb.0: 944 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 945 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 946 ; SANDY-NEXT: #APP 947 ; SANDY-NEXT: decl %eax # sched: [1:0.33] 948 ; SANDY-NEXT: decl (%ecx) # sched: [7:1.00] 949 ; SANDY-NEXT: #NO_APP 950 ; SANDY-NEXT: retl # sched: [6:1.00] 951 ; 952 ; HASWELL-LABEL: test_dec32: 953 ; HASWELL: # %bb.0: 954 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 955 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 956 ; HASWELL-NEXT: #APP 957 ; HASWELL-NEXT: decl %eax # sched: [1:0.25] 958 ; HASWELL-NEXT: decl (%ecx) # sched: [7:1.00] 959 ; HASWELL-NEXT: #NO_APP 960 ; HASWELL-NEXT: retl # sched: [7:1.00] 961 ; 962 ; BROADWELL-LABEL: test_dec32: 963 ; BROADWELL: # %bb.0: 964 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 965 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 966 ; BROADWELL-NEXT: #APP 967 ; BROADWELL-NEXT: decl %eax # sched: [1:0.25] 968 ; BROADWELL-NEXT: decl (%ecx) # sched: [7:1.00] 969 ; BROADWELL-NEXT: #NO_APP 970 ; BROADWELL-NEXT: retl # sched: [6:0.50] 971 ; 972 ; SKYLAKE-LABEL: test_dec32: 973 ; SKYLAKE: # %bb.0: 974 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 975 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 976 ; SKYLAKE-NEXT: #APP 977 ; SKYLAKE-NEXT: decl %eax # sched: [1:0.25] 978 ; SKYLAKE-NEXT: decl (%ecx) # sched: [7:1.00] 979 ; SKYLAKE-NEXT: #NO_APP 980 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 981 ; 982 ; SKX-LABEL: test_dec32: 983 ; SKX: # %bb.0: 984 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 985 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 986 ; SKX-NEXT: #APP 987 ; SKX-NEXT: decl %eax # sched: [1:0.25] 988 ; SKX-NEXT: decl (%ecx) # sched: [7:1.00] 989 ; SKX-NEXT: #NO_APP 990 ; SKX-NEXT: retl # sched: [6:0.50] 991 ; 992 ; BTVER2-LABEL: test_dec32: 993 ; BTVER2: # %bb.0: 994 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:1.00] 995 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:1.00] 996 ; BTVER2-NEXT: #APP 997 ; BTVER2-NEXT: decl %eax # sched: [1:0.50] 998 ; BTVER2-NEXT: decl (%ecx) # sched: [5:1.00] 999 ; BTVER2-NEXT: #NO_APP 1000 ; BTVER2-NEXT: retl # sched: [4:1.00] 1001 ; 1002 ; ZNVER1-LABEL: test_dec32: 1003 ; ZNVER1: # %bb.0: 1004 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [8:0.50] 1005 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [8:0.50] 1006 ; ZNVER1-NEXT: #APP 1007 ; ZNVER1-NEXT: decl %eax # sched: [1:0.25] 1008 ; ZNVER1-NEXT: decl (%ecx) # sched: [5:0.50] 1009 ; ZNVER1-NEXT: #NO_APP 1010 ; ZNVER1-NEXT: retl # sched: [1:0.50] 1011 tail call void asm "decl $0 \0A\09 decl $1", "r,*m"(i32 %a0, i32* %a1) nounwind 1012 ret void 1013 } 1014 1015 define void @test_inc16(i16 %a0, i16* %a1) optsize { 1016 ; GENERIC-LABEL: test_inc16: 1017 ; GENERIC: # %bb.0: 1018 ; GENERIC-NEXT: movzwl {{[0-9]+}}(%esp), %eax 1019 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %ecx 1020 ; GENERIC-NEXT: #APP 1021 ; GENERIC-NEXT: incw %ax 1022 ; GENERIC-NEXT: incw (%ecx) 1023 ; GENERIC-NEXT: #NO_APP 1024 ; GENERIC-NEXT: retl 1025 ; 1026 ; ATOM-LABEL: test_inc16: 1027 ; ATOM: # %bb.0: 1028 ; ATOM-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [1:1.00] 1029 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [1:1.00] 1030 ; ATOM-NEXT: #APP 1031 ; ATOM-NEXT: incw %ax # sched: [1:0.50] 1032 ; ATOM-NEXT: incw (%ecx) # sched: [1:1.00] 1033 ; ATOM-NEXT: #NO_APP 1034 ; ATOM-NEXT: retl # sched: [79:39.50] 1035 ; 1036 ; SLM-LABEL: test_inc16: 1037 ; SLM: # %bb.0: 1038 ; SLM-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [4:1.00] 1039 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [3:1.00] 1040 ; SLM-NEXT: #APP 1041 ; SLM-NEXT: incw %ax # sched: [1:0.50] 1042 ; SLM-NEXT: incw (%ecx) # sched: [5:2.00] 1043 ; SLM-NEXT: #NO_APP 1044 ; SLM-NEXT: retl # sched: [4:1.00] 1045 ; 1046 ; SANDY-LABEL: test_inc16: 1047 ; SANDY: # %bb.0: 1048 ; SANDY-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1049 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1050 ; SANDY-NEXT: #APP 1051 ; SANDY-NEXT: incw %ax # sched: [1:0.33] 1052 ; SANDY-NEXT: incw (%ecx) # sched: [7:1.00] 1053 ; SANDY-NEXT: #NO_APP 1054 ; SANDY-NEXT: retl # sched: [6:1.00] 1055 ; 1056 ; HASWELL-LABEL: test_inc16: 1057 ; HASWELL: # %bb.0: 1058 ; HASWELL-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1059 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1060 ; HASWELL-NEXT: #APP 1061 ; HASWELL-NEXT: incw %ax # sched: [1:0.25] 1062 ; HASWELL-NEXT: incw (%ecx) # sched: [7:1.00] 1063 ; HASWELL-NEXT: #NO_APP 1064 ; HASWELL-NEXT: retl # sched: [7:1.00] 1065 ; 1066 ; BROADWELL-LABEL: test_inc16: 1067 ; BROADWELL: # %bb.0: 1068 ; BROADWELL-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1069 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1070 ; BROADWELL-NEXT: #APP 1071 ; BROADWELL-NEXT: incw %ax # sched: [1:0.25] 1072 ; BROADWELL-NEXT: incw (%ecx) # sched: [7:1.00] 1073 ; BROADWELL-NEXT: #NO_APP 1074 ; BROADWELL-NEXT: retl # sched: [6:0.50] 1075 ; 1076 ; SKYLAKE-LABEL: test_inc16: 1077 ; SKYLAKE: # %bb.0: 1078 ; SKYLAKE-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1079 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1080 ; SKYLAKE-NEXT: #APP 1081 ; SKYLAKE-NEXT: incw %ax # sched: [1:0.25] 1082 ; SKYLAKE-NEXT: incw (%ecx) # sched: [7:1.00] 1083 ; SKYLAKE-NEXT: #NO_APP 1084 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 1085 ; 1086 ; SKX-LABEL: test_inc16: 1087 ; SKX: # %bb.0: 1088 ; SKX-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1089 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1090 ; SKX-NEXT: #APP 1091 ; SKX-NEXT: incw %ax # sched: [1:0.25] 1092 ; SKX-NEXT: incw (%ecx) # sched: [7:1.00] 1093 ; SKX-NEXT: #NO_APP 1094 ; SKX-NEXT: retl # sched: [6:0.50] 1095 ; 1096 ; BTVER2-LABEL: test_inc16: 1097 ; BTVER2: # %bb.0: 1098 ; BTVER2-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [4:1.00] 1099 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:1.00] 1100 ; BTVER2-NEXT: #APP 1101 ; BTVER2-NEXT: incw %ax # sched: [1:0.50] 1102 ; BTVER2-NEXT: incw (%ecx) # sched: [5:1.00] 1103 ; BTVER2-NEXT: #NO_APP 1104 ; BTVER2-NEXT: retl # sched: [4:1.00] 1105 ; 1106 ; ZNVER1-LABEL: test_inc16: 1107 ; ZNVER1: # %bb.0: 1108 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [8:0.50] 1109 ; ZNVER1-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [8:0.50] 1110 ; ZNVER1-NEXT: #APP 1111 ; ZNVER1-NEXT: incw %ax # sched: [1:0.25] 1112 ; ZNVER1-NEXT: incw (%ecx) # sched: [5:0.50] 1113 ; ZNVER1-NEXT: #NO_APP 1114 ; ZNVER1-NEXT: retl # sched: [1:0.50] 1115 tail call void asm "incw $0 \0A\09 incw $1", "r,*m"(i16 %a0, i16* %a1) nounwind 1116 ret void 1117 } 1118 define void @test_inc32(i32 %a0, i32* %a1) optsize { 1119 ; GENERIC-LABEL: test_inc32: 1120 ; GENERIC: # %bb.0: 1121 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %eax 1122 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %ecx 1123 ; GENERIC-NEXT: #APP 1124 ; GENERIC-NEXT: incl %eax 1125 ; GENERIC-NEXT: incl (%ecx) 1126 ; GENERIC-NEXT: #NO_APP 1127 ; GENERIC-NEXT: retl 1128 ; 1129 ; ATOM-LABEL: test_inc32: 1130 ; ATOM: # %bb.0: 1131 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [1:1.00] 1132 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [1:1.00] 1133 ; ATOM-NEXT: #APP 1134 ; ATOM-NEXT: incl %eax # sched: [1:0.50] 1135 ; ATOM-NEXT: incl (%ecx) # sched: [1:1.00] 1136 ; ATOM-NEXT: #NO_APP 1137 ; ATOM-NEXT: retl # sched: [79:39.50] 1138 ; 1139 ; SLM-LABEL: test_inc32: 1140 ; SLM: # %bb.0: 1141 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [3:1.00] 1142 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [3:1.00] 1143 ; SLM-NEXT: #APP 1144 ; SLM-NEXT: incl %eax # sched: [1:0.50] 1145 ; SLM-NEXT: incl (%ecx) # sched: [5:2.00] 1146 ; SLM-NEXT: #NO_APP 1147 ; SLM-NEXT: retl # sched: [4:1.00] 1148 ; 1149 ; SANDY-LABEL: test_inc32: 1150 ; SANDY: # %bb.0: 1151 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1152 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1153 ; SANDY-NEXT: #APP 1154 ; SANDY-NEXT: incl %eax # sched: [1:0.33] 1155 ; SANDY-NEXT: incl (%ecx) # sched: [7:1.00] 1156 ; SANDY-NEXT: #NO_APP 1157 ; SANDY-NEXT: retl # sched: [6:1.00] 1158 ; 1159 ; HASWELL-LABEL: test_inc32: 1160 ; HASWELL: # %bb.0: 1161 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1162 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1163 ; HASWELL-NEXT: #APP 1164 ; HASWELL-NEXT: incl %eax # sched: [1:0.25] 1165 ; HASWELL-NEXT: incl (%ecx) # sched: [7:1.00] 1166 ; HASWELL-NEXT: #NO_APP 1167 ; HASWELL-NEXT: retl # sched: [7:1.00] 1168 ; 1169 ; BROADWELL-LABEL: test_inc32: 1170 ; BROADWELL: # %bb.0: 1171 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1172 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1173 ; BROADWELL-NEXT: #APP 1174 ; BROADWELL-NEXT: incl %eax # sched: [1:0.25] 1175 ; BROADWELL-NEXT: incl (%ecx) # sched: [7:1.00] 1176 ; BROADWELL-NEXT: #NO_APP 1177 ; BROADWELL-NEXT: retl # sched: [6:0.50] 1178 ; 1179 ; SKYLAKE-LABEL: test_inc32: 1180 ; SKYLAKE: # %bb.0: 1181 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1182 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1183 ; SKYLAKE-NEXT: #APP 1184 ; SKYLAKE-NEXT: incl %eax # sched: [1:0.25] 1185 ; SKYLAKE-NEXT: incl (%ecx) # sched: [7:1.00] 1186 ; SKYLAKE-NEXT: #NO_APP 1187 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 1188 ; 1189 ; SKX-LABEL: test_inc32: 1190 ; SKX: # %bb.0: 1191 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1192 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1193 ; SKX-NEXT: #APP 1194 ; SKX-NEXT: incl %eax # sched: [1:0.25] 1195 ; SKX-NEXT: incl (%ecx) # sched: [7:1.00] 1196 ; SKX-NEXT: #NO_APP 1197 ; SKX-NEXT: retl # sched: [6:0.50] 1198 ; 1199 ; BTVER2-LABEL: test_inc32: 1200 ; BTVER2: # %bb.0: 1201 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:1.00] 1202 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:1.00] 1203 ; BTVER2-NEXT: #APP 1204 ; BTVER2-NEXT: incl %eax # sched: [1:0.50] 1205 ; BTVER2-NEXT: incl (%ecx) # sched: [5:1.00] 1206 ; BTVER2-NEXT: #NO_APP 1207 ; BTVER2-NEXT: retl # sched: [4:1.00] 1208 ; 1209 ; ZNVER1-LABEL: test_inc32: 1210 ; ZNVER1: # %bb.0: 1211 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [8:0.50] 1212 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [8:0.50] 1213 ; ZNVER1-NEXT: #APP 1214 ; ZNVER1-NEXT: incl %eax # sched: [1:0.25] 1215 ; ZNVER1-NEXT: incl (%ecx) # sched: [5:0.50] 1216 ; ZNVER1-NEXT: #NO_APP 1217 ; ZNVER1-NEXT: retl # sched: [1:0.50] 1218 tail call void asm "incl $0 \0A\09 incl $1", "r,*m"(i32 %a0, i32* %a1) nounwind 1219 ret void 1220 } 1221 1222 define void @test_into() optsize { 1223 ; GENERIC-LABEL: test_into: 1224 ; GENERIC: # %bb.0: 1225 ; GENERIC-NEXT: #APP 1226 ; GENERIC-NEXT: into 1227 ; GENERIC-NEXT: #NO_APP 1228 ; GENERIC-NEXT: retl 1229 ; 1230 ; ATOM-LABEL: test_into: 1231 ; ATOM: # %bb.0: 1232 ; ATOM-NEXT: #APP 1233 ; ATOM-NEXT: into # sched: [6:3.00] 1234 ; ATOM-NEXT: #NO_APP 1235 ; ATOM-NEXT: retl # sched: [79:39.50] 1236 ; 1237 ; SLM-LABEL: test_into: 1238 ; SLM: # %bb.0: 1239 ; SLM-NEXT: #APP 1240 ; SLM-NEXT: into # sched: [100:1.00] 1241 ; SLM-NEXT: #NO_APP 1242 ; SLM-NEXT: retl # sched: [4:1.00] 1243 ; 1244 ; SANDY-LABEL: test_into: 1245 ; SANDY: # %bb.0: 1246 ; SANDY-NEXT: #APP 1247 ; SANDY-NEXT: into # sched: [100:0.33] 1248 ; SANDY-NEXT: #NO_APP 1249 ; SANDY-NEXT: retl # sched: [6:1.00] 1250 ; 1251 ; HASWELL-LABEL: test_into: 1252 ; HASWELL: # %bb.0: 1253 ; HASWELL-NEXT: #APP 1254 ; HASWELL-NEXT: into # sched: [1:1.00] 1255 ; HASWELL-NEXT: #NO_APP 1256 ; HASWELL-NEXT: retl # sched: [7:1.00] 1257 ; 1258 ; BROADWELL-LABEL: test_into: 1259 ; BROADWELL: # %bb.0: 1260 ; BROADWELL-NEXT: #APP 1261 ; BROADWELL-NEXT: into # sched: [100:0.25] 1262 ; BROADWELL-NEXT: #NO_APP 1263 ; BROADWELL-NEXT: retl # sched: [6:0.50] 1264 ; 1265 ; SKYLAKE-LABEL: test_into: 1266 ; SKYLAKE: # %bb.0: 1267 ; SKYLAKE-NEXT: #APP 1268 ; SKYLAKE-NEXT: into # sched: [100:0.25] 1269 ; SKYLAKE-NEXT: #NO_APP 1270 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 1271 ; 1272 ; SKX-LABEL: test_into: 1273 ; SKX: # %bb.0: 1274 ; SKX-NEXT: #APP 1275 ; SKX-NEXT: into # sched: [100:0.25] 1276 ; SKX-NEXT: #NO_APP 1277 ; SKX-NEXT: retl # sched: [6:0.50] 1278 ; 1279 ; BTVER2-LABEL: test_into: 1280 ; BTVER2: # %bb.0: 1281 ; BTVER2-NEXT: #APP 1282 ; BTVER2-NEXT: into # sched: [100:0.50] 1283 ; BTVER2-NEXT: #NO_APP 1284 ; BTVER2-NEXT: retl # sched: [4:1.00] 1285 ; 1286 ; ZNVER1-LABEL: test_into: 1287 ; ZNVER1: # %bb.0: 1288 ; ZNVER1-NEXT: #APP 1289 ; ZNVER1-NEXT: into # sched: [100:0.25] 1290 ; ZNVER1-NEXT: #NO_APP 1291 ; ZNVER1-NEXT: retl # sched: [1:0.50] 1292 call void asm sideeffect "into", ""() 1293 ret void 1294 } 1295 1296 ; TODO - test_jmp 1297 1298 define void @test_jcxz_jecxz() optsize { 1299 ; GENERIC-LABEL: test_jcxz_jecxz: 1300 ; GENERIC: # %bb.0: 1301 ; GENERIC-NEXT: #APP 1302 ; GENERIC-NEXT: JXTGT: 1303 ; GENERIC-NEXT: jcxz JXTGT 1304 ; GENERIC-NEXT: jecxz JXTGT 1305 ; GENERIC-NEXT: #NO_APP 1306 ; GENERIC-NEXT: retl 1307 ; 1308 ; ATOM-LABEL: test_jcxz_jecxz: 1309 ; ATOM: # %bb.0: 1310 ; ATOM-NEXT: #APP 1311 ; ATOM-NEXT: JXTGT: 1312 ; ATOM-NEXT: jcxz JXTGT # sched: [4:2.00] 1313 ; ATOM-NEXT: jecxz JXTGT # sched: [4:2.00] 1314 ; ATOM-NEXT: #NO_APP 1315 ; ATOM-NEXT: retl # sched: [79:39.50] 1316 ; 1317 ; SLM-LABEL: test_jcxz_jecxz: 1318 ; SLM: # %bb.0: 1319 ; SLM-NEXT: #APP 1320 ; SLM-NEXT: JXTGT: 1321 ; SLM-NEXT: jcxz JXTGT # sched: [1:1.00] 1322 ; SLM-NEXT: jecxz JXTGT # sched: [1:1.00] 1323 ; SLM-NEXT: #NO_APP 1324 ; SLM-NEXT: retl # sched: [4:1.00] 1325 ; 1326 ; SANDY-LABEL: test_jcxz_jecxz: 1327 ; SANDY: # %bb.0: 1328 ; SANDY-NEXT: #APP 1329 ; SANDY-NEXT: JXTGT: 1330 ; SANDY-NEXT: jcxz JXTGT # sched: [2:1.00] 1331 ; SANDY-NEXT: jecxz JXTGT # sched: [2:1.00] 1332 ; SANDY-NEXT: #NO_APP 1333 ; SANDY-NEXT: retl # sched: [6:1.00] 1334 ; 1335 ; HASWELL-LABEL: test_jcxz_jecxz: 1336 ; HASWELL: # %bb.0: 1337 ; HASWELL-NEXT: #APP 1338 ; HASWELL-NEXT: JXTGT: 1339 ; HASWELL-NEXT: jcxz JXTGT # sched: [2:0.50] 1340 ; HASWELL-NEXT: jecxz JXTGT # sched: [2:0.50] 1341 ; HASWELL-NEXT: #NO_APP 1342 ; HASWELL-NEXT: retl # sched: [7:1.00] 1343 ; 1344 ; BROADWELL-LABEL: test_jcxz_jecxz: 1345 ; BROADWELL: # %bb.0: 1346 ; BROADWELL-NEXT: #APP 1347 ; BROADWELL-NEXT: JXTGT: 1348 ; BROADWELL-NEXT: jcxz JXTGT # sched: [2:0.50] 1349 ; BROADWELL-NEXT: jecxz JXTGT # sched: [2:0.50] 1350 ; BROADWELL-NEXT: #NO_APP 1351 ; BROADWELL-NEXT: retl # sched: [6:0.50] 1352 ; 1353 ; SKYLAKE-LABEL: test_jcxz_jecxz: 1354 ; SKYLAKE: # %bb.0: 1355 ; SKYLAKE-NEXT: #APP 1356 ; SKYLAKE-NEXT: JXTGT: 1357 ; SKYLAKE-NEXT: jcxz JXTGT # sched: [2:0.50] 1358 ; SKYLAKE-NEXT: jecxz JXTGT # sched: [2:0.50] 1359 ; SKYLAKE-NEXT: #NO_APP 1360 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 1361 ; 1362 ; SKX-LABEL: test_jcxz_jecxz: 1363 ; SKX: # %bb.0: 1364 ; SKX-NEXT: #APP 1365 ; SKX-NEXT: JXTGT: 1366 ; SKX-NEXT: jcxz JXTGT # sched: [2:0.50] 1367 ; SKX-NEXT: jecxz JXTGT # sched: [2:0.50] 1368 ; SKX-NEXT: #NO_APP 1369 ; SKX-NEXT: retl # sched: [6:0.50] 1370 ; 1371 ; BTVER2-LABEL: test_jcxz_jecxz: 1372 ; BTVER2: # %bb.0: 1373 ; BTVER2-NEXT: #APP 1374 ; BTVER2-NEXT: JXTGT: 1375 ; BTVER2-NEXT: jcxz JXTGT # sched: [1:0.50] 1376 ; BTVER2-NEXT: jecxz JXTGT # sched: [1:0.50] 1377 ; BTVER2-NEXT: #NO_APP 1378 ; BTVER2-NEXT: retl # sched: [4:1.00] 1379 ; 1380 ; ZNVER1-LABEL: test_jcxz_jecxz: 1381 ; ZNVER1: # %bb.0: 1382 ; ZNVER1-NEXT: #APP 1383 ; ZNVER1-NEXT: JXTGT: 1384 ; ZNVER1-NEXT: jcxz JXTGT # sched: [1:0.50] 1385 ; ZNVER1-NEXT: jecxz JXTGT # sched: [1:0.50] 1386 ; ZNVER1-NEXT: #NO_APP 1387 ; ZNVER1-NEXT: retl # sched: [1:0.50] 1388 call void asm sideeffect "JXTGT: \0A\09 jcxz JXTGT \0A\09 jecxz JXTGT", ""() 1389 ret void 1390 } 1391 1392 ; TODO - test_lds 1393 1394 define void @test_leave() optsize { 1395 ; GENERIC-LABEL: test_leave: 1396 ; GENERIC: # %bb.0: 1397 ; GENERIC-NEXT: #APP 1398 ; GENERIC-NEXT: leave 1399 ; GENERIC-NEXT: #NO_APP 1400 ; GENERIC-NEXT: retl 1401 ; 1402 ; ATOM-LABEL: test_leave: 1403 ; ATOM: # %bb.0: 1404 ; ATOM-NEXT: #APP 1405 ; ATOM-NEXT: leave # sched: [2:1.00] 1406 ; ATOM-NEXT: #NO_APP 1407 ; ATOM-NEXT: retl # sched: [79:39.50] 1408 ; 1409 ; SLM-LABEL: test_leave: 1410 ; SLM: # %bb.0: 1411 ; SLM-NEXT: #APP 1412 ; SLM-NEXT: leave # sched: [1:0.50] 1413 ; SLM-NEXT: #NO_APP 1414 ; SLM-NEXT: retl # sched: [4:1.00] 1415 ; 1416 ; SANDY-LABEL: test_leave: 1417 ; SANDY: # %bb.0: 1418 ; SANDY-NEXT: #APP 1419 ; SANDY-NEXT: leave # sched: [7:0.67] 1420 ; SANDY-NEXT: #NO_APP 1421 ; SANDY-NEXT: retl # sched: [6:1.00] 1422 ; 1423 ; HASWELL-LABEL: test_leave: 1424 ; HASWELL: # %bb.0: 1425 ; HASWELL-NEXT: #APP 1426 ; HASWELL-NEXT: leave # sched: [7:0.50] 1427 ; HASWELL-NEXT: #NO_APP 1428 ; HASWELL-NEXT: retl # sched: [7:1.00] 1429 ; 1430 ; BROADWELL-LABEL: test_leave: 1431 ; BROADWELL: # %bb.0: 1432 ; BROADWELL-NEXT: #APP 1433 ; BROADWELL-NEXT: leave # sched: [7:0.50] 1434 ; BROADWELL-NEXT: #NO_APP 1435 ; BROADWELL-NEXT: retl # sched: [6:0.50] 1436 ; 1437 ; SKYLAKE-LABEL: test_leave: 1438 ; SKYLAKE: # %bb.0: 1439 ; SKYLAKE-NEXT: #APP 1440 ; SKYLAKE-NEXT: leave # sched: [7:0.50] 1441 ; SKYLAKE-NEXT: #NO_APP 1442 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 1443 ; 1444 ; SKX-LABEL: test_leave: 1445 ; SKX: # %bb.0: 1446 ; SKX-NEXT: #APP 1447 ; SKX-NEXT: leave # sched: [7:0.50] 1448 ; SKX-NEXT: #NO_APP 1449 ; SKX-NEXT: retl # sched: [6:0.50] 1450 ; 1451 ; BTVER2-LABEL: test_leave: 1452 ; BTVER2: # %bb.0: 1453 ; BTVER2-NEXT: #APP 1454 ; BTVER2-NEXT: leave # sched: [1:0.50] 1455 ; BTVER2-NEXT: #NO_APP 1456 ; BTVER2-NEXT: retl # sched: [4:1.00] 1457 ; 1458 ; ZNVER1-LABEL: test_leave: 1459 ; ZNVER1: # %bb.0: 1460 ; ZNVER1-NEXT: #APP 1461 ; ZNVER1-NEXT: leave # sched: [8:0.50] 1462 ; ZNVER1-NEXT: #NO_APP 1463 ; ZNVER1-NEXT: retl # sched: [1:0.50] 1464 tail call void asm "leave", ""() nounwind 1465 ret void 1466 } 1467 1468 ; TODO - test_les 1469 1470 define void @test_pop_push() optsize { 1471 ; GENERIC-LABEL: test_pop_push: 1472 ; GENERIC: # %bb.0: 1473 ; GENERIC-NEXT: #APP 1474 ; GENERIC-NEXT: popl %ds 1475 ; GENERIC-NEXT: popl %es 1476 ; GENERIC-NEXT: popl %ss 1477 ; GENERIC-NEXT: popl %fs 1478 ; GENERIC-NEXT: popl %gs 1479 ; GENERIC-NEXT: pushl %cs 1480 ; GENERIC-NEXT: pushl %ds 1481 ; GENERIC-NEXT: pushl %es 1482 ; GENERIC-NEXT: pushl %ss 1483 ; GENERIC-NEXT: pushl %fs 1484 ; GENERIC-NEXT: pushl %gs 1485 ; GENERIC-NEXT: #NO_APP 1486 ; GENERIC-NEXT: retl 1487 ; 1488 ; ATOM-LABEL: test_pop_push: 1489 ; ATOM: # %bb.0: 1490 ; ATOM-NEXT: #APP 1491 ; ATOM-NEXT: popl %ds # sched: [29:14.50] 1492 ; ATOM-NEXT: popl %es # sched: [29:14.50] 1493 ; ATOM-NEXT: popl %ss # sched: [48:24.00] 1494 ; ATOM-NEXT: popl %fs # sched: [29:14.50] 1495 ; ATOM-NEXT: popl %gs # sched: [29:14.50] 1496 ; ATOM-NEXT: pushl %cs # sched: [2:1.00] 1497 ; ATOM-NEXT: pushl %ds # sched: [2:1.00] 1498 ; ATOM-NEXT: pushl %es # sched: [2:1.00] 1499 ; ATOM-NEXT: pushl %ss # sched: [2:1.00] 1500 ; ATOM-NEXT: pushl %fs # sched: [2:1.00] 1501 ; ATOM-NEXT: pushl %gs # sched: [2:1.00] 1502 ; ATOM-NEXT: #NO_APP 1503 ; ATOM-NEXT: retl # sched: [79:39.50] 1504 ; 1505 ; SLM-LABEL: test_pop_push: 1506 ; SLM: # %bb.0: 1507 ; SLM-NEXT: #APP 1508 ; SLM-NEXT: popl %ds # sched: [100:1.00] 1509 ; SLM-NEXT: popl %es # sched: [100:1.00] 1510 ; SLM-NEXT: popl %ss # sched: [100:1.00] 1511 ; SLM-NEXT: popl %fs # sched: [100:1.00] 1512 ; SLM-NEXT: popl %gs # sched: [100:1.00] 1513 ; SLM-NEXT: pushl %cs # sched: [100:1.00] 1514 ; SLM-NEXT: pushl %ds # sched: [100:1.00] 1515 ; SLM-NEXT: pushl %es # sched: [100:1.00] 1516 ; SLM-NEXT: pushl %ss # sched: [100:1.00] 1517 ; SLM-NEXT: pushl %fs # sched: [100:1.00] 1518 ; SLM-NEXT: pushl %gs # sched: [100:1.00] 1519 ; SLM-NEXT: #NO_APP 1520 ; SLM-NEXT: retl # sched: [4:1.00] 1521 ; 1522 ; SANDY-LABEL: test_pop_push: 1523 ; SANDY: # %bb.0: 1524 ; SANDY-NEXT: #APP 1525 ; SANDY-NEXT: popl %ds # sched: [100:0.33] 1526 ; SANDY-NEXT: popl %es # sched: [100:0.33] 1527 ; SANDY-NEXT: popl %ss # sched: [100:0.33] 1528 ; SANDY-NEXT: popl %fs # sched: [100:0.33] 1529 ; SANDY-NEXT: popl %gs # sched: [100:0.33] 1530 ; SANDY-NEXT: pushl %cs # sched: [100:0.33] 1531 ; SANDY-NEXT: pushl %ds # sched: [100:0.33] 1532 ; SANDY-NEXT: pushl %es # sched: [100:0.33] 1533 ; SANDY-NEXT: pushl %ss # sched: [100:0.33] 1534 ; SANDY-NEXT: pushl %fs # sched: [100:0.33] 1535 ; SANDY-NEXT: pushl %gs # sched: [100:0.33] 1536 ; SANDY-NEXT: #NO_APP 1537 ; SANDY-NEXT: retl # sched: [6:1.00] 1538 ; 1539 ; HASWELL-LABEL: test_pop_push: 1540 ; HASWELL: # %bb.0: 1541 ; HASWELL-NEXT: #APP 1542 ; HASWELL-NEXT: popl %ds # sched: [100:0.25] 1543 ; HASWELL-NEXT: popl %es # sched: [100:0.25] 1544 ; HASWELL-NEXT: popl %ss # sched: [100:0.25] 1545 ; HASWELL-NEXT: popl %fs # sched: [100:0.25] 1546 ; HASWELL-NEXT: popl %gs # sched: [100:0.25] 1547 ; HASWELL-NEXT: pushl %cs # sched: [100:0.25] 1548 ; HASWELL-NEXT: pushl %ds # sched: [100:0.25] 1549 ; HASWELL-NEXT: pushl %es # sched: [100:0.25] 1550 ; HASWELL-NEXT: pushl %ss # sched: [100:0.25] 1551 ; HASWELL-NEXT: pushl %fs # sched: [100:0.25] 1552 ; HASWELL-NEXT: pushl %gs # sched: [100:0.25] 1553 ; HASWELL-NEXT: #NO_APP 1554 ; HASWELL-NEXT: retl # sched: [7:1.00] 1555 ; 1556 ; BROADWELL-LABEL: test_pop_push: 1557 ; BROADWELL: # %bb.0: 1558 ; BROADWELL-NEXT: #APP 1559 ; BROADWELL-NEXT: popl %ds # sched: [100:0.25] 1560 ; BROADWELL-NEXT: popl %es # sched: [100:0.25] 1561 ; BROADWELL-NEXT: popl %ss # sched: [100:0.25] 1562 ; BROADWELL-NEXT: popl %fs # sched: [100:0.25] 1563 ; BROADWELL-NEXT: popl %gs # sched: [100:0.25] 1564 ; BROADWELL-NEXT: pushl %cs # sched: [100:0.25] 1565 ; BROADWELL-NEXT: pushl %ds # sched: [100:0.25] 1566 ; BROADWELL-NEXT: pushl %es # sched: [100:0.25] 1567 ; BROADWELL-NEXT: pushl %ss # sched: [100:0.25] 1568 ; BROADWELL-NEXT: pushl %fs # sched: [100:0.25] 1569 ; BROADWELL-NEXT: pushl %gs # sched: [100:0.25] 1570 ; BROADWELL-NEXT: #NO_APP 1571 ; BROADWELL-NEXT: retl # sched: [6:0.50] 1572 ; 1573 ; SKYLAKE-LABEL: test_pop_push: 1574 ; SKYLAKE: # %bb.0: 1575 ; SKYLAKE-NEXT: #APP 1576 ; SKYLAKE-NEXT: popl %ds # sched: [100:0.25] 1577 ; SKYLAKE-NEXT: popl %es # sched: [100:0.25] 1578 ; SKYLAKE-NEXT: popl %ss # sched: [100:0.25] 1579 ; SKYLAKE-NEXT: popl %fs # sched: [100:0.25] 1580 ; SKYLAKE-NEXT: popl %gs # sched: [100:0.25] 1581 ; SKYLAKE-NEXT: pushl %cs # sched: [100:0.25] 1582 ; SKYLAKE-NEXT: pushl %ds # sched: [100:0.25] 1583 ; SKYLAKE-NEXT: pushl %es # sched: [100:0.25] 1584 ; SKYLAKE-NEXT: pushl %ss # sched: [100:0.25] 1585 ; SKYLAKE-NEXT: pushl %fs # sched: [100:0.25] 1586 ; SKYLAKE-NEXT: pushl %gs # sched: [100:0.25] 1587 ; SKYLAKE-NEXT: #NO_APP 1588 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 1589 ; 1590 ; SKX-LABEL: test_pop_push: 1591 ; SKX: # %bb.0: 1592 ; SKX-NEXT: #APP 1593 ; SKX-NEXT: popl %ds # sched: [100:0.25] 1594 ; SKX-NEXT: popl %es # sched: [100:0.25] 1595 ; SKX-NEXT: popl %ss # sched: [100:0.25] 1596 ; SKX-NEXT: popl %fs # sched: [100:0.25] 1597 ; SKX-NEXT: popl %gs # sched: [100:0.25] 1598 ; SKX-NEXT: pushl %cs # sched: [100:0.25] 1599 ; SKX-NEXT: pushl %ds # sched: [100:0.25] 1600 ; SKX-NEXT: pushl %es # sched: [100:0.25] 1601 ; SKX-NEXT: pushl %ss # sched: [100:0.25] 1602 ; SKX-NEXT: pushl %fs # sched: [100:0.25] 1603 ; SKX-NEXT: pushl %gs # sched: [100:0.25] 1604 ; SKX-NEXT: #NO_APP 1605 ; SKX-NEXT: retl # sched: [6:0.50] 1606 ; 1607 ; BTVER2-LABEL: test_pop_push: 1608 ; BTVER2: # %bb.0: 1609 ; BTVER2-NEXT: #APP 1610 ; BTVER2-NEXT: popl %ds # sched: [100:0.50] 1611 ; BTVER2-NEXT: popl %es # sched: [100:0.50] 1612 ; BTVER2-NEXT: popl %ss # sched: [100:0.50] 1613 ; BTVER2-NEXT: popl %fs # sched: [100:0.50] 1614 ; BTVER2-NEXT: popl %gs # sched: [100:0.50] 1615 ; BTVER2-NEXT: pushl %cs # sched: [100:0.50] 1616 ; BTVER2-NEXT: pushl %ds # sched: [100:0.50] 1617 ; BTVER2-NEXT: pushl %es # sched: [100:0.50] 1618 ; BTVER2-NEXT: pushl %ss # sched: [100:0.50] 1619 ; BTVER2-NEXT: pushl %fs # sched: [100:0.50] 1620 ; BTVER2-NEXT: pushl %gs # sched: [100:0.50] 1621 ; BTVER2-NEXT: #NO_APP 1622 ; BTVER2-NEXT: retl # sched: [4:1.00] 1623 ; 1624 ; ZNVER1-LABEL: test_pop_push: 1625 ; ZNVER1: # %bb.0: 1626 ; ZNVER1-NEXT: #APP 1627 ; ZNVER1-NEXT: popl %ds # sched: [100:0.25] 1628 ; ZNVER1-NEXT: popl %es # sched: [100:0.25] 1629 ; ZNVER1-NEXT: popl %ss # sched: [100:0.25] 1630 ; ZNVER1-NEXT: popl %fs # sched: [100:0.25] 1631 ; ZNVER1-NEXT: popl %gs # sched: [100:0.25] 1632 ; ZNVER1-NEXT: pushl %cs # sched: [100:0.25] 1633 ; ZNVER1-NEXT: pushl %ds # sched: [100:0.25] 1634 ; ZNVER1-NEXT: pushl %es # sched: [100:0.25] 1635 ; ZNVER1-NEXT: pushl %ss # sched: [100:0.25] 1636 ; ZNVER1-NEXT: pushl %fs # sched: [100:0.25] 1637 ; ZNVER1-NEXT: pushl %gs # sched: [100:0.25] 1638 ; ZNVER1-NEXT: #NO_APP 1639 ; ZNVER1-NEXT: retl # sched: [1:0.50] 1640 call void asm sideeffect "pop %DS \0A\09 pop %ES \0A\09 pop %SS \0A\09 pop %FS \0A\09 pop %GS \0A\09 push %CS \0A\09 push %DS \0A\09 push %ES \0A\09 push %SS \0A\09 push %FS \0A\09 push %GS", ""() 1641 ret void 1642 } 1643 define i16 @test_pop_push_16(i16 %a0, i16 *%a1) optsize { 1644 ; GENERIC-LABEL: test_pop_push_16: 1645 ; GENERIC: # %bb.0: 1646 ; GENERIC-NEXT: movzwl {{[0-9]+}}(%esp), %eax 1647 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %ecx 1648 ; GENERIC-NEXT: #APP 1649 ; GENERIC-NEXT: popw %ax 1650 ; GENERIC-NEXT: popw (%ecx) 1651 ; GENERIC-NEXT: pushw %ax 1652 ; GENERIC-NEXT: pushw (%ecx) 1653 ; GENERIC-NEXT: pushw $4095 # imm = 0xFFF 1654 ; GENERIC-NEXT: pushw $7 1655 ; GENERIC-NEXT: #NO_APP 1656 ; GENERIC-NEXT: retl 1657 ; 1658 ; ATOM-LABEL: test_pop_push_16: 1659 ; ATOM: # %bb.0: 1660 ; ATOM-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [1:1.00] 1661 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [1:1.00] 1662 ; ATOM-NEXT: #APP 1663 ; ATOM-NEXT: popw %ax # sched: [2:1.00] 1664 ; ATOM-NEXT: popw (%ecx) # sched: [3:1.50] 1665 ; ATOM-NEXT: pushw %ax # sched: [1:1.00] 1666 ; ATOM-NEXT: pushw (%ecx) # sched: [2:1.00] 1667 ; ATOM-NEXT: pushw $4095 # imm = 0xFFF 1668 ; ATOM-NEXT: # sched: [1:1.00] 1669 ; ATOM-NEXT: pushw $7 # sched: [1:1.00] 1670 ; ATOM-NEXT: #NO_APP 1671 ; ATOM-NEXT: retl # sched: [79:39.50] 1672 ; 1673 ; SLM-LABEL: test_pop_push_16: 1674 ; SLM: # %bb.0: 1675 ; SLM-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [4:1.00] 1676 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [3:1.00] 1677 ; SLM-NEXT: #APP 1678 ; SLM-NEXT: popw %ax # sched: [3:1.00] 1679 ; SLM-NEXT: popw (%ecx) # sched: [1:1.00] 1680 ; SLM-NEXT: pushw %ax # sched: [1:1.00] 1681 ; SLM-NEXT: pushw (%ecx) # sched: [1:1.00] 1682 ; SLM-NEXT: pushw $4095 # imm = 0xFFF 1683 ; SLM-NEXT: # sched: [1:1.00] 1684 ; SLM-NEXT: pushw $7 # sched: [1:1.00] 1685 ; SLM-NEXT: #NO_APP 1686 ; SLM-NEXT: retl # sched: [4:1.00] 1687 ; 1688 ; SANDY-LABEL: test_pop_push_16: 1689 ; SANDY: # %bb.0: 1690 ; SANDY-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1691 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1692 ; SANDY-NEXT: #APP 1693 ; SANDY-NEXT: popw %ax # sched: [6:0.50] 1694 ; SANDY-NEXT: popw (%ecx) # sched: [6:0.50] 1695 ; SANDY-NEXT: pushw %ax # sched: [5:1.00] 1696 ; SANDY-NEXT: pushw (%ecx) # sched: [5:1.00] 1697 ; SANDY-NEXT: pushw $4095 # imm = 0xFFF 1698 ; SANDY-NEXT: # sched: [1:1.00] 1699 ; SANDY-NEXT: pushw $7 # sched: [1:1.00] 1700 ; SANDY-NEXT: #NO_APP 1701 ; SANDY-NEXT: retl # sched: [6:1.00] 1702 ; 1703 ; HASWELL-LABEL: test_pop_push_16: 1704 ; HASWELL: # %bb.0: 1705 ; HASWELL-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1706 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1707 ; HASWELL-NEXT: #APP 1708 ; HASWELL-NEXT: popw %ax # sched: [6:0.50] 1709 ; HASWELL-NEXT: popw (%ecx) # sched: [7:1.00] 1710 ; HASWELL-NEXT: pushw %ax # sched: [2:1.00] 1711 ; HASWELL-NEXT: pushw (%ecx) # sched: [7:1.00] 1712 ; HASWELL-NEXT: pushw $4095 # imm = 0xFFF 1713 ; HASWELL-NEXT: # sched: [1:1.00] 1714 ; HASWELL-NEXT: pushw $7 # sched: [1:1.00] 1715 ; HASWELL-NEXT: #NO_APP 1716 ; HASWELL-NEXT: retl # sched: [7:1.00] 1717 ; 1718 ; BROADWELL-LABEL: test_pop_push_16: 1719 ; BROADWELL: # %bb.0: 1720 ; BROADWELL-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1721 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1722 ; BROADWELL-NEXT: #APP 1723 ; BROADWELL-NEXT: popw %ax # sched: [6:0.50] 1724 ; BROADWELL-NEXT: popw (%ecx) # sched: [6:1.00] 1725 ; BROADWELL-NEXT: pushw %ax # sched: [2:1.00] 1726 ; BROADWELL-NEXT: pushw (%ecx) # sched: [6:1.00] 1727 ; BROADWELL-NEXT: pushw $4095 # imm = 0xFFF 1728 ; BROADWELL-NEXT: # sched: [1:1.00] 1729 ; BROADWELL-NEXT: pushw $7 # sched: [1:1.00] 1730 ; BROADWELL-NEXT: #NO_APP 1731 ; BROADWELL-NEXT: retl # sched: [6:0.50] 1732 ; 1733 ; SKYLAKE-LABEL: test_pop_push_16: 1734 ; SKYLAKE: # %bb.0: 1735 ; SKYLAKE-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1736 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1737 ; SKYLAKE-NEXT: #APP 1738 ; SKYLAKE-NEXT: popw %ax # sched: [6:0.50] 1739 ; SKYLAKE-NEXT: popw (%ecx) # sched: [6:1.00] 1740 ; SKYLAKE-NEXT: pushw %ax # sched: [2:1.00] 1741 ; SKYLAKE-NEXT: pushw (%ecx) # sched: [6:1.00] 1742 ; SKYLAKE-NEXT: pushw $4095 # imm = 0xFFF 1743 ; SKYLAKE-NEXT: # sched: [1:1.00] 1744 ; SKYLAKE-NEXT: pushw $7 # sched: [1:1.00] 1745 ; SKYLAKE-NEXT: #NO_APP 1746 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 1747 ; 1748 ; SKX-LABEL: test_pop_push_16: 1749 ; SKX: # %bb.0: 1750 ; SKX-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1751 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1752 ; SKX-NEXT: #APP 1753 ; SKX-NEXT: popw %ax # sched: [6:0.50] 1754 ; SKX-NEXT: popw (%ecx) # sched: [6:1.00] 1755 ; SKX-NEXT: pushw %ax # sched: [2:1.00] 1756 ; SKX-NEXT: pushw (%ecx) # sched: [6:1.00] 1757 ; SKX-NEXT: pushw $4095 # imm = 0xFFF 1758 ; SKX-NEXT: # sched: [1:1.00] 1759 ; SKX-NEXT: pushw $7 # sched: [1:1.00] 1760 ; SKX-NEXT: #NO_APP 1761 ; SKX-NEXT: retl # sched: [6:0.50] 1762 ; 1763 ; BTVER2-LABEL: test_pop_push_16: 1764 ; BTVER2: # %bb.0: 1765 ; BTVER2-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [4:1.00] 1766 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:1.00] 1767 ; BTVER2-NEXT: #APP 1768 ; BTVER2-NEXT: popw %ax # sched: [5:1.00] 1769 ; BTVER2-NEXT: popw (%ecx) # sched: [1:1.00] 1770 ; BTVER2-NEXT: pushw %ax # sched: [1:1.00] 1771 ; BTVER2-NEXT: pushw (%ecx) # sched: [1:1.00] 1772 ; BTVER2-NEXT: pushw $4095 # imm = 0xFFF 1773 ; BTVER2-NEXT: # sched: [1:1.00] 1774 ; BTVER2-NEXT: pushw $7 # sched: [1:1.00] 1775 ; BTVER2-NEXT: #NO_APP 1776 ; BTVER2-NEXT: retl # sched: [4:1.00] 1777 ; 1778 ; ZNVER1-LABEL: test_pop_push_16: 1779 ; ZNVER1: # %bb.0: 1780 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [8:0.50] 1781 ; ZNVER1-NEXT: movzwl {{[0-9]+}}(%esp), %eax # sched: [8:0.50] 1782 ; ZNVER1-NEXT: #APP 1783 ; ZNVER1-NEXT: popw %ax # sched: [8:0.50] 1784 ; ZNVER1-NEXT: popw (%ecx) # sched: [5:0.50] 1785 ; ZNVER1-NEXT: pushw %ax # sched: [1:0.50] 1786 ; ZNVER1-NEXT: pushw (%ecx) # sched: [4:0.50] 1787 ; ZNVER1-NEXT: pushw $4095 # imm = 0xFFF 1788 ; ZNVER1-NEXT: # sched: [1:0.50] 1789 ; ZNVER1-NEXT: pushw $7 # sched: [1:0.50] 1790 ; ZNVER1-NEXT: #NO_APP 1791 ; ZNVER1-NEXT: retl # sched: [1:0.50] 1792 %1 = call i16 asm sideeffect "popw $0 \0A\09 popw $2 \0A\09 pushw $1 \0A\09 pushw $2 \0A\09 pushw $3 \0A\09 pushw $4", "=r,r,*m,i,i"(i16 %a0, i16 *%a1, i16 4095, i8 7) 1793 ret i16 %1 1794 } 1795 define i32 @test_pop_push_32(i32 %a0, i32 *%a1) optsize { 1796 ; GENERIC-LABEL: test_pop_push_32: 1797 ; GENERIC: # %bb.0: 1798 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %eax 1799 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %ecx 1800 ; GENERIC-NEXT: #APP 1801 ; GENERIC-NEXT: popl %eax 1802 ; GENERIC-NEXT: popl (%ecx) 1803 ; GENERIC-NEXT: pushl %eax 1804 ; GENERIC-NEXT: pushl (%ecx) 1805 ; GENERIC-NEXT: pushl $4095 # imm = 0xFFF 1806 ; GENERIC-NEXT: pushl $7 1807 ; GENERIC-NEXT: #NO_APP 1808 ; GENERIC-NEXT: retl 1809 ; 1810 ; ATOM-LABEL: test_pop_push_32: 1811 ; ATOM: # %bb.0: 1812 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [1:1.00] 1813 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [1:1.00] 1814 ; ATOM-NEXT: #APP 1815 ; ATOM-NEXT: popl %eax # sched: [1:1.00] 1816 ; ATOM-NEXT: popl (%ecx) # sched: [3:1.50] 1817 ; ATOM-NEXT: pushl %eax # sched: [1:1.00] 1818 ; ATOM-NEXT: pushl (%ecx) # sched: [2:1.00] 1819 ; ATOM-NEXT: pushl $4095 # imm = 0xFFF 1820 ; ATOM-NEXT: # sched: [1:1.00] 1821 ; ATOM-NEXT: pushl $7 # sched: [1:1.00] 1822 ; ATOM-NEXT: #NO_APP 1823 ; ATOM-NEXT: retl # sched: [79:39.50] 1824 ; 1825 ; SLM-LABEL: test_pop_push_32: 1826 ; SLM: # %bb.0: 1827 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [3:1.00] 1828 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [3:1.00] 1829 ; SLM-NEXT: #APP 1830 ; SLM-NEXT: popl %eax # sched: [3:1.00] 1831 ; SLM-NEXT: popl (%ecx) # sched: [1:1.00] 1832 ; SLM-NEXT: pushl %eax # sched: [1:1.00] 1833 ; SLM-NEXT: pushl (%ecx) # sched: [1:1.00] 1834 ; SLM-NEXT: pushl $4095 # imm = 0xFFF 1835 ; SLM-NEXT: # sched: [1:1.00] 1836 ; SLM-NEXT: pushl $7 # sched: [1:1.00] 1837 ; SLM-NEXT: #NO_APP 1838 ; SLM-NEXT: retl # sched: [4:1.00] 1839 ; 1840 ; SANDY-LABEL: test_pop_push_32: 1841 ; SANDY: # %bb.0: 1842 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1843 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1844 ; SANDY-NEXT: #APP 1845 ; SANDY-NEXT: popl %eax # sched: [6:0.50] 1846 ; SANDY-NEXT: popl (%ecx) # sched: [6:0.50] 1847 ; SANDY-NEXT: pushl %eax # sched: [5:1.00] 1848 ; SANDY-NEXT: pushl (%ecx) # sched: [5:1.00] 1849 ; SANDY-NEXT: pushl $4095 # imm = 0xFFF 1850 ; SANDY-NEXT: # sched: [1:1.00] 1851 ; SANDY-NEXT: pushl $7 # sched: [1:1.00] 1852 ; SANDY-NEXT: #NO_APP 1853 ; SANDY-NEXT: retl # sched: [6:1.00] 1854 ; 1855 ; HASWELL-LABEL: test_pop_push_32: 1856 ; HASWELL: # %bb.0: 1857 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1858 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1859 ; HASWELL-NEXT: #APP 1860 ; HASWELL-NEXT: popl %eax # sched: [6:0.50] 1861 ; HASWELL-NEXT: popl (%ecx) # sched: [7:1.00] 1862 ; HASWELL-NEXT: pushl %eax # sched: [2:1.00] 1863 ; HASWELL-NEXT: pushl (%ecx) # sched: [7:1.00] 1864 ; HASWELL-NEXT: pushl $4095 # imm = 0xFFF 1865 ; HASWELL-NEXT: # sched: [1:1.00] 1866 ; HASWELL-NEXT: pushl $7 # sched: [1:1.00] 1867 ; HASWELL-NEXT: #NO_APP 1868 ; HASWELL-NEXT: retl # sched: [7:1.00] 1869 ; 1870 ; BROADWELL-LABEL: test_pop_push_32: 1871 ; BROADWELL: # %bb.0: 1872 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1873 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1874 ; BROADWELL-NEXT: #APP 1875 ; BROADWELL-NEXT: popl %eax # sched: [6:0.50] 1876 ; BROADWELL-NEXT: popl (%ecx) # sched: [6:1.00] 1877 ; BROADWELL-NEXT: pushl %eax # sched: [2:1.00] 1878 ; BROADWELL-NEXT: pushl (%ecx) # sched: [6:1.00] 1879 ; BROADWELL-NEXT: pushl $4095 # imm = 0xFFF 1880 ; BROADWELL-NEXT: # sched: [1:1.00] 1881 ; BROADWELL-NEXT: pushl $7 # sched: [1:1.00] 1882 ; BROADWELL-NEXT: #NO_APP 1883 ; BROADWELL-NEXT: retl # sched: [6:0.50] 1884 ; 1885 ; SKYLAKE-LABEL: test_pop_push_32: 1886 ; SKYLAKE: # %bb.0: 1887 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1888 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1889 ; SKYLAKE-NEXT: #APP 1890 ; SKYLAKE-NEXT: popl %eax # sched: [6:0.50] 1891 ; SKYLAKE-NEXT: popl (%ecx) # sched: [6:1.00] 1892 ; SKYLAKE-NEXT: pushl %eax # sched: [2:1.00] 1893 ; SKYLAKE-NEXT: pushl (%ecx) # sched: [6:1.00] 1894 ; SKYLAKE-NEXT: pushl $4095 # imm = 0xFFF 1895 ; SKYLAKE-NEXT: # sched: [1:1.00] 1896 ; SKYLAKE-NEXT: pushl $7 # sched: [1:1.00] 1897 ; SKYLAKE-NEXT: #NO_APP 1898 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 1899 ; 1900 ; SKX-LABEL: test_pop_push_32: 1901 ; SKX: # %bb.0: 1902 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 1903 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 1904 ; SKX-NEXT: #APP 1905 ; SKX-NEXT: popl %eax # sched: [6:0.50] 1906 ; SKX-NEXT: popl (%ecx) # sched: [6:1.00] 1907 ; SKX-NEXT: pushl %eax # sched: [2:1.00] 1908 ; SKX-NEXT: pushl (%ecx) # sched: [6:1.00] 1909 ; SKX-NEXT: pushl $4095 # imm = 0xFFF 1910 ; SKX-NEXT: # sched: [1:1.00] 1911 ; SKX-NEXT: pushl $7 # sched: [1:1.00] 1912 ; SKX-NEXT: #NO_APP 1913 ; SKX-NEXT: retl # sched: [6:0.50] 1914 ; 1915 ; BTVER2-LABEL: test_pop_push_32: 1916 ; BTVER2: # %bb.0: 1917 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:1.00] 1918 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:1.00] 1919 ; BTVER2-NEXT: #APP 1920 ; BTVER2-NEXT: popl %eax # sched: [5:1.00] 1921 ; BTVER2-NEXT: popl (%ecx) # sched: [1:1.00] 1922 ; BTVER2-NEXT: pushl %eax # sched: [1:1.00] 1923 ; BTVER2-NEXT: pushl (%ecx) # sched: [1:1.00] 1924 ; BTVER2-NEXT: pushl $4095 # imm = 0xFFF 1925 ; BTVER2-NEXT: # sched: [1:1.00] 1926 ; BTVER2-NEXT: pushl $7 # sched: [1:1.00] 1927 ; BTVER2-NEXT: #NO_APP 1928 ; BTVER2-NEXT: retl # sched: [4:1.00] 1929 ; 1930 ; ZNVER1-LABEL: test_pop_push_32: 1931 ; ZNVER1: # %bb.0: 1932 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [8:0.50] 1933 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [8:0.50] 1934 ; ZNVER1-NEXT: #APP 1935 ; ZNVER1-NEXT: popl %eax # sched: [8:0.50] 1936 ; ZNVER1-NEXT: popl (%ecx) # sched: [1:0.50] 1937 ; ZNVER1-NEXT: pushl %eax # sched: [1:0.50] 1938 ; ZNVER1-NEXT: pushl (%ecx) # sched: [4:0.50] 1939 ; ZNVER1-NEXT: pushl $4095 # imm = 0xFFF 1940 ; ZNVER1-NEXT: # sched: [1:0.50] 1941 ; ZNVER1-NEXT: pushl $7 # sched: [1:0.50] 1942 ; ZNVER1-NEXT: #NO_APP 1943 ; ZNVER1-NEXT: retl # sched: [1:0.50] 1944 %1 = call i32 asm sideeffect "popl $0 \0A\09 popl $2 \0A\09 pushl $1 \0A\09 pushl $2 \0A\09 pushl $3 \0A\09 pushl $4", "=r,r,*m,i,i"(i32 %a0, i32 *%a1, i32 4095, i8 7) 1945 ret i32 %1 1946 } 1947 1948 define void @test_popa_popf_pusha_pushf() optsize { 1949 ; GENERIC-LABEL: test_popa_popf_pusha_pushf: 1950 ; GENERIC: # %bb.0: 1951 ; GENERIC-NEXT: #APP 1952 ; GENERIC-NEXT: popal 1953 ; GENERIC-NEXT: popfl 1954 ; GENERIC-NEXT: pushal 1955 ; GENERIC-NEXT: pushfl 1956 ; GENERIC-NEXT: #NO_APP 1957 ; GENERIC-NEXT: retl 1958 ; 1959 ; ATOM-LABEL: test_popa_popf_pusha_pushf: 1960 ; ATOM: # %bb.0: 1961 ; ATOM-NEXT: #APP 1962 ; ATOM-NEXT: popal # sched: [9:4.50] 1963 ; ATOM-NEXT: popfl # sched: [26:13.00] 1964 ; ATOM-NEXT: pushal # sched: [8:4.00] 1965 ; ATOM-NEXT: pushfl # sched: [9:4.50] 1966 ; ATOM-NEXT: #NO_APP 1967 ; ATOM-NEXT: retl # sched: [79:39.50] 1968 ; 1969 ; SLM-LABEL: test_popa_popf_pusha_pushf: 1970 ; SLM: # %bb.0: 1971 ; SLM-NEXT: #APP 1972 ; SLM-NEXT: popal # sched: [3:1.00] 1973 ; SLM-NEXT: popfl # sched: [3:1.00] 1974 ; SLM-NEXT: pushal # sched: [1:1.00] 1975 ; SLM-NEXT: pushfl # sched: [1:1.00] 1976 ; SLM-NEXT: #NO_APP 1977 ; SLM-NEXT: retl # sched: [4:1.00] 1978 ; 1979 ; SANDY-LABEL: test_popa_popf_pusha_pushf: 1980 ; SANDY: # %bb.0: 1981 ; SANDY-NEXT: #APP 1982 ; SANDY-NEXT: popal # sched: [5:0.50] 1983 ; SANDY-NEXT: popfl # sched: [5:0.50] 1984 ; SANDY-NEXT: pushal # sched: [1:1.00] 1985 ; SANDY-NEXT: pushfl # sched: [1:1.00] 1986 ; SANDY-NEXT: #NO_APP 1987 ; SANDY-NEXT: retl # sched: [6:1.00] 1988 ; 1989 ; HASWELL-LABEL: test_popa_popf_pusha_pushf: 1990 ; HASWELL: # %bb.0: 1991 ; HASWELL-NEXT: #APP 1992 ; HASWELL-NEXT: popal # sched: [1:4.50] 1993 ; HASWELL-NEXT: popfl # sched: [5:0.50] 1994 ; HASWELL-NEXT: pushal # sched: [1:4.75] 1995 ; HASWELL-NEXT: pushfl # sched: [1:1.00] 1996 ; HASWELL-NEXT: #NO_APP 1997 ; HASWELL-NEXT: retl # sched: [7:1.00] 1998 ; 1999 ; BROADWELL-LABEL: test_popa_popf_pusha_pushf: 2000 ; BROADWELL: # %bb.0: 2001 ; BROADWELL-NEXT: #APP 2002 ; BROADWELL-NEXT: popal # sched: [5:0.50] 2003 ; BROADWELL-NEXT: popfl # sched: [5:0.50] 2004 ; BROADWELL-NEXT: pushal # sched: [1:1.00] 2005 ; BROADWELL-NEXT: pushfl # sched: [1:1.00] 2006 ; BROADWELL-NEXT: #NO_APP 2007 ; BROADWELL-NEXT: retl # sched: [6:0.50] 2008 ; 2009 ; SKYLAKE-LABEL: test_popa_popf_pusha_pushf: 2010 ; SKYLAKE: # %bb.0: 2011 ; SKYLAKE-NEXT: #APP 2012 ; SKYLAKE-NEXT: popal # sched: [5:0.50] 2013 ; SKYLAKE-NEXT: popfl # sched: [5:0.50] 2014 ; SKYLAKE-NEXT: pushal # sched: [1:1.00] 2015 ; SKYLAKE-NEXT: pushfl # sched: [1:1.00] 2016 ; SKYLAKE-NEXT: #NO_APP 2017 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 2018 ; 2019 ; SKX-LABEL: test_popa_popf_pusha_pushf: 2020 ; SKX: # %bb.0: 2021 ; SKX-NEXT: #APP 2022 ; SKX-NEXT: popal # sched: [5:0.50] 2023 ; SKX-NEXT: popfl # sched: [5:0.50] 2024 ; SKX-NEXT: pushal # sched: [1:1.00] 2025 ; SKX-NEXT: pushfl # sched: [1:1.00] 2026 ; SKX-NEXT: #NO_APP 2027 ; SKX-NEXT: retl # sched: [6:0.50] 2028 ; 2029 ; BTVER2-LABEL: test_popa_popf_pusha_pushf: 2030 ; BTVER2: # %bb.0: 2031 ; BTVER2-NEXT: #APP 2032 ; BTVER2-NEXT: popal # sched: [5:1.00] 2033 ; BTVER2-NEXT: popfl # sched: [5:1.00] 2034 ; BTVER2-NEXT: pushal # sched: [1:1.00] 2035 ; BTVER2-NEXT: pushfl # sched: [1:1.00] 2036 ; BTVER2-NEXT: #NO_APP 2037 ; BTVER2-NEXT: retl # sched: [4:1.00] 2038 ; 2039 ; ZNVER1-LABEL: test_popa_popf_pusha_pushf: 2040 ; ZNVER1: # %bb.0: 2041 ; ZNVER1-NEXT: #APP 2042 ; ZNVER1-NEXT: popal # sched: [100:0.25] 2043 ; ZNVER1-NEXT: popfl # sched: [100:0.25] 2044 ; ZNVER1-NEXT: pushal # sched: [8:0.50] 2045 ; ZNVER1-NEXT: pushfl # sched: [100:0.25] 2046 ; ZNVER1-NEXT: #NO_APP 2047 ; ZNVER1-NEXT: retl # sched: [1:0.50] 2048 call void asm sideeffect "popa \0A\09 popf \0A\09 pusha \0A\09 pushf", ""() 2049 ret void 2050 } 2051 2052 define void @test_ret() optsize { 2053 ; GENERIC-LABEL: test_ret: 2054 ; GENERIC: # %bb.0: 2055 ; GENERIC-NEXT: #APP 2056 ; GENERIC-NEXT: retl 2057 ; GENERIC-NEXT: retl $4095 # imm = 0xFFF 2058 ; GENERIC-NEXT: lretl 2059 ; GENERIC-NEXT: lretl $4095 # imm = 0xFFF 2060 ; GENERIC-NEXT: #NO_APP 2061 ; GENERIC-NEXT: retl 2062 ; 2063 ; ATOM-LABEL: test_ret: 2064 ; ATOM: # %bb.0: 2065 ; ATOM-NEXT: #APP 2066 ; ATOM-NEXT: retl # sched: [79:39.50] 2067 ; ATOM-NEXT: retl $4095 # imm = 0xFFF 2068 ; ATOM-NEXT: # sched: [1:1.00] 2069 ; ATOM-NEXT: lretl # sched: [79:39.50] 2070 ; ATOM-NEXT: lretl $4095 # imm = 0xFFF 2071 ; ATOM-NEXT: # sched: [79:39.50] 2072 ; ATOM-NEXT: #NO_APP 2073 ; ATOM-NEXT: retl # sched: [79:39.50] 2074 ; 2075 ; SLM-LABEL: test_ret: 2076 ; SLM: # %bb.0: 2077 ; SLM-NEXT: #APP 2078 ; SLM-NEXT: retl # sched: [4:1.00] 2079 ; SLM-NEXT: retl $4095 # imm = 0xFFF 2080 ; SLM-NEXT: # sched: [4:1.00] 2081 ; SLM-NEXT: lretl # sched: [4:1.00] 2082 ; SLM-NEXT: lretl $4095 # imm = 0xFFF 2083 ; SLM-NEXT: # sched: [4:1.00] 2084 ; SLM-NEXT: #NO_APP 2085 ; SLM-NEXT: retl # sched: [4:1.00] 2086 ; 2087 ; SANDY-LABEL: test_ret: 2088 ; SANDY: # %bb.0: 2089 ; SANDY-NEXT: #APP 2090 ; SANDY-NEXT: retl # sched: [6:1.00] 2091 ; SANDY-NEXT: retl $4095 # imm = 0xFFF 2092 ; SANDY-NEXT: # sched: [6:1.00] 2093 ; SANDY-NEXT: lretl # sched: [6:1.00] 2094 ; SANDY-NEXT: lretl $4095 # imm = 0xFFF 2095 ; SANDY-NEXT: # sched: [6:1.00] 2096 ; SANDY-NEXT: #NO_APP 2097 ; SANDY-NEXT: retl # sched: [6:1.00] 2098 ; 2099 ; HASWELL-LABEL: test_ret: 2100 ; HASWELL: # %bb.0: 2101 ; HASWELL-NEXT: #APP 2102 ; HASWELL-NEXT: retl # sched: [7:1.00] 2103 ; HASWELL-NEXT: retl $4095 # imm = 0xFFF 2104 ; HASWELL-NEXT: # sched: [1:2.00] 2105 ; HASWELL-NEXT: lretl # sched: [6:0.50] 2106 ; HASWELL-NEXT: lretl $4095 # imm = 0xFFF 2107 ; HASWELL-NEXT: # sched: [1:2.00] 2108 ; HASWELL-NEXT: #NO_APP 2109 ; HASWELL-NEXT: retl # sched: [7:1.00] 2110 ; 2111 ; BROADWELL-LABEL: test_ret: 2112 ; BROADWELL: # %bb.0: 2113 ; BROADWELL-NEXT: #APP 2114 ; BROADWELL-NEXT: retl # sched: [6:0.50] 2115 ; BROADWELL-NEXT: retl $4095 # imm = 0xFFF 2116 ; BROADWELL-NEXT: # sched: [6:0.50] 2117 ; BROADWELL-NEXT: lretl # sched: [6:0.50] 2118 ; BROADWELL-NEXT: lretl $4095 # imm = 0xFFF 2119 ; BROADWELL-NEXT: # sched: [6:0.50] 2120 ; BROADWELL-NEXT: #NO_APP 2121 ; BROADWELL-NEXT: retl # sched: [6:0.50] 2122 ; 2123 ; SKYLAKE-LABEL: test_ret: 2124 ; SKYLAKE: # %bb.0: 2125 ; SKYLAKE-NEXT: #APP 2126 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 2127 ; SKYLAKE-NEXT: retl $4095 # imm = 0xFFF 2128 ; SKYLAKE-NEXT: # sched: [6:0.50] 2129 ; SKYLAKE-NEXT: lretl # sched: [6:0.50] 2130 ; SKYLAKE-NEXT: lretl $4095 # imm = 0xFFF 2131 ; SKYLAKE-NEXT: # sched: [6:0.50] 2132 ; SKYLAKE-NEXT: #NO_APP 2133 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 2134 ; 2135 ; SKX-LABEL: test_ret: 2136 ; SKX: # %bb.0: 2137 ; SKX-NEXT: #APP 2138 ; SKX-NEXT: retl # sched: [6:0.50] 2139 ; SKX-NEXT: retl $4095 # imm = 0xFFF 2140 ; SKX-NEXT: # sched: [6:0.50] 2141 ; SKX-NEXT: lretl # sched: [6:0.50] 2142 ; SKX-NEXT: lretl $4095 # imm = 0xFFF 2143 ; SKX-NEXT: # sched: [6:0.50] 2144 ; SKX-NEXT: #NO_APP 2145 ; SKX-NEXT: retl # sched: [6:0.50] 2146 ; 2147 ; BTVER2-LABEL: test_ret: 2148 ; BTVER2: # %bb.0: 2149 ; BTVER2-NEXT: #APP 2150 ; BTVER2-NEXT: retl # sched: [4:1.00] 2151 ; BTVER2-NEXT: retl $4095 # imm = 0xFFF 2152 ; BTVER2-NEXT: # sched: [4:1.00] 2153 ; BTVER2-NEXT: lretl # sched: [4:1.00] 2154 ; BTVER2-NEXT: lretl $4095 # imm = 0xFFF 2155 ; BTVER2-NEXT: # sched: [4:1.00] 2156 ; BTVER2-NEXT: #NO_APP 2157 ; BTVER2-NEXT: retl # sched: [4:1.00] 2158 ; 2159 ; ZNVER1-LABEL: test_ret: 2160 ; ZNVER1: # %bb.0: 2161 ; ZNVER1-NEXT: #APP 2162 ; ZNVER1-NEXT: retl # sched: [1:0.50] 2163 ; ZNVER1-NEXT: retl $4095 # imm = 0xFFF 2164 ; ZNVER1-NEXT: # sched: [5:0.50] 2165 ; ZNVER1-NEXT: lretl # sched: [1:0.50] 2166 ; ZNVER1-NEXT: lretl $4095 # imm = 0xFFF 2167 ; ZNVER1-NEXT: # sched: [5:0.50] 2168 ; ZNVER1-NEXT: #NO_APP 2169 ; ZNVER1-NEXT: retl # sched: [1:0.50] 2170 call void asm sideeffect "ret \0A\09 ret $0 \0A\09 lret \0A\09 lret $0", "i"(i16 4095) 2171 ret void 2172 } 2173 2174 define i8 @test_salc() optsize { 2175 ; GENERIC-LABEL: test_salc: 2176 ; GENERIC: # %bb.0: 2177 ; GENERIC-NEXT: #APP 2178 ; GENERIC-NEXT: salc 2179 ; GENERIC-NEXT: #NO_APP 2180 ; GENERIC-NEXT: retl 2181 ; 2182 ; ATOM-LABEL: test_salc: 2183 ; ATOM: # %bb.0: 2184 ; ATOM-NEXT: #APP 2185 ; ATOM-NEXT: salc # sched: [1:0.50] 2186 ; ATOM-NEXT: #NO_APP 2187 ; ATOM-NEXT: retl # sched: [79:39.50] 2188 ; 2189 ; SLM-LABEL: test_salc: 2190 ; SLM: # %bb.0: 2191 ; SLM-NEXT: #APP 2192 ; SLM-NEXT: salc # sched: [1:0.50] 2193 ; SLM-NEXT: #NO_APP 2194 ; SLM-NEXT: retl # sched: [4:1.00] 2195 ; 2196 ; SANDY-LABEL: test_salc: 2197 ; SANDY: # %bb.0: 2198 ; SANDY-NEXT: #APP 2199 ; SANDY-NEXT: salc # sched: [1:0.33] 2200 ; SANDY-NEXT: #NO_APP 2201 ; SANDY-NEXT: retl # sched: [6:1.00] 2202 ; 2203 ; HASWELL-LABEL: test_salc: 2204 ; HASWELL: # %bb.0: 2205 ; HASWELL-NEXT: #APP 2206 ; HASWELL-NEXT: salc # sched: [1:0.25] 2207 ; HASWELL-NEXT: #NO_APP 2208 ; HASWELL-NEXT: retl # sched: [7:1.00] 2209 ; 2210 ; BROADWELL-LABEL: test_salc: 2211 ; BROADWELL: # %bb.0: 2212 ; BROADWELL-NEXT: #APP 2213 ; BROADWELL-NEXT: salc # sched: [1:0.25] 2214 ; BROADWELL-NEXT: #NO_APP 2215 ; BROADWELL-NEXT: retl # sched: [6:0.50] 2216 ; 2217 ; SKYLAKE-LABEL: test_salc: 2218 ; SKYLAKE: # %bb.0: 2219 ; SKYLAKE-NEXT: #APP 2220 ; SKYLAKE-NEXT: salc # sched: [1:0.25] 2221 ; SKYLAKE-NEXT: #NO_APP 2222 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 2223 ; 2224 ; SKX-LABEL: test_salc: 2225 ; SKX: # %bb.0: 2226 ; SKX-NEXT: #APP 2227 ; SKX-NEXT: salc # sched: [1:0.25] 2228 ; SKX-NEXT: #NO_APP 2229 ; SKX-NEXT: retl # sched: [6:0.50] 2230 ; 2231 ; BTVER2-LABEL: test_salc: 2232 ; BTVER2: # %bb.0: 2233 ; BTVER2-NEXT: #APP 2234 ; BTVER2-NEXT: salc # sched: [1:0.50] 2235 ; BTVER2-NEXT: #NO_APP 2236 ; BTVER2-NEXT: retl # sched: [4:1.00] 2237 ; 2238 ; ZNVER1-LABEL: test_salc: 2239 ; ZNVER1: # %bb.0: 2240 ; ZNVER1-NEXT: #APP 2241 ; ZNVER1-NEXT: salc # sched: [1:0.25] 2242 ; ZNVER1-NEXT: #NO_APP 2243 ; ZNVER1-NEXT: retl # sched: [1:0.50] 2244 %1 = tail call i8 asm "salc", "=r"() nounwind 2245 ret i8 %1 2246 } 2247 2248 ; TODO - test_sgdt 2249 ; TODO - test_sidt 2250 2251 define void @test_xchg_32(i32 %a0, i32 %a1, i32 *%a2) optsize { 2252 ; GENERIC-LABEL: test_xchg_32: 2253 ; GENERIC: # %bb.0: 2254 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %eax 2255 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %ecx 2256 ; GENERIC-NEXT: movl {{[0-9]+}}(%esp), %edx 2257 ; GENERIC-NEXT: #APP 2258 ; GENERIC-NEXT: xchgl %eax, %eax 2259 ; GENERIC-NEXT: xchgl %ecx, %eax 2260 ; GENERIC-NEXT: xchgl %eax, (%edx) 2261 ; GENERIC-NEXT: #NO_APP 2262 ; GENERIC-NEXT: retl 2263 ; 2264 ; ATOM-LABEL: test_xchg_32: 2265 ; ATOM: # %bb.0: 2266 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [1:1.00] 2267 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [1:1.00] 2268 ; ATOM-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [1:1.00] 2269 ; ATOM-NEXT: #APP 2270 ; ATOM-NEXT: xchgl %eax, %eax # sched: [2:1.00] 2271 ; ATOM-NEXT: xchgl %ecx, %eax # sched: [2:1.00] 2272 ; ATOM-NEXT: xchgl %eax, (%edx) # sched: [3:1.50] 2273 ; ATOM-NEXT: #NO_APP 2274 ; ATOM-NEXT: retl # sched: [79:39.50] 2275 ; 2276 ; SLM-LABEL: test_xchg_32: 2277 ; SLM: # %bb.0: 2278 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [3:1.00] 2279 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [3:1.00] 2280 ; SLM-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [3:1.00] 2281 ; SLM-NEXT: #APP 2282 ; SLM-NEXT: xchgl %eax, %eax # sched: [1:0.50] 2283 ; SLM-NEXT: xchgl %ecx, %eax # sched: [1:0.50] 2284 ; SLM-NEXT: xchgl %eax, (%edx) # sched: [4:2.00] 2285 ; SLM-NEXT: #NO_APP 2286 ; SLM-NEXT: retl # sched: [4:1.00] 2287 ; 2288 ; SANDY-LABEL: test_xchg_32: 2289 ; SANDY: # %bb.0: 2290 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 2291 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 2292 ; SANDY-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [5:0.50] 2293 ; SANDY-NEXT: #APP 2294 ; SANDY-NEXT: xchgl %eax, %eax # sched: [2:1.00] 2295 ; SANDY-NEXT: xchgl %ecx, %eax # sched: [2:1.00] 2296 ; SANDY-NEXT: xchgl %eax, (%edx) # sched: [6:1.00] 2297 ; SANDY-NEXT: #NO_APP 2298 ; SANDY-NEXT: retl # sched: [6:1.00] 2299 ; 2300 ; HASWELL-LABEL: test_xchg_32: 2301 ; HASWELL: # %bb.0: 2302 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 2303 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 2304 ; HASWELL-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [5:0.50] 2305 ; HASWELL-NEXT: #APP 2306 ; HASWELL-NEXT: xchgl %eax, %eax # sched: [2:0.75] 2307 ; HASWELL-NEXT: xchgl %ecx, %eax # sched: [2:0.75] 2308 ; HASWELL-NEXT: xchgl %eax, (%edx) # sched: [9:1.00] 2309 ; HASWELL-NEXT: #NO_APP 2310 ; HASWELL-NEXT: retl # sched: [7:1.00] 2311 ; 2312 ; BROADWELL-LABEL: test_xchg_32: 2313 ; BROADWELL: # %bb.0: 2314 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 2315 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 2316 ; BROADWELL-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [5:0.50] 2317 ; BROADWELL-NEXT: #APP 2318 ; BROADWELL-NEXT: xchgl %eax, %eax # sched: [2:0.75] 2319 ; BROADWELL-NEXT: xchgl %ecx, %eax # sched: [2:0.75] 2320 ; BROADWELL-NEXT: xchgl %eax, (%edx) # sched: [8:1.00] 2321 ; BROADWELL-NEXT: #NO_APP 2322 ; BROADWELL-NEXT: retl # sched: [6:0.50] 2323 ; 2324 ; SKYLAKE-LABEL: test_xchg_32: 2325 ; SKYLAKE: # %bb.0: 2326 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 2327 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 2328 ; SKYLAKE-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [5:0.50] 2329 ; SKYLAKE-NEXT: #APP 2330 ; SKYLAKE-NEXT: xchgl %eax, %eax # sched: [2:0.75] 2331 ; SKYLAKE-NEXT: xchgl %ecx, %eax # sched: [2:0.75] 2332 ; SKYLAKE-NEXT: xchgl %eax, (%edx) # sched: [10:1.25] 2333 ; SKYLAKE-NEXT: #NO_APP 2334 ; SKYLAKE-NEXT: retl # sched: [6:0.50] 2335 ; 2336 ; SKX-LABEL: test_xchg_32: 2337 ; SKX: # %bb.0: 2338 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:0.50] 2339 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:0.50] 2340 ; SKX-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [5:0.50] 2341 ; SKX-NEXT: #APP 2342 ; SKX-NEXT: xchgl %eax, %eax # sched: [2:0.75] 2343 ; SKX-NEXT: xchgl %ecx, %eax # sched: [2:0.75] 2344 ; SKX-NEXT: xchgl %eax, (%edx) # sched: [10:1.25] 2345 ; SKX-NEXT: #NO_APP 2346 ; SKX-NEXT: retl # sched: [6:0.50] 2347 ; 2348 ; BTVER2-LABEL: test_xchg_32: 2349 ; BTVER2: # %bb.0: 2350 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [5:1.00] 2351 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [5:1.00] 2352 ; BTVER2-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [5:1.00] 2353 ; BTVER2-NEXT: #APP 2354 ; BTVER2-NEXT: xchgl %eax, %eax # sched: [1:0.50] 2355 ; BTVER2-NEXT: xchgl %ecx, %eax # sched: [1:0.50] 2356 ; BTVER2-NEXT: xchgl %eax, (%edx) # sched: [4:1.00] 2357 ; BTVER2-NEXT: #NO_APP 2358 ; BTVER2-NEXT: retl # sched: [4:1.00] 2359 ; 2360 ; ZNVER1-LABEL: test_xchg_32: 2361 ; ZNVER1: # %bb.0: 2362 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %eax # sched: [8:0.50] 2363 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %ecx # sched: [8:0.50] 2364 ; ZNVER1-NEXT: movl {{[0-9]+}}(%esp), %edx # sched: [8:0.50] 2365 ; ZNVER1-NEXT: #APP 2366 ; ZNVER1-NEXT: xchgl %eax, %eax # sched: [1:0.50] 2367 ; ZNVER1-NEXT: xchgl %ecx, %eax # sched: [1:0.50] 2368 ; ZNVER1-NEXT: xchgl %eax, (%edx) # sched: [5:0.50] 2369 ; ZNVER1-NEXT: #NO_APP 2370 ; ZNVER1-NEXT: retl # sched: [1:0.50] 2371 tail call void asm "xchg %EAX, $0 \0A\09 xchg $1, $0 \0A\09 xchg $2, $0", "r,r,*m"(i32 %a0, i32 %a1, i32 *%a2) nounwind 2372 ret void 2373 } 2374