summaryrefslogtreecommitdiff
path: root/src/compiler_llvm/compilation_unit.cc
diff options
context:
space:
mode:
author Shih-wei Liao <sliao@google.com> 2012-06-30 10:21:18 -0700
committer Android Git Automerger <android-git-automerger@android.com> 2012-06-30 10:21:18 -0700
commitce9992f0fe18cee730ce4e82d0d101ab139ed6fb (patch)
tree69bc7553402bbd64aa4702c9d5ec20cc4e31252e /src/compiler_llvm/compilation_unit.cc
parente60f69b7716807116be6d0467be809e78d6e5d1a (diff)
parent02a1e359707c4b4d091ec7b4b5cda3848a6bd8a5 (diff)
am 02a1e359: Workaround for x86 build now.
* commit '02a1e359707c4b4d091ec7b4b5cda3848a6bd8a5': Workaround for x86 build now.
Diffstat (limited to 'src/compiler_llvm/compilation_unit.cc')
-rw-r--r--src/compiler_llvm/compilation_unit.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/compiler_llvm/compilation_unit.cc b/src/compiler_llvm/compilation_unit.cc
index fdbf575c0f..8aae161fcb 100644
--- a/src/compiler_llvm/compilation_unit.cc
+++ b/src/compiler_llvm/compilation_unit.cc
@@ -363,6 +363,14 @@ bool CompilationUnit::MaterializeToRawOStream(llvm::raw_ostream& out_stream) {
bool CompilationUnit::ExtractCodeAndPrelink(const std::string& elf_image) {
+ if (GetInstructionSet() == kX86) {
+ compiled_code_.push_back(0xccU);
+ compiled_code_.push_back(0xccU);
+ compiled_code_.push_back(0xccU);
+ compiled_code_.push_back(0xccU);
+ return true;
+ }
+
llvm::OwningPtr<llvm::MemoryBuffer> elf_image_buff(
llvm::MemoryBuffer::getMemBuffer(llvm::StringRef(elf_image.data(),
elf_image.size())));