http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59990
--- Comment #12 from Jakub Jelinek <jakub at gcc dot gnu.org> --- (In reply to Richard Biener from comment #9) > Created attachment 31991 [details] > patch > > Must resist turning this fn upside down ... > > Anyway, untested patch attached. We can surely do better selecting a > type, but IIRC most targets have an integer mode that covers all other > modes (even vector modes). Besides the GET_MODE_SIZE -> GET_MODE_BITSIZE fix and handling ENUMERAL_TYPEs similarly for -fsanitize=enum, do you think you could add the build_aligned_type call too? I mean, if say the floating point/boolean/complex/enum type has certain alignment and the integral type we are going to use instead has different, it would be better to preserve the alignment info.
