diff options
author | David L. Jones <dlj@google.com> | 2016-02-18 20:27:16 +0000 |
---|---|---|
committer | David L. Jones <dlj@google.com> | 2016-02-18 20:27:16 +0000 |
commit | cd58bd6200ca8b5141fff482de3e9b38673b0d2e (patch) | |
tree | cd81f8ad534fa140a7ca728832e04b69afd1adea /clang/unittests/Frontend/CodeGenActionTest.cpp | |
parent | 6b2608f2e053406d3f3406c1437aa9b0dd44ee90 (diff) | |
download | bcm5719-llvm-cd58bd6200ca8b5141fff482de3e9b38673b0d2e.tar.gz bcm5719-llvm-cd58bd6200ca8b5141fff482de3e9b38673b0d2e.zip |
Use Backend_EmitMCNull for null codegen unit tests.
Using Backend_EmitLL attemps to create a file with an empty filename.
This is problematic in certain environments: an empty filename may be
illegal, or the default output path may not be writable (in the case
where an empty filename would otherwise have some non-failing
semantics). This patch switches to use Backend_EmitMCNull, which
allows CodeGen to run, but does not attempt to create or write an
output file.
Differential Revision: http://reviews.llvm.org/D17405
llvm-svn: 261252
Diffstat (limited to 'clang/unittests/Frontend/CodeGenActionTest.cpp')
-rw-r--r-- | clang/unittests/Frontend/CodeGenActionTest.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/unittests/Frontend/CodeGenActionTest.cpp b/clang/unittests/Frontend/CodeGenActionTest.cpp index 3ff6c4eb40b..71446fd4d79 100644 --- a/clang/unittests/Frontend/CodeGenActionTest.cpp +++ b/clang/unittests/Frontend/CodeGenActionTest.cpp @@ -26,7 +26,7 @@ namespace { class NullCodeGenAction : public CodeGenAction { public: NullCodeGenAction(llvm::LLVMContext *_VMContext = nullptr) - : CodeGenAction(Backend_EmitLL, _VMContext) {} + : CodeGenAction(Backend_EmitMCNull, _VMContext) {} // The action does not call methods of ATContext. void ExecuteAction() override { |