Going from LDX to LD requires that the LDX be word aligned in the first place. This is a requirement of the LD instruction bot not of the LDX instruction. If we are not word aligned we must leave the load as LDX.
This bug is causing a compile-time failure in the benchmark h264ref.
Details
Diff Detail
- Repository
- rL LLVM
Event Timeline
This is added by QingShan Zhang in https://reviews.llvm.org/D49007, add him as reviewer.
llvm/lib/Target/PowerPC/PPCInstrInfo.cpp | ||
---|---|---|
3069 ↗ | (On Diff #165082) | isImmElgibleForForwarding() will check if the ImmMO is elgible for forwarding. And it will check the alignment there according to the restriction with different instructions. |
Please add a test case that we used to transform to a D-Form and no longer do with your patch (preferably one for DS-Form and one for DQ-Form).
llvm/lib/Target/PowerPC/PPCInstrInfo.cpp | ||
---|---|---|
3067 ↗ | (On Diff #165082) | This comment also needs to be updated. The instruction does not require the data to be aligned, it requires the displacement to be a multiple of 4. |