summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGStmt.cpp
diff options
context:
space:
mode:
authorEric Christopher <echristo@apple.com>2011-06-21 00:07:10 +0000
committerEric Christopher <echristo@apple.com>2011-06-21 00:07:10 +0000
commitb4a791f7bc44e47d984be2b18c31725cb2438a35 (patch)
tree62b44e8faefbc8f19d38a2ba406794e77e3d8cb2 /clang/lib/CodeGen/CGStmt.cpp
parentcdd3635b0930239aaa91f435910b4b94285901ee (diff)
downloadbcm5719-llvm-b4a791f7bc44e47d984be2b18c31725cb2438a35.tar.gz
bcm5719-llvm-b4a791f7bc44e47d984be2b18c31725cb2438a35.zip
Canonicalize register names properly.
Fixes rdar://9425559 llvm-svn: 133486
Diffstat (limited to 'clang/lib/CodeGen/CGStmt.cpp')
-rw-r--r--clang/lib/CodeGen/CGStmt.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CGStmt.cpp b/clang/lib/CodeGen/CGStmt.cpp
index 86b9e2b997a..e0541911587 100644
--- a/clang/lib/CodeGen/CGStmt.cpp
+++ b/clang/lib/CodeGen/CGStmt.cpp
@@ -1286,6 +1286,8 @@ AddVariableConstraints(const std::string &Constraint, const Expr &AsmExpr,
CGM.ErrorUnsupported(&Stmt, "__asm__");
return Constraint;
}
+ // Canonicalize the register here before returning it.
+ Register = Target.getNormalizedGCCRegisterName(Register);
return "{" + Register.str() + "}";
}
OpenPOWER on IntegriCloud