[cfe-commits] Patch for EmitAggregateCopy.

Chris Lattner clattner at apple.com
Wed Nov 19 21:08:39 PST 2008


On Nov 19, 2008, at 1:58 AM, Daniel Dunbar wrote:

> You do not need to compute IntTy with the switch (which would assert
> on x86_64). Note that you can just use IntegerType::get(N) to return
> the integer type of width N (which in fact the code right above is
> already doing).
>
> However, even with this change this will break x86_64, because the
> memset intrinsics expect an int32 parameter for the alignment. Its not
> clear to me why PIC16 should need the alignment to be an int16; this
> is a small constant integer, not something for which code is actually
> generated. It is inconsistent to have the alignment be int32 for the
> 64-bit and 32-bit memcpy intrinsics and 16-bit for PIC16.

Right, this is wrong.  The alignment field should be i32 for all of  
these intrinsics.  The new intrinsics need to be fixed in LLVM.

-Chris



More information about the cfe-commits mailing list