[all-commits] [llvm/llvm-project] 259fa7: [PGO] incorrect classof in InstrProfIncrementInst
Ellis Hoag via All-commits
all-commits at lists.llvm.org
Fri Jan 20 10:22:36 PST 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 259fa70885e9e0e9e396b198829769276a6a6069
https://github.com/llvm/llvm-project/commit/259fa70885e9e0e9e396b198829769276a6a6069
Author: Ellis Hoag <ellis.sparky.hoag at gmail.com>
Date: 2023-01-20 (Fri, 20 Jan 2023)
Changed paths:
M llvm/include/llvm/IR/IntrinsicInst.h
A llvm/test/Instrumentation/InstrProfiling/before-value-profile-lowering.ll
Log Message:
-----------
[PGO] incorrect classof in InstrProfIncrementInst
Class InstrProfIncrementInstStep inherits from InstrProfIncrementInst but cannot cast to InstrProfIncrementInst, because InstrProfIncrementInst::classof does not cover such circumstance。
Function InstrProfiling::run traverse all instruction in a module and try to cast them to InstrProfIncrementInst using dyn_cast, but it will return nullptr if the instruction is InstrProfIncrementInstStep(subclass of InstrProfIncrementInst).
Reviewed By: tejohnson, ellis
Differential Revision: https://reviews.llvm.org/D141579
More information about the All-commits
mailing list