Thanks Tim. <br><br>Cheers. <br><div class="gmail_quote"><div dir="ltr">On Tue, Jun 28, 2016 at 3:07 PM Tim Northover <<a href="mailto:t.p.northover@gmail.com">t.p.northover@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 28 June 2016 at 11:59, Ramkumar Ramachandra via llvm-dev<br>
<<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>> wrote:<br>
> I have what appears to be an alignment/struct padding bug. An i64 is not<br>
> correctly aligned to the 8-byte boundary, and this results in a mismatched<br>
> struct size between C and LLVM. We are currently running 3.8, and did not see<br>
> this bug in 3.5.<br>
<br>
LLVM needs to be provided with a datalayout to calculate correct<br>
struct offsets, and for historical reasons the default alignment<br>
requirement for i64 is only 32-bits. I suspect you're just relying on<br>
this default, you should be able to crib the correct layout from a<br>
Clang-compiled C file and use Module::setDataLayout to fix it.<br>
<br>
Cheers.<br>
<br>
Tim.<br>
</blockquote></div>