mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-26 12:20:42 +00:00
ARM target now also recognize triplets like thumbv6-apple-darwin and set thumb mode and arch subversion. Eventually thumb triplets will go way and replaced with function notes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66435 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -53,7 +53,9 @@ unsigned ThumbTargetMachine::getJITMatchQuality() {
|
||||
|
||||
unsigned ThumbTargetMachine::getModuleMatchQuality(const Module &M) {
|
||||
std::string TT = M.getTargetTriple();
|
||||
if (TT.size() >= 6 && std::string(TT.begin(), TT.begin()+6) == "thumb-")
|
||||
// Match thumb-foo-bar, as well as things like thumbv5blah-*
|
||||
if (TT.size() >= 6 &&
|
||||
(TT.substr(0, 6) == "thumb-" || TT.substr(0, 6) == "thumbv"))
|
||||
return 20;
|
||||
|
||||
// If the target triple is something non-thumb, we don't match.
|
||||
@@ -105,7 +107,8 @@ unsigned ARMTargetMachine::getJITMatchQuality() {
|
||||
|
||||
unsigned ARMTargetMachine::getModuleMatchQuality(const Module &M) {
|
||||
std::string TT = M.getTargetTriple();
|
||||
if (TT.size() >= 4 && // Match arm-foo-bar, as well as things like armv5blah-*
|
||||
// Match arm-foo-bar, as well as things like armv5blah-*
|
||||
if (TT.size() >= 4 &&
|
||||
(TT.substr(0, 4) == "arm-" || TT.substr(0, 4) == "armv"))
|
||||
return 20;
|
||||
// If the target triple is something non-arm, we don't match.
|
||||
|
||||
Reference in New Issue
Block a user