diff options
| author | Rafael Espindola <rafael.espindola@gmail.com> | 2011-01-02 03:59:13 +0000 |
|---|---|---|
| committer | Rafael Espindola <rafael.espindola@gmail.com> | 2011-01-02 03:59:13 +0000 |
| commit | 47731fe3f110b9128118e6ec2edf9e6201b6fc07 (patch) | |
| tree | 5262be735fe7674a8eb66b0c8a48adb59d06475d /clang/lib/CodeGen/CGStmt.cpp | |
| parent | 85b6d81d41d574d3265cc53bc8f6e3ec1a7688a8 (diff) | |
| download | bcm5719-llvm-47731fe3f110b9128118e6ec2edf9e6201b6fc07.tar.gz bcm5719-llvm-47731fe3f110b9128118e6ec2edf9e6201b6fc07.zip | |
Add support for passing variables declared to use a xmm register to asm
statements using the "x" constraint.
llvm-svn: 122679
Diffstat (limited to 'clang/lib/CodeGen/CGStmt.cpp')
| -rw-r--r-- | clang/lib/CodeGen/CGStmt.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGStmt.cpp b/clang/lib/CodeGen/CGStmt.cpp index 8ccd2893b83..b86cdf861ed 100644 --- a/clang/lib/CodeGen/CGStmt.cpp +++ b/clang/lib/CodeGen/CGStmt.cpp @@ -938,7 +938,8 @@ AddVariableConstraints(const std::string &Constraint, const Expr &AsmExpr, return Constraint; llvm::StringRef Register = Attr->getLabel(); assert(Target.isValidGCCRegisterName(Register)); - if (Constraint != "r") { + // FIXME: We should check which registers are compatible with "r" or "x". + if (Constraint != "r" && Constraint != "x") { CGM.ErrorUnsupported(&Stmt, "__asm__"); return Constraint; } |

