2009-07-15 14:35:19 +08:00
|
|
|
//===-- ARMTargetInfo.cpp - ARM Target Implementation ---------------------===//
|
|
|
|
//
|
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
//
|
|
|
|
// This file is distributed under the University of Illinois Open Source
|
|
|
|
// License. See LICENSE.TXT for details.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
2014-03-23 07:51:00 +08:00
|
|
|
#include "MCTargetDesc/ARMMCTargetDesc.h"
|
2011-08-25 02:08:43 +08:00
|
|
|
#include "llvm/Support/TargetRegistry.h"
|
2009-07-15 14:35:19 +08:00
|
|
|
using namespace llvm;
|
|
|
|
|
2016-10-10 07:00:34 +08:00
|
|
|
Target &llvm::getTheARMLETarget() {
|
|
|
|
static Target TheARMLETarget;
|
|
|
|
return TheARMLETarget;
|
|
|
|
}
|
|
|
|
Target &llvm::getTheARMBETarget() {
|
|
|
|
static Target TheARMBETarget;
|
|
|
|
return TheARMBETarget;
|
|
|
|
}
|
|
|
|
Target &llvm::getTheThumbLETarget() {
|
|
|
|
static Target TheThumbLETarget;
|
|
|
|
return TheThumbLETarget;
|
|
|
|
}
|
|
|
|
Target &llvm::getTheThumbBETarget() {
|
|
|
|
static Target TheThumbBETarget;
|
|
|
|
return TheThumbBETarget;
|
|
|
|
}
|
2009-07-15 14:35:19 +08:00
|
|
|
|
2015-05-13 03:42:31 +08:00
|
|
|
extern "C" void LLVMInitializeARMTargetInfo() {
|
2016-10-10 07:00:34 +08:00
|
|
|
RegisterTarget<Triple::arm, /*HasJIT=*/true> X(getTheARMLETarget(), "arm",
|
Add backend name to Target to enable runtime info to be fed back into TableGen
Summary:
Make it possible to feed runtime information back to tablegen to enable
profile-guided tablegen-eration, detection of untested tablegen definitions, etc.
Being a cross-compiler by nature, LLVM will potentially collect data for multiple
architectures (e.g. when running 'ninja check'). We therefore need a way for
TableGen to figure out what data applies to the backend it is generating at the
time. This patch achieves that by including the name of the 'def X : Target ...'
for the backend in the TargetRegistry.
Reviewers: qcolombet
Reviewed By: qcolombet
Subscribers: jholewinski, arsenm, jyknight, aditya_nandakumar, sdardis, nemanjai, ab, nhaehnle, t.p.northover, javed.absar, qcolombet, llvm-commits, fedor.sergeev
Differential Revision: https://reviews.llvm.org/D39742
llvm-svn: 318352
2017-11-16 07:55:44 +08:00
|
|
|
"ARM", "ARM");
|
2016-10-10 07:00:34 +08:00
|
|
|
RegisterTarget<Triple::armeb, /*HasJIT=*/true> Y(getTheARMBETarget(), "armeb",
|
Add backend name to Target to enable runtime info to be fed back into TableGen
Summary:
Make it possible to feed runtime information back to tablegen to enable
profile-guided tablegen-eration, detection of untested tablegen definitions, etc.
Being a cross-compiler by nature, LLVM will potentially collect data for multiple
architectures (e.g. when running 'ninja check'). We therefore need a way for
TableGen to figure out what data applies to the backend it is generating at the
time. This patch achieves that by including the name of the 'def X : Target ...'
for the backend in the TargetRegistry.
Reviewers: qcolombet
Reviewed By: qcolombet
Subscribers: jholewinski, arsenm, jyknight, aditya_nandakumar, sdardis, nemanjai, ab, nhaehnle, t.p.northover, javed.absar, qcolombet, llvm-commits, fedor.sergeev
Differential Revision: https://reviews.llvm.org/D39742
llvm-svn: 318352
2017-11-16 07:55:44 +08:00
|
|
|
"ARM (big endian)", "ARM");
|
2009-07-15 14:35:19 +08:00
|
|
|
|
2016-10-10 07:00:34 +08:00
|
|
|
RegisterTarget<Triple::thumb, /*HasJIT=*/true> A(getTheThumbLETarget(),
|
Add backend name to Target to enable runtime info to be fed back into TableGen
Summary:
Make it possible to feed runtime information back to tablegen to enable
profile-guided tablegen-eration, detection of untested tablegen definitions, etc.
Being a cross-compiler by nature, LLVM will potentially collect data for multiple
architectures (e.g. when running 'ninja check'). We therefore need a way for
TableGen to figure out what data applies to the backend it is generating at the
time. This patch achieves that by including the name of the 'def X : Target ...'
for the backend in the TargetRegistry.
Reviewers: qcolombet
Reviewed By: qcolombet
Subscribers: jholewinski, arsenm, jyknight, aditya_nandakumar, sdardis, nemanjai, ab, nhaehnle, t.p.northover, javed.absar, qcolombet, llvm-commits, fedor.sergeev
Differential Revision: https://reviews.llvm.org/D39742
llvm-svn: 318352
2017-11-16 07:55:44 +08:00
|
|
|
"thumb", "Thumb", "ARM");
|
2016-10-10 07:00:34 +08:00
|
|
|
RegisterTarget<Triple::thumbeb, /*HasJIT=*/true> B(
|
Add backend name to Target to enable runtime info to be fed back into TableGen
Summary:
Make it possible to feed runtime information back to tablegen to enable
profile-guided tablegen-eration, detection of untested tablegen definitions, etc.
Being a cross-compiler by nature, LLVM will potentially collect data for multiple
architectures (e.g. when running 'ninja check'). We therefore need a way for
TableGen to figure out what data applies to the backend it is generating at the
time. This patch achieves that by including the name of the 'def X : Target ...'
for the backend in the TargetRegistry.
Reviewers: qcolombet
Reviewed By: qcolombet
Subscribers: jholewinski, arsenm, jyknight, aditya_nandakumar, sdardis, nemanjai, ab, nhaehnle, t.p.northover, javed.absar, qcolombet, llvm-commits, fedor.sergeev
Differential Revision: https://reviews.llvm.org/D39742
llvm-svn: 318352
2017-11-16 07:55:44 +08:00
|
|
|
getTheThumbBETarget(), "thumbeb", "Thumb (big endian)", "ARM");
|
2009-07-15 14:35:19 +08:00
|
|
|
}
|