[clang] [llvm] RFC: Implementing new mechanism for hard register operands to inline asm as a constraint. (PR #85846)
via cfe-commits
cfe-commits at lists.llvm.org
Thu Mar 28 13:10:41 PDT 2024
================
@@ -770,6 +770,18 @@ bool TargetInfo::validateOutputConstraint(ConstraintInfo &Info) const {
case 'E':
case 'F':
break; // Pass them.
+ case '{': {
----------------
tltao wrote:
Yes, we should be using the same names. The register asm variable is parsed in `clang/lib/Sema/SemaDecl.cpp` using:
```
case SC_Register:
// Local Named register
if (!Context.getTargetInfo().isValidGCCRegisterName(Label) &&
DeclAttrsMatchCUDAMode(getLangOpts(), getCurFunctionDecl()))
Diag(E->getExprLoc(), diag::err_asm_unknown_register_name) << Label;
break;
```
https://github.com/llvm/llvm-project/pull/85846
More information about the cfe-commits
mailing list