[PATCH] Fix Mach-O unit tests breakage on Windows

kledzik at apple.com kledzik at apple.com
Thu Nov 6 18:51:34 PST 2014


Funny.  I just ran into this myself linking libc for arm64.  Some of the .o files inside static archives are not 8-byte aligned, so the read64() is asserting.  I think the read64() assert may be too aggressive.  It may need to fallback to memcpy() for reading unaligned data, rather that asserting.

But this patch is goodness.  Mach-O files should be at least 4 or 8 byte aligned, and the uint8_t[] does not guarantee that.  Please commit this.

http://reviews.llvm.org/D6161






More information about the llvm-commits mailing list