summaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
diff options
context:
space:
mode:
authorluxufan <932494295@qq.com>2021-05-24 09:51:04 -0700
committerCraig Topper <craig.topper@sifive.com>2021-05-24 10:04:37 -0700
commitd70e9195a3339a6d56ed46ad4b8b467a0053322a (patch)
tree5adfef1b8f737205b19da587df5a04aeca8d4970 /llvm/lib/Bitcode/Reader/BitcodeReader.cpp
parentd35bd98651ec64a8c6c9e5b942d950a20ecdcb79 (diff)
[RISCV] Optimize getVLENFactoredAmount function.
If the local variable `NumOfVReg` isPowerOf2_32(NumOfVReg - 1) or isPowerOf2_32(NumOfVReg + 1), the ADDI and MUL instructions can be replaced with SLLI and ADD(or SUB) instructions. Based on original patch by StephenFan. Reviewed By: frasercrmck, StephenFan Differential Revision: https://reviews.llvm.org/D100577
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp')
0 files changed, 0 insertions, 0 deletions