Skip to content
This repository was archived by the owner on Apr 23, 2020. It is now read-only.

Commit cf76a97

Browse files
committed
ADT: add a helper to check if the Triple is ARM64
Add a trivial helper for checking if the architecture is AArch64 Little Endian or Big Endian. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@316837 91177308-0d34-0410-b5e6-96231b3b80d8
1 parent 72428f5 commit cf76a97

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

include/llvm/ADT/Triple.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -655,6 +655,11 @@ class Triple {
655655
return getArch() == Triple::arm || getArch() == Triple::armeb;
656656
}
657657

658+
/// Tests whether the target is AArch64 (little and big endian).
659+
bool isAArch64() const {
660+
return getArch() == Triple::aarch64 || getArch() == Triple::aarch64_be;
661+
}
662+
658663
/// Tests wether the target supports comdat
659664
bool supportsCOMDAT() const { return !isOSBinFormatMachO(); }
660665

0 commit comments

Comments
 (0)