This is an archive of the discontinued LLVM Phabricator instance.

[SanitizerCoverage] Use zeroext for cmp parameters on all targets
ClosedPublic

Authored by iii on Aug 10 2020, 2:22 PM.

Details

Summary

Commit 9385aaa84851 ("[sancov] Fix PR33732") added zeroext to
__sanitizer_cov_trace(_const)?_cmp[1248] parameters for x86_64 only,
however, it is useful on other targets, in particular, on SystemZ: it
fixes swap-cmp.test.

Therefore, use it on all targets. This is safe: if target ABI does not
require zero extension for a particular parameter, zeroext is simply
ignored. A similar change has been implemeted as part of commit
3bc439bdff8b ("[MSan] Add instrumentation for SystemZ"), and there were
no problems with it.

Diff Detail

Event Timeline

iii created this revision.Aug 10 2020, 2:22 PM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptAug 10 2020, 2:22 PM
Herald added subscribers: llvm-commits, Restricted Project, hiraditya. · View Herald Transcript
iii requested review of this revision.Aug 10 2020, 2:22 PM
iii added a comment.Aug 12 2020, 2:24 AM

All 3 test failures here are in unrelated areas and must be preexisting.

This revision is now accepted and ready to land.Aug 12 2020, 9:25 AM
This revision was landed with ongoing or failed builds.Aug 12 2020, 9:38 AM
This revision was automatically updated to reflect the committed changes.