r246985 - Compute and preserve alignment more faithfully in IR-generation.

John McCall via cfe-commits cfe-commits at lists.llvm.org
Tue Sep 8 18:32:50 PDT 2015


> On Sep 8, 2015, at 6:19 PM, Steven Wu <stevenwu at apple.com> wrote:
> CreateElementBitcast doesn’t seem to do what the name suggested. If you give it VTy, it doesn’t grab the element type to generate bitcast. Is this by-design? If so, I need to do this:
> PtrOp0 = Builder.CreateElementBitCast(PtrOp0, VTy->getElementType());

Yes, I’m sorry, that’s right.  I missed that you were also drilling down to the element type.

John.


More information about the cfe-commits mailing list