This is an archive of the discontinued LLVM Phabricator instance.

[test][asan] Make the printf-5.c test case actually emit a volatile memcpy.
ClosedPublic

Authored by pcwalton on Oct 30 2022, 11:10 AM.

Details

Summary

The current test in printf-5.c appears to try to emit a volatile memcpy for the
format string, but it doesn't because the volatile qualifier is implicitly
casted away. Using a string literal instead preserves the volatile qualifier.

This is a follow-up to D137031 and is a prerequisite for D136822, which elides
memcpys in more instances and would otherwise break this test.

Diff Detail

Event Timeline

pcwalton created this revision.Oct 30 2022, 11:10 AM
Herald added a project: Restricted Project. · View Herald TranscriptOct 30 2022, 11:10 AM
Herald added a subscriber: Enna1. · View Herald Transcript
pcwalton requested review of this revision.Oct 30 2022, 11:10 AM
Herald added a project: Restricted Project. · View Herald TranscriptOct 30 2022, 11:10 AM
Herald added a subscriber: Restricted Project. · View Herald Transcript
nikic accepted this revision.Oct 30 2022, 12:40 PM
nikic added a subscriber: nikic.

LG

This revision is now accepted and ready to land.Oct 30 2022, 12:40 PM