LLVM 24.0.0git
ARMTargetParserCommon.h
Go to the documentation of this file.
1//===---------------- ARMTargetParserCommon ---------------------*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8//
9// Code that is common to ARMTargetParser and AArch64TargetParser.
10//
11//===----------------------------------------------------------------------===//
12
13#ifndef LLVM_TARGETPARSER_ARMTARGETPARSERCOMMON_H
14#define LLVM_TARGETPARSER_ARMTARGETPARSERCOMMON_H
15
16#include "llvm/ADT/StringRef.h"
19
20namespace llvm {
21namespace ARM {
22
23enum class ISAKind { INVALID = 0, ARM, THUMB, AARCH64 };
24
25enum class EndianKind { INVALID = 0, LITTLE, BIG };
26
27/// Converts e.g. "armv8" -> "armv8-a"
29
30/// MArch is expected to be of the form (arm|thumb)?(eb)?(v.+)?(eb)?, but
31/// (iwmmxt|xscale)(eb)? is also permitted. If the former, return
32/// "v.+", if the latter, return unmodified string, minus 'eb'.
33/// If invalid, return empty string.
35
36// ARM, Thumb, AArch64
38
39// Little/Big endian
41
49
51 StringRef &Err, const llvm::Triple &Triple,
52 bool EnablePAuthLR = false);
53
54} // namespace ARM
55} // namespace llvm
56#endif
#define LLVM_ABI
Definition Compiler.h:215
Represent a constant reference to a string, i.e.
Definition StringRef.h:56
Triple - Helper class for working with autoconf configuration names.
Definition Triple.h:47
Define some predicates that are used for node matching.
Definition ARMEHABI.h:25
LLVM_ABI StringRef getCanonicalArchName(StringRef Arch)
MArch is expected to be of the form (arm|thumb)?(eb)?(v.
LLVM_ABI ISAKind parseArchISA(StringRef Arch)
LLVM_ABI StringRef getArchSynonym(StringRef Arch)
Converts e.g. "armv8" -> "armv8-a".
LLVM_ABI EndianKind parseArchEndian(StringRef Arch)
LLVM_ABI bool parseBranchProtection(StringRef Spec, ParsedBranchProtection &PBP, StringRef &Err, const llvm::Triple &Triple, bool EnablePAuthLR=false)
This is an optimization pass for GlobalISel generic memory operations.