27 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 32; PR135043; RUN: llc -mtriple=i686-- -mcpu=atom < %s | FileCheck %s4; Check that treemap is read before the asm statement.5 6define i32 @foo(i32 %treemap) nounwind {7; CHECK-LABEL: foo:8; CHECK: # %bb.0: # %entry9; CHECK-NEXT: pushl %eax10; CHECK-NEXT: movl {{[0-9]+}}(%esp), %eax11; CHECK-NEXT: movl %eax, %ecx12; CHECK-NEXT: negl %ecx13; CHECK-NEXT: andl %eax, %ecx14; CHECK-NEXT: movl %ecx, (%esp)15; CHECK-NEXT: #APP16; CHECK-NEXT: bsfl (%esp), %eax17; CHECK-NEXT: #NO_APP18; CHECK-NEXT: popl %ecx19; CHECK-NEXT: retl20entry:21 %sub = sub i32 0, %treemap22 %and = and i32 %treemap, %sub23 %0 = call i32 asm "bsfl $1,$0", "=r,rm"(i32 %and)24 ret i32 %025}26 27