craig.topper created this revision.
craig.topper added a reviewer: rnk.
Herald added subscribers: cfe-commits, eraman.
Herald added a project: clang.
The backend used to print the x87 FPSW register as 'fpsw', but gcc inline asm
uses 'fpsr'. After D57641 <https://reviews.llvm.org/D57641>, the backend now
uses 'fpsr' to match. So we need to update the test and we can remove the code
that excluded the 'fpsw' string.
Repository:
rC Clang
https://reviews.llvm.org/D57642
Files:
lib/Parse/ParseStmtAsm.cpp
test/CodeGen/ms-inline-asm.c
Index: test/CodeGen/ms-inline-asm.c
===================================================================
--- test/CodeGen/ms-inline-asm.c
+++ test/CodeGen/ms-inline-asm.c
@@ -571,7 +571,7 @@
// CHECK: fld dword ptr $1
__asm fistp i
// CHECK: fistp dword ptr $0
-// CHECK: "=*m,*m,~{dirflag},~{fpsr},~{flags}"(i32* %{{.*}}, float* %{{.*}})
+// CHECK: "=*m,*m,~{fpsr},~{dirflag},~{fpsr},~{flags}"(i32* %{{.*}}, float*
%{{.*}})
}
void t41(unsigned short a) {
Index: lib/Parse/ParseStmtAsm.cpp
===================================================================
--- lib/Parse/ParseStmtAsm.cpp
+++ lib/Parse/ParseStmtAsm.cpp
@@ -636,7 +636,7 @@
// Filter out "fpsw" and "mxcsr". They aren't valid GCC asm clobber
// constraints. Clang always adds fpsr to the clobber list anyway.
llvm::erase_if(Clobbers, [](const std::string &C) {
- return C == "fpsw" || C == "mxcsr";
+ return C == "mxcsr";
});
// Build the vector of clobber StringRefs.
Index: test/CodeGen/ms-inline-asm.c
===================================================================
--- test/CodeGen/ms-inline-asm.c
+++ test/CodeGen/ms-inline-asm.c
@@ -571,7 +571,7 @@
// CHECK: fld dword ptr $1
__asm fistp i
// CHECK: fistp dword ptr $0
-// CHECK: "=*m,*m,~{dirflag},~{fpsr},~{flags}"(i32* %{{.*}}, float* %{{.*}})
+// CHECK: "=*m,*m,~{fpsr},~{dirflag},~{fpsr},~{flags}"(i32* %{{.*}}, float* %{{.*}})
}
void t41(unsigned short a) {
Index: lib/Parse/ParseStmtAsm.cpp
===================================================================
--- lib/Parse/ParseStmtAsm.cpp
+++ lib/Parse/ParseStmtAsm.cpp
@@ -636,7 +636,7 @@
// Filter out "fpsw" and "mxcsr". They aren't valid GCC asm clobber
// constraints. Clang always adds fpsr to the clobber list anyway.
llvm::erase_if(Clobbers, [](const std::string &C) {
- return C == "fpsw" || C == "mxcsr";
+ return C == "mxcsr";
});
// Build the vector of clobber StringRefs.
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits