Details | Last modification | View Log | RSS feed
| Rev | Author | Line No. | Line |
|---|---|---|---|
| 14 | pmbaty | 1 | //===---- CSKYAttributeParser.h - CSKY Attribute Parser ---------*- 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 | #ifndef LLVM_SUPPORT_CSKYATTRIBUTEPARSER_H |
||
| 10 | #define LLVM_SUPPORT_CSKYATTRIBUTEPARSER_H |
||
| 11 | |||
| 12 | #include "llvm/Support/CSKYAttributes.h" |
||
| 13 | #include "llvm/Support/ELFAttributeParser.h" |
||
| 14 | |||
| 15 | namespace llvm { |
||
| 16 | class CSKYAttributeParser : public ELFAttributeParser { |
||
| 17 | struct DisplayHandler { |
||
| 18 | CSKYAttrs::AttrType attribute; |
||
| 19 | Error (CSKYAttributeParser::*routine)(unsigned); |
||
| 20 | }; |
||
| 21 | static const DisplayHandler displayRoutines[]; |
||
| 22 | |||
| 23 | Error dspVersion(unsigned tag); |
||
| 24 | Error vdspVersion(unsigned tag); |
||
| 25 | Error fpuVersion(unsigned tag); |
||
| 26 | Error fpuABI(unsigned tag); |
||
| 27 | Error fpuRounding(unsigned tag); |
||
| 28 | Error fpuDenormal(unsigned tag); |
||
| 29 | Error fpuException(unsigned tag); |
||
| 30 | Error fpuHardFP(unsigned tag); |
||
| 31 | |||
| 32 | Error handler(uint64_t tag, bool &handled) override; |
||
| 33 | |||
| 34 | public: |
||
| 35 | CSKYAttributeParser(ScopedPrinter *sw) |
||
| 36 | : ELFAttributeParser(sw, CSKYAttrs::getCSKYAttributeTags(), "csky") {} |
||
| 37 | CSKYAttributeParser() |
||
| 38 | : ELFAttributeParser(CSKYAttrs::getCSKYAttributeTags(), "csky") {} |
||
| 39 | }; |
||
| 40 | |||
| 41 | } // namespace llvm |
||
| 42 | |||
| 43 | #endif |