diff options
| author | Renato Golin <renato.golin@linaro.org> | 2015-10-01 12:58:41 +0000 |
|---|---|---|
| committer | Renato Golin <renato.golin@linaro.org> | 2015-10-01 12:58:41 +0000 |
| commit | 41106188a4fea286c094fc201e8066b416455463 (patch) | |
| tree | 25d6cbdf2e91b430d3210affb9589cd705d454ea /clang/lib | |
| parent | 2960f3a3466a46ff438f9dcf5f35b92e57398348 (diff) | |
| download | bcm5719-llvm-41106188a4fea286c094fc201e8066b416455463.tar.gz bcm5719-llvm-41106188a4fea286c094fc201e8066b416455463.zip | |
Revert "Decorating virtual functions load with invariant.load" and fix
This reverts commit r248982 as it was breaking the ARM buildbots and the fix didn't work.
This reverts commit r248984, the fix that didn't work.
llvm-svn: 249005
Diffstat (limited to 'clang/lib')
| -rw-r--r-- | clang/lib/CodeGen/ItaniumCXXABI.cpp | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/clang/lib/CodeGen/ItaniumCXXABI.cpp b/clang/lib/CodeGen/ItaniumCXXABI.cpp index 37b49dc6086..8392f6a7ba2 100644 --- a/clang/lib/CodeGen/ItaniumCXXABI.cpp +++ b/clang/lib/CodeGen/ItaniumCXXABI.cpp @@ -1609,16 +1609,7 @@ llvm::Value *ItaniumCXXABI::getVirtualFunctionPointer(CodeGenFunction &CGF, uint64_t VTableIndex = CGM.getItaniumVTableContext().getMethodVTableIndex(GD); llvm::Value *VFuncPtr = CGF.Builder.CreateConstInBoundsGEP1_64(VTable, VTableIndex, "vfn"); - auto *Inst = CGF.Builder.CreateAlignedLoad(VFuncPtr, CGF.getPointerAlign()); - - // It's safe to add "invariant.load" without -fstrict-vtable-pointers, but it - // would not help in devirtualization. - if (CGM.getCodeGenOpts().OptimizationLevel > 0 && - CGM.getCodeGenOpts().StrictVTablePointers) - Inst->setMetadata(llvm::LLVMContext::MD_invariant_load, - llvm::MDNode::get(CGM.getLLVMContext(), - llvm::ArrayRef<llvm::Metadata *>())); - return Inst; + return CGF.Builder.CreateAlignedLoad(VFuncPtr, CGF.getPointerAlign()); } llvm::Value *ItaniumCXXABI::EmitVirtualDestructorCall( |

