Skip to content

Commit

Permalink
[RISCV] Remove a use of getMinVLen in favor of getRealMinVLen
Browse files Browse the repository at this point in the history
The later is possibly greater than the former, and thus the assert was overly strong when a wider VLEN was set at the command line.
  • Loading branch information
preames committed Jun 27, 2022
1 parent aadc9d2 commit 0533b6e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion llvm/lib/Target/RISCV/RISCVISelLowering.cpp
Expand Up @@ -3185,7 +3185,7 @@ SDValue RISCVTargetLowering::LowerOperation(SDValue Op,
// minimum size. e.g. <vscale x 2 x i32>. VLENB is in bytes so we calculate
// vscale as VLENB / 8.
static_assert(RISCV::RVVBitsPerBlock == 64, "Unexpected bits per block!");
if (Subtarget.getMinVLen() < RISCV::RVVBitsPerBlock)
if (Subtarget.getRealMinVLen() < RISCV::RVVBitsPerBlock)
report_fatal_error("Support for VLEN==32 is incomplete.");
// We assume VLENB is a multiple of 8. We manually choose the best shift
// here because SimplifyDemandedBits isn't always able to simplify it.
Expand Down

0 comments on commit 0533b6e

Please sign in to comment.