2006-02-05 06:50:24 +01:00
|
|
|
//===- SparcSubtarget.cpp - SPARC Subtarget Information -------------------===//
|
|
|
|
//
|
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
//
|
2007-12-29 21:36:04 +01:00
|
|
|
// This file is distributed under the University of Illinois Open Source
|
|
|
|
// License. See LICENSE.TXT for details.
|
2006-02-05 06:50:24 +01:00
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
//
|
|
|
|
// This file implements the SPARC specific subclass of TargetSubtarget.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
|
|
#include "SparcSubtarget.h"
|
|
|
|
#include "SparcGenSubtarget.inc"
|
|
|
|
using namespace llvm;
|
|
|
|
|
2010-02-04 07:34:01 +01:00
|
|
|
SparcSubtarget::SparcSubtarget(const std::string &TT, const std::string &FS,
|
|
|
|
bool is64Bit) :
|
|
|
|
IsV9(false),
|
|
|
|
V8DeprecatedInsts(false),
|
|
|
|
IsVIS(false),
|
|
|
|
Is64Bit(is64Bit) {
|
2006-02-05 06:50:24 +01:00
|
|
|
|
|
|
|
// Determine default and user specified characteristics
|
2010-02-04 07:34:01 +01:00
|
|
|
const char *CPU = "v8";
|
|
|
|
if (is64Bit) {
|
|
|
|
CPU = "v9";
|
|
|
|
IsV9 = true;
|
|
|
|
}
|
2006-02-05 06:50:24 +01:00
|
|
|
|
|
|
|
// Parse features string.
|
|
|
|
ParseSubtargetFeatures(FS, CPU);
|
2006-05-24 19:04:05 +02:00
|
|
|
}
|