From: Simon Atanasyan Date: Tue, 22 May 2012 11:03:10 +0000 (+0000) Subject: Replace inline asm constraint "=a" by the more general constraint "=r". X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d95e95ec5300249f5b7c6f1b72bde59e5141069c;p=clang Replace inline asm constraint "=a" by the more general constraint "=r". That extend a range of platforms support this test case. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@157247 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/test/Analysis/nullptr.cpp b/test/Analysis/nullptr.cpp index 3119b4fc39..050c3f8dc5 100644 --- a/test/Analysis/nullptr.cpp +++ b/test/Analysis/nullptr.cpp @@ -55,7 +55,7 @@ void zoo2() { int **a = 0; int **b = 0; asm ("nop" - :"=a"(*a) + :"=r"(*a) :"0"(*b) // expected-warning{{Dereference of null pointer}} ); } diff --git a/test/SemaTemplate/instantiate-expr-1.cpp b/test/SemaTemplate/instantiate-expr-1.cpp index 9395117e9c..e777243586 100644 --- a/test/SemaTemplate/instantiate-expr-1.cpp +++ b/test/SemaTemplate/instantiate-expr-1.cpp @@ -127,7 +127,7 @@ void test_call_operator(CallOperator call_op, int i, double d) { template void test_asm(T t) { - asm ("nop" : "=a"(*t) : "r"(*t)); // expected-error {{indirection requires pointer operand ('int' invalid)}} + asm ("nop" : "=r"(*t) : "r"(*t)); // expected-error {{indirection requires pointer operand ('int' invalid)}} } void test_asm() {