mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-12-20 03:17:48 +00:00
Unify selectMipsCPU implementations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229595 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -43,7 +43,7 @@ using namespace llvm;
|
||||
|
||||
/// Select the Mips CPU for the given triple and cpu name.
|
||||
/// FIXME: Merge with the copy in MipsSubtarget.cpp
|
||||
static inline StringRef selectMipsCPU(StringRef TT, StringRef CPU) {
|
||||
StringRef MIPS_MC::selectMipsCPU(StringRef TT, StringRef CPU) {
|
||||
if (CPU.empty() || CPU == "generic") {
|
||||
Triple TheTriple(TT);
|
||||
if (TheTriple.getArch() == Triple::mips ||
|
||||
@@ -69,7 +69,7 @@ static MCRegisterInfo *createMipsMCRegisterInfo(StringRef TT) {
|
||||
|
||||
static MCSubtargetInfo *createMipsMCSubtargetInfo(StringRef TT, StringRef CPU,
|
||||
StringRef FS) {
|
||||
CPU = selectMipsCPU(TT, CPU);
|
||||
CPU = MIPS_MC::selectMipsCPU(TT, CPU);
|
||||
MCSubtargetInfo *X = new MCSubtargetInfo();
|
||||
InitMipsMCSubtargetInfo(X, TT, CPU, FS);
|
||||
return X;
|
||||
|
||||
Reference in New Issue
Block a user