Description
Bugzilla Link | 39704 |
Resolution | FIXED |
Resolved on | Nov 29, 2018 16:08 |
Version | 7.0 |
OS | other |
Blocks | #38454 |
CC | @zmodem,@hfinkel,@nemanjai,@noloader,@tstellar |
Fixed by commit(s) | 347556 r347935 |
Extended Description
I don't have a reduced case for this at the moment. We are trying to track down the cause of several failed self tests. But I hope someone can take a quick look and tweak an attribute somewhere.
I'm working on GCC112, which is powerpc64le-unknown-linux-gnu. I built Clang from the 7.0 release tarballs. During a run of UBsan I caught several findings like shown below. All the findings pointed to altivec.h:16363.
/home/noloader/llvm/lib/clang/7.0.0/include/altivec.h:16363:10: runtime error: load of misaligned address 0x3fffd3453848 for type '__vector unsigned char' (vector of 16 'unsigned char' values), which requires 16 byte alignment
0x3fffd3453848: note: pointer points here
00 00 00 00 a0 10 97 5f 2f e6 c9 b9 69 36 ab 5d 96 9e 6c cf fc c7 e9 ac c0 09 cd f3 aa cf 66 7c
^
altivec.h:16363 is shown below. Notice the vec_xl:
16361 static inline __ATTRS_o_ai vector unsigned char
16362 vec_xl(signed long long __offset, unsigned char *__ptr) {
16363 return *(vector unsigned char *)(__ptr + __offset);
16364 }
As far as I know there is no alignment requirement for the instruction.