diff options
author | David Blaikie <dblaikie@gmail.com> | 2015-03-24 22:38:16 +0000 |
---|---|---|
committer | David Blaikie <dblaikie@gmail.com> | 2015-03-24 22:38:16 +0000 |
commit | 68d535c45f207b8749b6dc2383a05a6e39d13738 (patch) | |
tree | 007acf3d1a7683a9e1829087244a6c4dbfb021d6 /llvm/lib/CodeGen/SjLjEHPrepare.cpp | |
parent | 2b969d7010c3a8478ea157cd326f7102a3832438 (diff) | |
download | bcm5719-llvm-68d535c45f207b8749b6dc2383a05a6e39d13738.tar.gz bcm5719-llvm-68d535c45f207b8749b6dc2383a05a6e39d13738.zip |
Opaque Pointer Types: GEP API migrations to specify the gep type explicitly
The changes to InstCombine do seem a bit silly - it doesn't make
anything obviously better to have the caller access the pointers element
type (the thing I'm trying to remove) than the GEP itself, but it's a
helpful migration step. This will allow me to more obviously lock down
GEP (& Load, etc) API usage, then fix all the code that accesses pointer
element types except the places that need to be removed (most of the
InstCombines) anyway - at which point I'll need to just remove all that
code because it won't be meaningful anymore (there will be no pointer
types, so no bitcasts to combine)
llvm-svn: 233126
Diffstat (limited to 'llvm/lib/CodeGen/SjLjEHPrepare.cpp')
-rw-r--r-- | llvm/lib/CodeGen/SjLjEHPrepare.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/SjLjEHPrepare.cpp b/llvm/lib/CodeGen/SjLjEHPrepare.cpp index 35e4292eea8..2335a888794 100644 --- a/llvm/lib/CodeGen/SjLjEHPrepare.cpp +++ b/llvm/lib/CodeGen/SjLjEHPrepare.cpp @@ -128,7 +128,8 @@ void SjLjEHPrepare::insertCallSiteStore(Instruction *I, int Number) { Value *Zero = ConstantInt::get(Int32Ty, 0); Value *One = ConstantInt::get(Int32Ty, 1); Value *Idxs[2] = { Zero, One }; - Value *CallSite = Builder.CreateGEP(FuncCtx, Idxs, "call_site"); + Value *CallSite = + Builder.CreateGEP(FunctionContextTy, FuncCtx, Idxs, "call_site"); // Insert a store of the call-site number ConstantInt *CallSiteNoC = |