1 // REQUIRES: x86-registered-target
2 // RUN: %clang_cc1 %s -fasm-blocks -triple i386-apple-darwin10 -emit-llvm -o - | FileCheck %s
15 // CHECK: call void asm
16 // CHECK-SAME: mov eax, $$12
18 // CHECK-SAME: mov eax, $$17
19 __asm mov eax
, x::y_t::A
20 // CHECK-NEXT: call void asm
21 // CHECK-SAME: mov eax, $$1
28 // CHECK: call void asm
29 // CHECK-SAME: mov eax, $$21
30 __asm mov eax
, (A
+ 9) * 2 + A
31 // CHECK-SAME: mov eax, $$4
33 // CHECK-SAME: mov eax, $$2
35 // CHECK-SAME: mov eax, $$5
36 __asm mov eax
, 3 + (B
& 3)
37 // CHECK-SAME: mov eax, $$8
38 __asm mov eax
, 2 << A
* B
45 // CHECK: call void asm
46 // CHECK-SAME: mov eax, [eax + $$47]
47 __asm
{ mov eax
, [(x::A
+ 9) + A
* B
+ 3 + 3 + eax
] }
48 // CHECK-NEXT: call void asm
49 // CHECK-SAME: mov eax, dword ptr $0[$$4]
50 __asm
{ mov eax
, dword ptr
[arr
+ A
] }
51 // CHECK-NEXT: call void asm
52 // CHECK-SAME: mov eax, dword ptr $0[$$8]
53 __asm
{ mov eax
, dword ptr A
[arr
+ A
] }