1*0a6a1f1dSLionel Sambuc // REQUIRES: x86-registered-target 2*0a6a1f1dSLionel Sambuc // RUN: %clang_cc1 -triple x86_64 %s -S -o /dev/null -DWARN -verify 3*0a6a1f1dSLionel Sambuc // RUN: %clang_cc1 -triple x86_64 %s -S -o /dev/null -Werror -verify f()4*0a6a1f1dSLionel Sambucvoid f() { 5*0a6a1f1dSLionel Sambuc asm("movaps %xmm3, (%esi, 2)"); 6*0a6a1f1dSLionel Sambuc // expected-note@1 {{instantiated into assembly here}} 7*0a6a1f1dSLionel Sambuc #ifdef WARN 8*0a6a1f1dSLionel Sambuc // expected-warning@-3 {{scale factor without index register is ignored}} 9*0a6a1f1dSLionel Sambuc #else 10*0a6a1f1dSLionel Sambuc // expected-error@-5 {{scale factor without index register is ignored}} 11*0a6a1f1dSLionel Sambuc #endif 12*0a6a1f1dSLionel Sambuc } 13*0a6a1f1dSLionel Sambuc 14*0a6a1f1dSLionel Sambuc static unsigned var[1] = {}; g(void)15*0a6a1f1dSLionel Sambucvoid g(void) { asm volatile("movd %%xmm0, %0" 16*0a6a1f1dSLionel Sambuc : 17*0a6a1f1dSLionel Sambuc : "m"(var)); } 18