LLVM 19.0.0git
HexagonAttributeParser.cpp
Go to the documentation of this file.
1//===-- HexagonAttributeParser.cpp - Hexagon Attribute Parser -------------===//
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
10
11using namespace llvm;
12
13const HexagonAttributeParser::DisplayHandler
14 HexagonAttributeParser::DisplayRoutines[] = {
15 {
18 },
19 {
22 },
23 {
26 },
27 {
30 },
31 {
34 },
35 {
38 },
39 {
42 }};
43
44Error HexagonAttributeParser::handler(uint64_t Tag, bool &Handled) {
45 Handled = false;
46 for (const auto &R : DisplayRoutines) {
47 if (uint64_t(R.Attribute) == Tag) {
48 if (Error E = (this->*R.Routine)(Tag))
49 return E;
50 Handled = true;
51 break;
52 }
53 }
54 return Error::success();
55}
Error integerAttribute(unsigned tag)
Lightweight error class with error context and mandatory checking.
Definition: Error.h:160
static ErrorSuccess success()
Create a success value.
Definition: Error.h:334
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18