https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114797
--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> --- (In reply to XChy from comment #2) > It looks like for completely overlapped memset, it's merged: > https://godbolt.org/z/4r7Eqr1Ee > With clobber, that's not the case: https://godbolt.org/z/8jhaEbKqo Yes for the secondary memset that is completely overlapping can be removed.