search for: adjusttramp

Displaying 4 results from an estimated 4 matches for "adjusttramp".

2011 Aug 31
0
[LLVMdev] [PATCH] Split init.trampoline into init.trampoline & adjust.trampoline
...nabled. I don't think this comment (including the bit before) should exist. Passes rely on other passes have put things in decent shape all the time, and don't bother to say so. > + > + // First check if this instruction is actually an llvm.adjust.trampoline > + IntrinsicInst *AdjustTramp = dyn_cast<IntrinsicInst>(Callee); > + if (!AdjustTramp || > + AdjustTramp->getIntrinsicID() != Intrinsic::adjust_trampoline) > + return 0; > + > + // The first argument passed to adjust_trampoline is the trampoline argument. > + // Get a hold of this. > +...
2011 Aug 29
3
[LLVMdev] [PATCH] Split init.trampoline into init.trampoline & adjust.trampoline
Hi! Attached patches split init.trampoline into adjust.trampoline and init.trampoline, like in gcc. As mentioned in the previous mail, I've not made a documentation patch, since I'm not sure about what the documented semantics of llvm.adjust.trampoline should be. Thanks! -- Sanjoy Das http://playingwithpointers.com -------------- next part -------------- A non-text attachment was
2011 Aug 25
0
[LLVMdev] [RFC] Splitting init.trampoline into init.trampoline and adjust.trampoline
...Inst *BCInst = dyn_cast<BitCastInst>(Callee); > + if (BCInst == NULL) > + return NULL; It may be better to just do: Callee = Callee->stripPointerCasts(); Then you would use Callee rather than BCOp. > + > + Value *BCOp = BCInst->getOperand(0); > + IntrinsicInst *AdjustTramp = cast<IntrinsicInst>(BCOp); This will crash if it isn't an intrinsic. Use dyn_cast not cast. > + if (AdjustTramp == NULL) > + return NULL; You forgot to check that this intrinsic is the adjust.trampoline intrinsic. Also, the LLVM style is to use 0 rather than NULL in this ki...
2011 Aug 23
2
[LLVMdev] [RFC] Splitting init.trampoline into init.trampoline and adjust.trampoline
Hi! Attached set of patches splits llvm.init.trampoline into an "init" phase and an "adjust" phase, as discussed on the "Go on dragonegg" thread. Thanks! -- Sanjoy Das http://playingwithpointers.com -------------- next part -------------- A non-text attachment was scrubbed... Name: 0001-Split-intrinsics-and-DAG-nodes.patch Type: text/x-diff Size: 8808 bytes Desc: