Clang changes to make use of the LLVM intrinsics added in D21160.
Details
Diff Detail
Event Timeline
(Art, I would appreciate a second set of eyes on this one, as the last time I did this -- with ldg -- I messed up pretty badly.)
Update after tra's review.
lib/Headers/__clang_cuda_intrinsics.h | ||
---|---|---|
77–80 | I'm pretty sure using a union for this purpose is UB in C++. "[9.5.1] In a union, at most one of the non-static data members can be active at any time, that is, the value of at most one of the non-static data members can be stored in a union at any time" Although apparently it's fine in C11, http://stackoverflow.com/questions/25664848/unions-and-type-punning | |
87 | Done, thanks. |
Could we use a union instead?