ARMWinEHPrinter.h (276479) | ARMWinEHPrinter.h (280031) |
---|---|
1//===--- ARMWinEHPrinter.h - Windows on ARM Unwind Information Printer ----===// 2// 3// The LLVM Compiler Infrastructure 4// 5// This file is distributed under the University of Illinois Open Source 6// License. See LICENSE.TXT for details. 7// 8//===----------------------------------------------------------------------===// 9 | 1//===--- ARMWinEHPrinter.h - Windows on ARM Unwind Information Printer ----===// 2// 3// The LLVM Compiler Infrastructure 4// 5// This file is distributed under the University of Illinois Open Source 6// License. See LICENSE.TXT for details. 7// 8//===----------------------------------------------------------------------===// 9 |
10#ifndef LLVM_READOBJ_ARMWINEHPRINTER_H 11#define LLVM_READOBJ_ARMWINEHPRINTER_H | 10#ifndef LLVM_TOOLS_LLVM_READOBJ_ARMWINEHPRINTER_H 11#define LLVM_TOOLS_LLVM_READOBJ_ARMWINEHPRINTER_H |
12 13#include "StreamWriter.h" 14#include "llvm/Object/COFF.h" 15#include "llvm/Support/ErrorOr.h" 16 17namespace llvm { 18namespace ARM { 19namespace WinEH { 20class RuntimeFunction; 21 22class Decoder { 23 static const size_t PDataEntrySize; 24 25 StreamWriter &SW; 26 raw_ostream &OS; 27 28 struct RingEntry { 29 uint8_t Mask; 30 uint8_t Value; | 12 13#include "StreamWriter.h" 14#include "llvm/Object/COFF.h" 15#include "llvm/Support/ErrorOr.h" 16 17namespace llvm { 18namespace ARM { 19namespace WinEH { 20class RuntimeFunction; 21 22class Decoder { 23 static const size_t PDataEntrySize; 24 25 StreamWriter &SW; 26 raw_ostream &OS; 27 28 struct RingEntry { 29 uint8_t Mask; 30 uint8_t Value; |
31 bool (Decoder::*Routine)(const support::ulittle8_t *, unsigned &, unsigned, 32 bool); | 31 bool (Decoder::*Routine)(const uint8_t *, unsigned &, unsigned, bool); |
33 }; 34 static const RingEntry Ring[]; 35 | 32 }; 33 static const RingEntry Ring[]; 34 |
36 bool opcode_0xxxxxxx(const support::ulittle8_t *Opcodes, unsigned &Offset, | 35 bool opcode_0xxxxxxx(const uint8_t *Opcodes, unsigned &Offset, |
37 unsigned Length, bool Prologue); | 36 unsigned Length, bool Prologue); |
38 bool opcode_10Lxxxxx(const support::ulittle8_t *Opcodes, unsigned &Offset, | 37 bool opcode_10Lxxxxx(const uint8_t *Opcodes, unsigned &Offset, |
39 unsigned Length, bool Prologue); | 38 unsigned Length, bool Prologue); |
40 bool opcode_1100xxxx(const support::ulittle8_t *Opcodes, unsigned &Offset, | 39 bool opcode_1100xxxx(const uint8_t *Opcodes, unsigned &Offset, |
41 unsigned Length, bool Prologue); | 40 unsigned Length, bool Prologue); |
42 bool opcode_11010Lxx(const support::ulittle8_t *Opcodes, unsigned &Offset, | 41 bool opcode_11010Lxx(const uint8_t *Opcodes, unsigned &Offset, |
43 unsigned Length, bool Prologue); | 42 unsigned Length, bool Prologue); |
44 bool opcode_11011Lxx(const support::ulittle8_t *Opcodes, unsigned &Offset, | 43 bool opcode_11011Lxx(const uint8_t *Opcodes, unsigned &Offset, |
45 unsigned Length, bool Prologue); | 44 unsigned Length, bool Prologue); |
46 bool opcode_11100xxx(const support::ulittle8_t *Opcodes, unsigned &Offset, | 45 bool opcode_11100xxx(const uint8_t *Opcodes, unsigned &Offset, |
47 unsigned Length, bool Prologue); | 46 unsigned Length, bool Prologue); |
48 bool opcode_111010xx(const support::ulittle8_t *Opcodes, unsigned &Offset, | 47 bool opcode_111010xx(const uint8_t *Opcodes, unsigned &Offset, |
49 unsigned Length, bool Prologue); | 48 unsigned Length, bool Prologue); |
50 bool opcode_1110110L(const support::ulittle8_t *Opcodes, unsigned &Offset, | 49 bool opcode_1110110L(const uint8_t *Opcodes, unsigned &Offset, |
51 unsigned Length, bool Prologue); | 50 unsigned Length, bool Prologue); |
52 bool opcode_11101110(const support::ulittle8_t *Opcodes, unsigned &Offset, | 51 bool opcode_11101110(const uint8_t *Opcodes, unsigned &Offset, |
53 unsigned Length, bool Prologue); | 52 unsigned Length, bool Prologue); |
54 bool opcode_11101111(const support::ulittle8_t *Opcodes, unsigned &Offset, | 53 bool opcode_11101111(const uint8_t *Opcodes, unsigned &Offset, |
55 unsigned Length, bool Prologue); | 54 unsigned Length, bool Prologue); |
56 bool opcode_11110101(const support::ulittle8_t *Opcodes, unsigned &Offset, | 55 bool opcode_11110101(const uint8_t *Opcodes, unsigned &Offset, |
57 unsigned Length, bool Prologue); | 56 unsigned Length, bool Prologue); |
58 bool opcode_11110110(const support::ulittle8_t *Opcodes, unsigned &Offset, | 57 bool opcode_11110110(const uint8_t *Opcodes, unsigned &Offset, |
59 unsigned Length, bool Prologue); | 58 unsigned Length, bool Prologue); |
60 bool opcode_11110111(const support::ulittle8_t *Opcodes, unsigned &Offset, | 59 bool opcode_11110111(const uint8_t *Opcodes, unsigned &Offset, |
61 unsigned Length, bool Prologue); | 60 unsigned Length, bool Prologue); |
62 bool opcode_11111000(const support::ulittle8_t *Opcodes, unsigned &Offset, | 61 bool opcode_11111000(const uint8_t *Opcodes, unsigned &Offset, |
63 unsigned Length, bool Prologue); | 62 unsigned Length, bool Prologue); |
64 bool opcode_11111001(const support::ulittle8_t *Opcodes, unsigned &Offset, | 63 bool opcode_11111001(const uint8_t *Opcodes, unsigned &Offset, |
65 unsigned Length, bool Prologue); | 64 unsigned Length, bool Prologue); |
66 bool opcode_11111010(const support::ulittle8_t *Opcodes, unsigned &Offset, | 65 bool opcode_11111010(const uint8_t *Opcodes, unsigned &Offset, |
67 unsigned Length, bool Prologue); | 66 unsigned Length, bool Prologue); |
68 bool opcode_11111011(const support::ulittle8_t *Opcodes, unsigned &Offset, | 67 bool opcode_11111011(const uint8_t *Opcodes, unsigned &Offset, |
69 unsigned Length, bool Prologue); | 68 unsigned Length, bool Prologue); |
70 bool opcode_11111100(const support::ulittle8_t *Opcodes, unsigned &Offset, | 69 bool opcode_11111100(const uint8_t *Opcodes, unsigned &Offset, |
71 unsigned Length, bool Prologue); | 70 unsigned Length, bool Prologue); |
72 bool opcode_11111101(const support::ulittle8_t *Opcodes, unsigned &Offset, | 71 bool opcode_11111101(const uint8_t *Opcodes, unsigned &Offset, |
73 unsigned Length, bool Prologue); | 72 unsigned Length, bool Prologue); |
74 bool opcode_11111110(const support::ulittle8_t *Opcodes, unsigned &Offset, | 73 bool opcode_11111110(const uint8_t *Opcodes, unsigned &Offset, |
75 unsigned Length, bool Prologue); | 74 unsigned Length, bool Prologue); |
76 bool opcode_11111111(const support::ulittle8_t *Opcodes, unsigned &Offset, | 75 bool opcode_11111111(const uint8_t *Opcodes, unsigned &Offset, |
77 unsigned Length, bool Prologue); 78 | 76 unsigned Length, bool Prologue); 77 |
79 void decodeOpcodes(ArrayRef<support::ulittle8_t> Opcodes, unsigned Offset, | 78 void decodeOpcodes(ArrayRef<uint8_t> Opcodes, unsigned Offset, |
80 bool Prologue); 81 82 void printRegisters(const std::pair<uint16_t, uint32_t> &RegisterMask); 83 84 ErrorOr<object::SectionRef> 85 getSectionContaining(const object::COFFObjectFile &COFF, uint64_t Address); 86 87 ErrorOr<object::SymbolRef> --- 23 unchanged lines hidden (view full) --- 111 Decoder(StreamWriter &SW) : SW(SW), OS(SW.getOStream()) {} 112 std::error_code dumpProcedureData(const object::COFFObjectFile &COFF); 113}; 114} 115} 116} 117 118#endif | 79 bool Prologue); 80 81 void printRegisters(const std::pair<uint16_t, uint32_t> &RegisterMask); 82 83 ErrorOr<object::SectionRef> 84 getSectionContaining(const object::COFFObjectFile &COFF, uint64_t Address); 85 86 ErrorOr<object::SymbolRef> --- 23 unchanged lines hidden (view full) --- 110 Decoder(StreamWriter &SW) : SW(SW), OS(SW.getOStream()) {} 111 std::error_code dumpProcedureData(const object::COFFObjectFile &COFF); 112}; 113} 114} 115} 116 117#endif |
119 | |