1 // REQUIRES: x86-registered-target
2 // RUN: %clang_cc1 -triple x86_64 %s -S -o /dev/null -DWARN -verify
3 // RUN: %clang_cc1 -triple x86_64 %s -S -o /dev/null -Werror -verify
4 // RUN: %clang_cc1 -triple x86_64-linux-gnu %s -S -o - | FileCheck %s
6 asm("movaps %xmm3, (%esi, 2)");
7 // expected-note@1 {{instantiated into assembly here}}
9 // expected-warning@-3 {{scale factor without index register is ignored}}
11 // expected-error@-5 {{scale factor without index register is ignored}}
15 static unsigned var
[1] = {};
16 void g(void) { asm volatile("movd %%xmm0, %0"
24 __asm__
__volatile__("\n#define S_A abcd%0\n" : : "n"(&((struct s
*)0)->a
));
25 __asm__
__volatile__("\n#define S_B abcd%0\n" : : "n"(&((struct s
*)0)->b
));
26 __asm__
__volatile__("\n#define BEEF abcd%0\n" : : "n"((int*)0xdeadbeeeeeef));
27 __asm__
__volatile__("movabsq %0, %%rax" : : "n"(4624529908474429119));
29 // CHECK-LABEL: pr40890
30 // CHECK: #define S_A abcd$0
31 // CHECK: #define S_B abcd$4
32 // CHECK: #define BEEF abcd$244837814038255
33 // CHECK: movabsq $4624529908474429119, %rax