Allow filling zero count for all the function ranges even there is no samples hitting that function. Add a switch for this.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Updating D112858: [llvm-profgen] Add a switch to fill zero count for all function ranges
llvm/test/tools/llvm-profgen/inline-noprobe.test | ||
---|---|---|
7 | Does it work when given an empty raw profile? Can it also work without giving a profile input? That can be a real scenario. |
llvm/test/tools/llvm-profgen/inline-noprobe.test | ||
---|---|---|
7 | No profile here would be great! |
llvm/test/tools/llvm-profgen/inline-noprobe.test | ||
---|---|---|
7 | I think asking user to provide an (empty) profile is reasonable.. Otherwise it feels a bit stretched for llvm-profgen as a profile generation tool. |
fix typo and test
llvm/test/tools/llvm-profgen/inline-noprobe.test | ||
---|---|---|
7 | Currently we only have PerfScriptReader and UnsymbolizedProfileReader which both need an input. To support no input profile, we might need lots of if (FillZeroForAllFuncs) else ... in validateCommandLine, PerfReader or an UnknownFileReader. Those seem make the code a little messy. Our internal tools also require an input which can be empty(two zero on the top). What do you think? |
llvm/test/tools/llvm-profgen/inline-noprobe.test | ||
---|---|---|
7 | Having an empty raw profile is enough, do you mind adding a test case for it? |
llvm/test/tools/llvm-profgen/inline-noprobe.test | ||
---|---|---|
7 | Good point, changed the test case with only two zero input. |
Does it work when given an empty raw profile? Can it also work without giving a profile input? That can be a real scenario.