This is an archive of the discontinued LLVM Phabricator instance.

[InlineAdvisor] Add single quotes around caller/callee names
ClosedPublic

Authored by MaskRay on Aug 9 2021, 4:45 PM.

Details

Summary

This patch makes inline remarks conform to the convention.
New behavior:

% clang -O2 -Rpass=inline -Rpass-missed=inline -S a.c
a.c:4:25: remark: 'foo' inlined into 'bar' with (cost=-30, threshold=337) at callsite bar:0:25; [-Rpass=inline]
int bar(int a) { return foo(a); }
                        ^

Diff Detail

Event Timeline

MaskRay created this revision.Aug 9 2021, 4:45 PM
MaskRay requested review of this revision.Aug 9 2021, 4:45 PM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptAug 9 2021, 4:45 PM

(I haven't converted directories in tools/gold Transforms/ LTO/, but they should be pretty mechanical.)

hoy added inline comments.Aug 9 2021, 5:54 PM
llvm/test/Transforms/SampleProfile/inline-replay.ll
7

The inline replay file is designed to have the same format with the optimization remarks file so that you can just replay with a remark output. Tweaking the format of remark output changes this behavior. Can you also change the replay part as well?

MaskRay updated this revision to Diff 365332.Aug 9 2021, 6:52 PM

Update inline-replay code and tests

hoy accepted this revision.Aug 9 2021, 9:32 PM

LGTM.

This revision is now accepted and ready to land.Aug 9 2021, 9:32 PM
MaskRay edited the summary of this revision. (Show Details)Aug 10 2021, 11:38 AM
This revision was landed with ongoing or failed builds.Aug 10 2021, 11:51 AM
This revision was automatically updated to reflect the committed changes.