aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/MachineScheduler.cpp
diff options
context:
space:
mode:
authorWang, Xin10 <xin10.wang@intel.com>2023-03-30 10:33:57 +0800
committerWang, Xin10 <xin10.wang@intel.com>2023-03-30 10:42:19 +0800
commit0bf75d85419e87d3cb0352f7ebc8ef252869e9f6 (patch)
treeb7d0be42ad950439ff341902eb66cfc3b0e651d4 /llvm/lib/CodeGen/MachineScheduler.cpp
parentc5c6781428a70d1fffd00a256a237cbf5a3ccfd3 (diff)
downloadllvm-0bf75d85419e87d3cb0352f7ebc8ef252869e9f6.zip
llvm-0bf75d85419e87d3cb0352f7ebc8ef252869e9f6.tar.gz
llvm-0bf75d85419e87d3cb0352f7ebc8ef252869e9f6.tar.bz2
Handle the unexpected inputs for pass HardwareLoops
For a function TryConvertLoop in pass HardwareLoops, wrong input arguments will lead to crash. There will be 3 cases. In line 342, compiler want to get something from HWLoopInfo.CountType, which depends on if argument Bitwidth is given, if not, will crash. In Function isHardwareLoopCandidate, it dereference CountType too. In Function InsertLoopDec, it dereference LoopDecrement. They all could lead to crash. This patch add condition to this pass, when we meet unexpected inputs then skip the pass. Reviewed By: samparker, fhahn Differential Revision: https://reviews.llvm.org/D146277
Diffstat (limited to 'llvm/lib/CodeGen/MachineScheduler.cpp')
0 files changed, 0 insertions, 0 deletions