1 //===-- SparcTargetInfo.cpp - Sparc Target Implementation -----------------===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
11 #include "llvm/IR/Module.h"
12 #include "llvm/Support/TargetRegistry.h"
15 Target &llvm::getTheSparcTarget() {
16 static Target TheSparcTarget;
17 return TheSparcTarget;
19 Target &llvm::getTheSparcV9Target() {
20 static Target TheSparcV9Target;
21 return TheSparcV9Target;
23 Target &llvm::getTheSparcelTarget() {
24 static Target TheSparcelTarget;
25 return TheSparcelTarget;
28 extern "C" void LLVMInitializeSparcTargetInfo() {
29 RegisterTarget<Triple::sparc, /*HasJIT=*/true> X(getTheSparcTarget(), "sparc",
31 RegisterTarget<Triple::sparcv9, /*HasJIT=*/true> Y(getTheSparcV9Target(),
32 "sparcv9", "Sparc V9");
33 RegisterTarget<Triple::sparcel, /*HasJIT=*/true> Z(getTheSparcelTarget(),
34 "sparcel", "Sparc LE");