[llvm] r260587 - Set load alignment on aggregate loads.

Pete Cooper via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 11 18:22:37 PST 2016


Great. Thanks Hans!

Pete

Sent from my iPhone

> On Feb 11, 2016, at 5:47 PM, Hans Wennborg <hans at chromium.org> wrote:
> 
> On Thu, Feb 11, 2016 at 1:10 PM, Pete Cooper via llvm-commits
> <llvm-commits at lists.llvm.org> wrote:
>> Author: pete
>> Date: Thu Feb 11 15:10:40 2016
>> New Revision: 260587
>> 
>> URL: http://llvm.org/viewvc/llvm-project?rev=260587&view=rev
>> Log:
>> Set load alignment on aggregate loads.
>> 
>> When optimizing a extractvalue(load), we generate a load from the
>> aggregate type.  This load didn't have alignment set and so would
>> get the alignment of the type.  This breaks when the type is packed
>> and so the alignment should be lower.
>> 
>> For example, loading { int, int } would give us alignment of 4, but
>> the original load from this type may have an alignment of 1 if packed.
>> 
>> Reviewed by David Majnemer
>> 
>> Differential revision: http://reviews.llvm.org/D17158
> 
> Merged to 3.8 in r260640 as suggested on the review.
> 
> Cheers,
> Hans


More information about the llvm-commits mailing list