mirror of
https://github.com/RPCS3/llvm.git
synced 2024-12-28 07:05:03 +00:00
965b20e39c
When accessing just a single CR register, it is always preferable to use mfocrf instead of mfcr, if the former is available on the CPU. Current code makes that distinction in many, but not all places where a single CR register value is retrieved. One missing location is PPCRegisterInfo::lowerCRSpilling. To fix this and make this simpler in the future, this patch changes the bulk of the back-end to always assume mfocrf is available and simply generate it when needed. On machines that actually do not support mfocrf, the instruction is replaced by mfcr at the very end, in EmitInstruction. This has the additional benefit that we no longer need the MFCRpseud hack, since before EmitInstruction we always have a MFOCRF instruction pattern, which already models data flow as required. The patch also adds the MFOCRF8 version of the instruction, which was missing so far. Except for the PPCRegisterInfo::lowerCRSpilling case, no change in generated code intended. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185556 91177308-0d34-0410-b5e6-96231b3b80d8 |
||
---|---|---|
.. | ||
CMakeLists.txt | ||
LLVMBuild.txt | ||
Makefile | ||
PPCAsmBackend.cpp | ||
PPCELFObjectWriter.cpp | ||
PPCFixupKinds.h | ||
PPCMCAsmInfo.cpp | ||
PPCMCAsmInfo.h | ||
PPCMCCodeEmitter.cpp | ||
PPCMCExpr.cpp | ||
PPCMCExpr.h | ||
PPCMCTargetDesc.cpp | ||
PPCMCTargetDesc.h | ||
PPCPredicates.cpp | ||
PPCPredicates.h |