This is an archive of the discontinued LLVM Phabricator instance.

Add flag to llvm-profdata to allow symbols in profile data to be remapped, andadd a tool to generate symbol remapping files.
Needs ReviewPublic

Authored by rsmith on Aug 29 2018, 5:26 PM.

Details

Summary

The new tool llvm-cxxmap builds a symbol mapping table from a file containing
a description of partial equivalences to apply to mangled names and files
containing old and new symbol tables.

Diff Detail

Event Timeline

rsmith created this revision.Aug 29 2018, 5:26 PM

Some test case for llvm-profdata new option is also needed (under test/tools/llvm-profdata)

tools/llvm-profdata/llvm-profdata.cpp
543 ↗(On Diff #163234)

The new option needs to be documented in docs/CommandGuide/llvm-profdata.rst

davidxl retitled this revision from Add flag to llvm-profdata to allow symbols in profile data to be remapped, and add a tool to generate symbol remapping files. to Add flag to llvm-profdata to allow symbols in profile data to be remapped, andadd a tool to generate symbol remapping files..Aug 30 2018, 9:29 AM
davidxl added a reviewer: wmi.
rsmith updated this revision to Diff 163453.Aug 30 2018, 5:28 PM
  • Update documentation for llvm-profdata and add documentation for llvm-cxxmap.
  • Add tests for new llvm-profdata functionality.
  • Add tests for llvm-cxxmap.
rsmith marked an inline comment as done.Aug 30 2018, 5:29 PM
davidxl accepted this revision.Aug 31 2018, 8:43 AM

lgtm

Wei may have more comments on the samplePGO remapping code.

This revision is now accepted and ready to land.Aug 31 2018, 8:43 AM
wmi accepted this revision.Sep 13 2018, 12:06 PM

LGTM.

This revision was automatically updated to reflect the committed changes.

This commit made the reverse-iteration bot (http://lab.llvm.org:8011/builders/reverse-iteration) red (red since 6 months now) :

FAIL: LLVM :: tools/llvm-profdata/instr-remap.test (42755 of 44261)
******************** TEST 'LLVM :: tools/llvm-profdata/instr-remap.test' FAILED ********************
Script:
--
: 'RUN: at line 1';   /local/buildbot/slaves/hexagon-build-02/reverse-iteration/llvm.obj/bin/llvm-profdata merge -text /local/buildbot/slaves/hexagon-build-02/reverse-iteration/llvm.src/test/tools/llvm-profdata/Inputs/instr-remap.proftext -r /local/buildbot/slaves/hexagon-build-02/reverse-iteration/llvm.src/test/tools/llvm-profdata/Inputs/instr-remap.remap -o /local/buildbot/slaves/hexagon-build-02/reverse-iteration/llvm.obj/test/tools/llvm-profdata/Output/instr-remap.test.tmp.output
: 'RUN: at line 2';   diff /local/buildbot/slaves/hexagon-build-02/reverse-iteration/llvm.src/test/tools/llvm-profdata/Inputs/instr-remap.expected /local/buildbot/slaves/hexagon-build-02/reverse-iteration/llvm.obj/test/tools/llvm-profdata/Output/instr-remap.test.tmp.output
--
Exit Code: 1

Command Output (stdout):
--
5c5
< 1234
---
> 5678
9,10c9,10
< 31
< 42
---
> 500
> 600
14c14
< 5678
---
> 1234
18,19c18,19
< 500
< 600
---
> 31
> 42

--

********************
Testing: 0 .. 10.. 20.. 30.. 40.. 50.. 60.. 70.. 80.. 90.. 

1 warning(s) in tests.
Testing Time: 184.64s
********************
Failing Tests (1):
    LLVM :: tools/llvm-profdata/instr-remap.test

  Expected Passes    : 43374
  Expected Failures  : 195
  Unsupported Tests  : 691
  Unexpected Failures: 1
riccibruno reopened this revision.Jan 16 2019, 6:15 AM
This revision is now accepted and ready to land.Jan 16 2019, 6:15 AM
riccibruno requested changes to this revision.Jan 16 2019, 6:16 AM
This revision now requires changes to proceed.Jan 16 2019, 6:16 AM

@davidxl @wmi Ping. The reverse-iteration bot is still red because of this patch.
(http://lab.llvm.org:8011/builders/reverse-iteration)

Hahnfeld added a subscriber: Hahnfeld.

This commit made the reverse-iteration bot (http://lab.llvm.org:8011/builders/reverse-iteration) red (red since 6 months now) :

It's a pity that nobody cared. I've submitted D58385 to fix this, PTAL.

Herald added a project: Restricted Project. · View Herald TranscriptFeb 19 2019, 7:30 AM
Herald added a subscriber: jdoerfert. · View Herald Transcript

This commit made the reverse-iteration bot (http://lab.llvm.org:8011/builders/reverse-iteration) red (red since 6 months now) :

It's a pity that nobody cared. I've submitted D58385 to fix this, PTAL.

Thanks a lot. I am afraid I cannot comment on the changes since I am not at all familiar with it, but I am glad that this issue is being looked at !

This revision was not accepted when it landed; it landed in state Needs Revision.Oct 7 2019, 3:45 AM
This revision was automatically updated to reflect the committed changes.
sammccall reopened this revision.Oct 7 2019, 4:14 AM