[Support][unittests] Enforce alignment in ConvertUTFTest
`LLVM-Unit :: Support/./SupportTests/ConvertUTFTest.ConvertUTF16LittleEndianToUTF8String` `FAIL`s on Solaris/sparcv9: In `llvm/lib/Support/ConvertUTFWrapper.cpp` (`convertUTF16ToUTF8String`) the `SrcBytes` arg is reinterpreted/accessed as `UTF16` (`unsigned short`, which requires 2-byte alignment on strict-alignment targets like Sparc) without anything guaranteeing the alignment, so the access yields a `SIGBUS`. This patch avoids this by enforcing the required alignment in the callers. Tested on `sparcv9-sun-solaris2.11`. Differential Revision: https://reviews.llvm.org/D88824
Loading
Please register or sign in to comment