Lines Matching defs:Opcode
64 /// opcode and an optional sequence of operands.
67 Instruction(uint8_t Opcode)
68 : Opcode(Opcode)
71 uint8_t Opcode;
77 /// Convenience methods to add a new instruction with the given opcode and
79 void addInstruction(uint8_t Opcode) {
80 Instructions.push_back(Instruction(Opcode));
83 void addInstruction(uint8_t Opcode, uint64_t Operand1) {
84 Instructions.push_back(Instruction(Opcode));
88 void addInstruction(uint8_t Opcode, uint64_t Operand1, uint64_t Operand2) {
89 Instructions.push_back(Instruction(Opcode));
103 uint8_t Opcode = Data.getU8(Offset);
104 // Some instructions have a primary opcode encoded in the top bits.
105 uint8_t Primary = Opcode & DWARF_CFI_PRIMARY_OPCODE_MASK;
108 // If it's a primary opcode, the first operand is encoded in the bottom
109 // bits of the opcode itself.
110 uint64_t Op1 = Opcode & DWARF_CFI_PRIMARY_OPERAND_MASK;
112 default: llvm_unreachable("Impossible primary CFI opcode");
122 // Extended opcode - its value is Opcode itself.
123 switch (Opcode) {
124 default: llvm_unreachable("Invalid extended CFI opcode");
130 addInstruction(Opcode);
134 addInstruction(Opcode, Data.getAddress(Offset));
138 addInstruction(Opcode, Data.getU8(Offset));
142 addInstruction(Opcode, Data.getU16(Offset));
146 addInstruction(Opcode, Data.getU32(Offset));
154 addInstruction(Opcode, Data.getULEB128(Offset));
158 addInstruction(Opcode, Data.getSLEB128(Offset));
165 addInstruction(Opcode, Data.getULEB128(Offset),
172 addInstruction(Opcode, Data.getULEB128(Offset),
348 /// \brief Print \p Opcode's operand number \p OperandIdx which has
350 static void printOperand(raw_ostream &OS, uint8_t Opcode, unsigned OperandIdx,
354 OperandType Type = OpTypes[Opcode][OperandIdx];
359 if (const char *OpcodeName = CallFrameString(Opcode))
362 OS << format(" Opcode %x", Opcode);
415 uint8_t Opcode = Instr.Opcode;
416 if (Opcode & DWARF_CFI_PRIMARY_OPCODE_MASK)
417 Opcode &= DWARF_CFI_PRIMARY_OPCODE_MASK;
418 OS << " " << CallFrameString(Opcode) << ":";
420 printOperand(OS, Opcode, i, Instr.Ops[i], CodeAlignmentFactor,