In DeadArgumentElimination, the call instructions will be replaced. We also need to set the prof weights so that function inlining can find the correct profile.
Details
Diff Detail
- Build Status
Buildable 4980 Build 4980: arc lint + arc unit
Event Timeline
lib/IR/Instruction.cpp | ||
---|---|---|
658 | Nit: "...call and invoke instructions" | |
659 | Why is this guard needed? Is there a difference in handling an instruction with no metadata and one with a call weight of 0? | |
test/Transforms/DeadArgElim/prof.ll | ||
1 ↗ | (On Diff #92362) | Nit: the file name is not very meaningful. |
3 ↗ | (On Diff #92362) | reserved? |
lib/IR/Instruction.cpp | ||
---|---|---|
659 | It should not be needed, removed. |
LGTM after you fix the test case.
lib/IR/Instruction.cpp | ||
---|---|---|
658 | Nit: "call and invoke instructions" | |
test/Transforms/DeadArgElim/call_profile.ll | ||
6 | Could you add the test case for the non va_arg case as well? There are two places in the code where a new instruction is created and you should check both the cases (or optionally refactor the code so that the new instruction creation and metadata copying is done in one helper function) |
Nit: "...call and invoke instructions"