This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: AutoFDO profile toolchain is open-sourced
- From: Diego Novillo <dnovillo at google dot com>
- To: Ilya Palachev <i dot palachev at samsung dot com>
- Cc: GCC Development <gcc at gcc dot gnu dot org>, David Li <davidxl at google dot com>, Jan Hubicka <hubicka at ucw dot cz>, Sebastian Pop <sebpop at gmail dot com>, Dehao Chen <dehao at google dot com>, Vyacheslav Barinov <v dot barinov at samsung dot com>
- Date: Tue, 21 Apr 2015 07:57:05 -0400
- Subject: Re: AutoFDO profile toolchain is open-sourced
- Authentication-results: sourceware.org; auth=none
- References: <CAO2gOZWydpiBXb=1QDyCRt-ybDieqy8X4S_+uRZk2Y2v+cFdYQ at mail dot gmail dot com> <5523ED98 dot 8080007 at samsung dot com> <CAFk3UF8To5Qcz8NN5rUF3z6j8CCg_89A+62P=1U9YrtbZ5=mLg at mail dot gmail dot com> <20150410203927 dot GA18980 at atrey dot karlin dot mff dot cuni dot cz> <552E1613 dot 2040405 at samsung dot com> <5536278E dot 3090706 at samsung dot com>
On Tue, Apr 21, 2015 at 6:33 AM, Ilya Palachev <i.palachev@samsung.com> wrote:
> ping?
>
> On 15.04.2015 10:41, Ilya Palachev wrote:
>>
>> Hi,
>>
>> One more question.
>>
> Does anybody know with which options should the perf be executed so that to
> collect appropriate data for the autofdo converter?
>From the autofdo page: https://github.com/google/autofdo
[ ... ]
Inputs:
--profile: PERF_PROFILE collected using linux perf (with last branch record).
In order to collect this profile, you will need to have an Intel CPU that
have last branch record (LBR) support. You also need to have your linux
kernel configured with LBR support. To profile:
# perf record -c PERIOD -e EVENT -b -o perf.data -- ./command
EVENT is refering to BR_INST_RETIRED:TAKEN if available. For some
architectures, BR_INST_EXEC:TAKEN also works.
[ ... ]
The important one for autofdo is -b. It asks perf to use LBR registers
for branch tracking (assuming your architecture supports it).
The binary you run under perf should also have line table information
(compiled with -gmlt) to produce location support for autofdo.
Diego.