xref: /llvm-project/clang/test/CodeGen/ms-inline-asm-static-variable.c (revision be08e452f36602cd73f816787bf16d1a0405ff09)
1 // REQUIRES: x86-registered-target
2 // Check the constraint "*m" of operand arr and the definition of arr is not removed by FE
3 // RUN: %clang_cc1 %s -fasm-blocks -triple i386-apple-darwin10 -emit-llvm -o - | FileCheck %s
4 
5 static int arr[10];
6 void t1() {
7   // CHECK: @arr = internal global [10 x i32]
8   // CHECK: call void asm sideeffect inteldialect "mov dword ptr $0[edx * $$4],edx", "=*m,{{.*}}([10 x i32]* @arr)
9   __asm mov  dword ptr arr[edx*4],edx
10 }
11