[RISCV] Optimize immediate materialisation with BCLRI
Do the following optimization for immediate materialisation: 1. For values in range 0xffffffff 7fffffff ~ 0xffffffff 00000000, first generate the lower 32-bit with Val|0x80000000 (which is expected be an int32), then emit (BCLRI r, 31). 2. For values in range 0x80000000 ~ 0xffffffff, first generate the lower 32-bit with Val&~0x80000000 (which is expected to be an int32), then emit (BSETI r, 31). Reviewed By: craig.topper Differential Revision: https://reviews.llvm.org/D111532
Loading
Please register or sign in to comment