diff options
author | TDYa127 <tdy@google.com> | 2012-05-31 08:03:26 -0700 |
---|---|---|
committer | Shih-wei Liao <sliao@google.com> | 2012-06-03 09:02:22 -0700 |
commit | de479be99328d2113bf483e082c9ecf235a34d69 (patch) | |
tree | 7a51b8512e12561b9b05238f489d98c1d4a4fdb9 /src/compiler_llvm/ir_builder.h | |
parent | af543476661966c83a1e1c4db4fbef0d9a2d3afa (diff) | |
download | art-de479be99328d2113bf483e082c9ecf235a34d69.zip art-de479be99328d2113bf483e082c9ecf235a34d69.tar.gz art-de479be99328d2113bf483e082c9ecf235a34d69.tar.bz2 |
Refactor runtime support builder.
Also, add inline assembly for load offset from current thread.
Change-Id: I5c32c04a5ab9a8574acbaf8ee3e08761ebe33d4f
Diffstat (limited to 'src/compiler_llvm/ir_builder.h')
-rw-r--r-- | src/compiler_llvm/ir_builder.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/compiler_llvm/ir_builder.h b/src/compiler_llvm/ir_builder.h index 46c37f1..f21cfaf 100644 --- a/src/compiler_llvm/ir_builder.h +++ b/src/compiler_llvm/ir_builder.h @@ -120,8 +120,8 @@ class IRBuilder : public LLVMIRBuilder { StoreToObjectOffset(object_addr, offset, new_value, tbaa_.GetMemoryJType(special_ty, j_ty)); } - void SetTBAACall(llvm::CallInst* call_inst, TBAASpecialType special_ty) { - call_inst->setMetadata(llvm::LLVMContext::MD_tbaa, tbaa_.GetSpecialType(special_ty)); + void SetTBAA(llvm::Instruction* inst, TBAASpecialType special_ty) { + inst->setMetadata(llvm::LLVMContext::MD_tbaa, tbaa_.GetSpecialType(special_ty)); } @@ -217,10 +217,16 @@ class IRBuilder : public LLVMIRBuilder { // Runtime Helper Function //-------------------------------------------------------------------------- + RuntimeSupportBuilder& Runtime() { + return *runtime_support_; + } + + // TODO: Deprecate llvm::Function* GetRuntime(runtime_support::RuntimeId rt) { return runtime_support_->GetRuntimeSupportFunction(rt); } + // TODO: Deprecate void SetRuntimeSupport(RuntimeSupportBuilder* runtime_support) { // Can only set once. We can't do this on constructor, because RuntimeSupportBuilder needs // IRBuilder. |