This is an archive of the discontinued LLVM Phabricator instance.

[CSSPGO] Turn on unique linkage name by default for pseudo probe.
ClosedPublic

Authored by hoy on Jul 16 2021, 2:26 PM.

Details

Summary

Turning on -funique-internal-linkage-names when -fpseudo-probe-for-profiling is on, unless -fno-unique-internal-linkage-names is specified.

Diff Detail

Event Timeline

hoy created this revision.Jul 16 2021, 2:26 PM
hoy requested review of this revision.Jul 16 2021, 2:26 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 16 2021, 2:26 PM
Herald added a subscriber: cfe-commits. · View Herald Transcript
wenlei added inline comments.Jul 16 2021, 2:29 PM
clang/test/Driver/pseudo-probe.c
4

how do we test unique linkage name is implied with probe on?

hoy added inline comments.
clang/test/Driver/pseudo-probe.c
4

These two test lines below corresponding to line 1 in the test, which show that -funique-internal-linkage-names is passed to cc1.

// YESPROBE: -fpseudo-probe-for-profiling
// YESPROBE: -funique-internal-linkage-names

The change being made here is a driver change, so a driver test should be good.

wenlei added inline comments.Jul 16 2021, 2:39 PM
clang/test/Driver/pseudo-probe.c
4

The change is about making -funique-internal-linkage-names implied, but the test specified that switch explicitly. I was asking how to test the "implicit" part? Not sure what line 4 is testing wrt to this change.

hoy added inline comments.Jul 16 2021, 2:43 PM
clang/test/Driver/pseudo-probe.c
4

Line 1 is the -funique-internal-linkage-names switch , and we are checking YESPROBE for it.

4

Line 1 is the -funique-internal-linkage-names switch , and we are checking YESPROBE for it.

Line is w/o the -funique-internal-linkage-names switch.

wenlei accepted this revision.Jul 16 2021, 2:45 PM

lgtm, thanks.

clang/test/Driver/pseudo-probe.c
4

ah, sorry missed that.

This revision is now accepted and ready to land.Jul 16 2021, 2:45 PM
This revision was landed with ongoing or failed builds.Jul 16 2021, 4:43 PM
This revision was automatically updated to reflect the committed changes.