aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Target/RISCV/Disassembler/RISCVDisassembler.cpp
diff options
context:
space:
mode:
authorPrakhar Dixit <75660779+Prakhar-Dixit@users.noreply.github.com>2025-02-26 07:09:24 +0530
committerGitHub <noreply@github.com>2025-02-26 10:39:24 +0900
commitda37c76ac621c64216e56ead3efe1bd569250ee2 (patch)
tree69872b5e27548766a4fcc54ad5e7e63ea7366175 /llvm/lib/Target/RISCV/Disassembler/RISCVDisassembler.cpp
parentb1a735b45dcc194ad9be08d057bc853ad1c1467b (diff)
downloadllvm-da37c76ac621c64216e56ead3efe1bd569250ee2.zip
llvm-da37c76ac621c64216e56ead3efe1bd569250ee2.tar.gz
llvm-da37c76ac621c64216e56ead3efe1bd569250ee2.tar.bz2
[mlir][vector] Add a check to ensure input vector rank equals target shape rank (#127706)
Fixes issue #126197 The crash is caused because, during IR transformation, the vector-unrolling pass (using ExtractStridedSliceOp) attempts to slice an input vector of higher rank using a target vector of lower rank, which is not supported. Specific example : ``` module { func.func @func1() { %cst_25 = arith.constant dense<3.718400e+04> : vector<4x2x2xf16> %cst_26 = arith.constant dense<1.000000e+00> : vector<24x2x2xf32> %47 = vector.fma %cst_26, %cst_26, %cst_26 : vector<24x2x2xf32> %818 = scf.execute_region -> vector<24x2x2xf32> { scf.yield %47 : vector<24x2x2xf32> } %823 = vector.extract_strided_slice %cst_25 {offsets = [2], sizes = [1], strides = [1]} : vector<4x2x2xf16> to vector<1x2x2xf16> return } } ``` --------- Co-authored-by: Kai Sasaki <lewuathe@gmail.com>
Diffstat (limited to 'llvm/lib/Target/RISCV/Disassembler/RISCVDisassembler.cpp')
0 files changed, 0 insertions, 0 deletions