remove a dead bool.
[llvm/avr.git] / lib / Target / Mips / MipsSubtarget.cpp
blobdb114da00d73420399c3a7ae162d9ef313fed34f
1 //===- MipsSubtarget.cpp - Mips Subtarget Information -----------*- C++ -*-===//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 //
10 // This file implements the Mips specific subclass of TargetSubtarget.
12 //===----------------------------------------------------------------------===//
14 #include "MipsSubtarget.h"
15 #include "Mips.h"
16 #include "MipsGenSubtarget.inc"
17 using namespace llvm;
19 MipsSubtarget::MipsSubtarget(const std::string &TT, const std::string &FS,
20 bool little) :
21 MipsArchVersion(Mips1), MipsABI(O32), IsLittle(little), IsSingleFloat(false),
22 IsFP64bit(false), IsGP64bit(false), HasVFPU(false), IsLinux(true),
23 HasSEInReg(false), HasCondMov(false), HasMulDivAdd(false), HasMinMax(false),
24 HasSwap(false), HasBitCount(false)
26 std::string CPU = "mips1";
27 MipsArchVersion = Mips1;
29 // Parse features string.
30 ParseSubtargetFeatures(FS, CPU);
32 // Is the target system Linux ?
33 if (TT.find("linux") == std::string::npos)
34 IsLinux = false;
36 // When only the target triple is specified and is
37 // a allegrex target, set the features. We also match
38 // big and little endian allegrex cores (dont really
39 // know if a big one exists)
40 if (TT.find("mipsallegrex") != std::string::npos ||
41 TT.find("psp") != std::string::npos) {
42 MipsABI = EABI;
43 IsSingleFloat = true;
44 MipsArchVersion = Mips2;
45 HasVFPU = true; // Enables Allegrex Vector FPU (not supported yet)
46 HasSEInReg = true;
47 HasBitCount = true;
48 HasSwap = true;
49 HasCondMov = true;