[PATCH] D76297: [clang][AArch64] readd support for 'p' inline asm constraint
Nick Desaulniers via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Mar 17 11:17:10 PDT 2020
This revision was automatically updated to reflect the committed changes.
Closed by commit rG5d90f886bc02: [clang][AArch64] readd support for 'p' inline asm constraint (authored by nickdesaulniers).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D76297/new/
https://reviews.llvm.org/D76297
Files:
clang/lib/Basic/Targets/AArch64.h
clang/test/CodeGen/inline-asm-p-constraint.c
Index: clang/test/CodeGen/inline-asm-p-constraint.c
===================================================================
--- /dev/null
+++ clang/test/CodeGen/inline-asm-p-constraint.c
@@ -0,0 +1,6 @@
+// RUN: %clang_cc1 -emit-llvm %s -o - -triple aarch64-linux-gnu | FileCheck %s
+void foo(void* ptr) {
+ asm volatile("prfm pldl1keep, %a0\n" : : "p" (ptr));
+ // CHECK: call void asm sideeffect "prfm pldl1keep, ${0:a}\0A", "r"(i8* %0)
+ // CHECK-NOT: call void asm sideeffect "prfm pldl1keep, ${0:a}\0A", "p"(i8* %0)
+}
Index: clang/lib/Basic/Targets/AArch64.h
===================================================================
--- clang/lib/Basic/Targets/AArch64.h
+++ clang/lib/Basic/Targets/AArch64.h
@@ -96,7 +96,7 @@
Constraint += 2;
break;
default:
- R = std::string(1, *Constraint);
+ R = TargetInfo::convertConstraint(Constraint);
break;
}
return R;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D76297.250834.patch
Type: text/x-patch
Size: 912 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20200317/52d2fa5c/attachment.bin>
More information about the cfe-commits
mailing list