Skip to content

Commit

Permalink
[AArch64] Add support for Qualcomm's Falkor CPU.
Browse files Browse the repository at this point in the history
Differential Revision: https://reviews.llvm.org/D26673

llvm-svn: 287036
  • Loading branch information
Chad Rosier committed Nov 15, 2016
1 parent d23de36 commit 201fc1e
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 0 deletions.
2 changes: 2 additions & 0 deletions llvm/include/llvm/Support/AArch64TargetParser.def
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@ AARCH64_CPU_NAME("exynos-m1", AK_ARMV8A, FK_CRYPTO_NEON_FP_ARMV8, false,
(AArch64::AEK_SIMD | AArch64::AEK_CRC | AArch64::AEK_CRYPTO))
AARCH64_CPU_NAME("exynos-m2", AK_ARMV8A, FK_CRYPTO_NEON_FP_ARMV8, false,
(AArch64::AEK_SIMD | AArch64::AEK_CRC | AArch64::AEK_CRYPTO))
AARCH64_CPU_NAME("falkor", AK_ARMV8A, FK_CRYPTO_NEON_FP_ARMV8, false,
(AArch64::AEK_SIMD | AArch64::AEK_CRC | AArch64::AEK_CRYPTO))
AARCH64_CPU_NAME("kryo", AK_ARMV8A, FK_CRYPTO_NEON_FP_ARMV8, false,
(AArch64::AEK_SIMD | AArch64::AEK_CRC | AArch64::AEK_CRYPTO))
AARCH64_CPU_NAME("vulcan", AK_ARMV8_1A, FK_CRYPTO_NEON_FP_ARMV8, false,
Expand Down
10 changes: 10 additions & 0 deletions llvm/lib/Target/AArch64/AArch64.td
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,15 @@ def ProcKryo : SubtargetFeature<"kryo", "ARMProcFamily", "Kryo",
FeatureZCZeroing
]>;

def ProcFalkor : SubtargetFeature<"falkor", "ARMProcFamily", "Falkor",
"Qualcomm Falkor processors", [
FeatureCRC,
FeatureCrypto,
FeatureFPARMv8,
FeatureNEON,
FeaturePerfMon
]>;

def ProcVulcan : SubtargetFeature<"vulcan", "ARMProcFamily", "Vulcan",
"Broadcom Vulcan processors", [
FeatureCRC,
Expand Down Expand Up @@ -283,6 +292,7 @@ def : ProcessorModel<"cortex-a73", CortexA57Model, [ProcA73]>;
def : ProcessorModel<"cyclone", CycloneModel, [ProcCyclone]>;
def : ProcessorModel<"exynos-m1", ExynosM1Model, [ProcExynosM1]>;
def : ProcessorModel<"exynos-m2", ExynosM1Model, [ProcExynosM2]>;
def : ProcessorModel<"falkor", NoSchedModel, [ProcFalkor]>;
def : ProcessorModel<"kryo", KryoModel, [ProcKryo]>;
def : ProcessorModel<"vulcan", VulcanModel, [ProcVulcan]>;

Expand Down
1 change: 1 addition & 0 deletions llvm/lib/Target/AArch64/AArch64Subtarget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ void AArch64Subtarget::initializeProperties() {
case CortexA53: break;
case CortexA72: break;
case CortexA73: break;
case Falkor: break;
case Others: break;
}
}
Expand Down
1 change: 1 addition & 0 deletions llvm/lib/Target/AArch64/AArch64Subtarget.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ class AArch64Subtarget final : public AArch64GenSubtargetInfo {
CortexA73,
Cyclone,
ExynosM1,
Falkor,
Kryo,
Vulcan
};
Expand Down
1 change: 1 addition & 0 deletions llvm/test/CodeGen/AArch64/cpus.ll
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
; RUN: llc < %s -mtriple=arm64-unknown-unknown -mcpu=cortex-a73 2>&1 | FileCheck %s
; RUN: llc < %s -mtriple=arm64-unknown-unknown -mcpu=exynos-m1 2>&1 | FileCheck %s
; RUN: llc < %s -mtriple=arm64-unknown-unknown -mcpu=exynos-m2 2>&1 | FileCheck %s
; RUN: llc < %s -mtriple=arm64-unknown-unknown -mcpu=falkor 2>&1 | FileCheck %s
; RUN: llc < %s -mtriple=arm64-unknown-unknown -mcpu=kryo 2>&1 | FileCheck %s
; RUN: llc < %s -mtriple=arm64-unknown-unknown -mcpu=vulcan 2>&1 | FileCheck %s
; RUN: llc < %s -mtriple=arm64-unknown-unknown -mcpu=invalidcpu 2>&1 | FileCheck %s --check-prefix=INVALID
Expand Down
1 change: 1 addition & 0 deletions llvm/test/CodeGen/AArch64/remat.ll
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
; RUN: llc -mtriple=aarch64-linux-gnuabi -mcpu=cortex-a73 -o - %s | FileCheck %s
; RUN: llc -mtriple=aarch64-linux-gnuabi -mcpu=exynos-m1 -o - %s | FileCheck %s
; RUN: llc -mtriple=aarch64-linux-gnuabi -mcpu=exynos-m2 -o - %s | FileCheck %s
; RUN: llc -mtriple=aarch64-linux-gnuabi -mcpu=falkor -o - %s | FileCheck %s
; RUN: llc -mtriple=aarch64-linux-gnuabi -mcpu=kryo -o - %s | FileCheck %s
; RUN: llc -mtriple=aarch64-linux-gnuabi -mcpu=vulcan -o - %s | FileCheck %s
; RUN: llc -mtriple=aarch64-linux-gnuabi -mattr=+custom-cheap-as-move -o - %s | FileCheck %s
Expand Down
1 change: 1 addition & 0 deletions llvm/unittests/Support/TargetParserTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -550,6 +550,7 @@ TEST(TargetParserTest, AArch64parseCPUArch) {
"cyclone",
"exynos-m1",
"exynos-m2",
"falkor",
"kryo",
"vulcan"};

Expand Down

0 comments on commit 201fc1e

Please sign in to comment.