aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/CodeGen/CodeGenAction.cpp
diff options
context:
space:
mode:
authorJames Y Knight <jyknight@google.com>2016-03-04 19:00:41 +0000
committerJames Y Knight <jyknight@google.com>2016-03-04 19:00:41 +0000
commitb214cbc7852fa1719c5d0bd3ccb9615481e03c55 (patch)
treee5fe189f5192242789a8887dcf64d3af79258831 /clang/lib/CodeGen/CodeGenAction.cpp
parent31f251f1f0acae8864d08a07be4b190cea2ed4b5 (diff)
downloadllvm-b214cbc7852fa1719c5d0bd3ccb9615481e03c55.zip
llvm-b214cbc7852fa1719c5d0bd3ccb9615481e03c55.tar.gz
llvm-b214cbc7852fa1719c5d0bd3ccb9615481e03c55.tar.bz2
Make TargetInfo store an actual DataLayout instead of a string.
Use it to calculate UserLabelPrefix, instead of specifying it (often incorrectly). Note that the *actual* user label prefix has always come from the DataLayout, and is handled within LLVM. The main thing clang's TargetInfo::UserLabelPrefix did was to set the #define value. Having these be different from each-other is just silly. Differential Revision: http://reviews.llvm.org/D17183 llvm-svn: 262737
Diffstat (limited to 'clang/lib/CodeGen/CodeGenAction.cpp')
-rw-r--r--clang/lib/CodeGen/CodeGenAction.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/CodeGen/CodeGenAction.cpp b/clang/lib/CodeGen/CodeGenAction.cpp
index c9e188a8..638f79a 100644
--- a/clang/lib/CodeGen/CodeGenAction.cpp
+++ b/clang/lib/CodeGen/CodeGenAction.cpp
@@ -174,7 +174,7 @@ namespace clang {
}
EmitBackendOutput(Diags, CodeGenOpts, TargetOpts, LangOpts,
- C.getTargetInfo().getDataLayoutString(),
+ C.getTargetInfo().getDataLayout(),
getModule(), Action, AsmOutStream);
Ctx.setInlineAsmDiagnosticHandler(OldHandler, OldContext);
@@ -813,7 +813,7 @@ void CodeGenAction::ExecuteAction() {
LLVMContext &Ctx = TheModule->getContext();
Ctx.setInlineAsmDiagnosticHandler(BitcodeInlineAsmDiagHandler);
EmitBackendOutput(CI.getDiagnostics(), CI.getCodeGenOpts(), TargetOpts,
- CI.getLangOpts(), CI.getTarget().getDataLayoutString(),
+ CI.getLangOpts(), CI.getTarget().getDataLayout(),
TheModule.get(), BA, OS);
return;
}