Jakub Jelinek via Gcc-patches <gcc-patches@gcc.gnu.org> writes: > Hi! > > .VEC_CONVERT is a const internal call, so normally if the lhs is not used, > we'd DCE it far before getting to veclower, but with -O0 (or perhaps > -fno-tree-dce and some other -fno-* options) it can happen. > But as the internal fn needs the lhs to know the type to which the > conversion is done (and I think that is a reasonable representation, having > some magic another argument and having to create constants with that type > looks overkill to me), we just should DCE those calls ourselves.
FWIW, the reason we took that approach for .WHILE_ULT was for things like value numbering. It seems reasonable to expect that one const call to internal function F with arguments A produces the same result as another const call to internal function F with arguments A, without having to differentiate based on lhs type as well. (Not a comment on the patch itself btw.) Thanks, Richard