This is an archive of the discontinued LLVM Phabricator instance.

[clang][ARM] When handling multiple -mimplicit-it mark all as used
ClosedPublic

Authored by DavidSpickett on May 25 2021, 6:57 AM.

Details

Summary

Since 4468e5b8999291cc84b78f33f207dcd0e58146bc clang will prefer
the last one it finds of "-mimplicit-it" or "-Wa,-mimplicit-it".

Due to a mistake in that patch the compiler argument "-mimplicit-it"
was never marked as used, even if it was the last one and was passed
to llvm.

Move the Claim call back to the start of the loop and update
the testing to check we don't get any unused argument warnings.

Diff Detail

Event Timeline

DavidSpickett created this revision.May 25 2021, 6:57 AM
DavidSpickett requested review of this revision.May 25 2021, 6:57 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 25 2021, 6:57 AM
Herald added a subscriber: cfe-commits. · View Herald Transcript
DavidSpickett added a reviewer: mstorsjo.EditedMay 25 2021, 7:00 AM

You could argue that one of them is actually "unused" but I tried -march which also takes the last value and that does not warn when it ignores earlier values.

Should've spotted it in review really but hey, simple fix.

DavidSpickett retitled this revision from [clang][ARM] When handling multiple -mimplcit-it mark all as used to [clang][ARM] When handling multiple -mimplicit-it mark all as used.May 25 2021, 7:01 AM
mstorsjo accepted this revision.May 25 2021, 7:07 AM

LGTM, and sorry for not testning this aspect in the updated version of the patch.

This revision is now accepted and ready to land.May 25 2021, 7:07 AM
This revision was landed with ongoing or failed builds.May 25 2021, 7:53 AM
This revision was automatically updated to reflect the committed changes.