mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-23 05:29:23 +00:00
Run clang-format on the parts of AsmPrinterDwarf where it improves the
readability. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@225726 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
34ae4e7151
commit
2f95648566
@ -35,22 +35,21 @@ using namespace llvm;
|
|||||||
/// DwarfExpression implementation for .debug_loc entries.
|
/// DwarfExpression implementation for .debug_loc entries.
|
||||||
class DebugLocDwarfExpression : public DwarfExpression {
|
class DebugLocDwarfExpression : public DwarfExpression {
|
||||||
ByteStreamer &BS;
|
ByteStreamer &BS;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
DebugLocDwarfExpression(TargetMachine &TM, ByteStreamer &BS)
|
DebugLocDwarfExpression(TargetMachine &TM, ByteStreamer &BS)
|
||||||
: DwarfExpression(TM), BS(BS) {}
|
: DwarfExpression(TM), BS(BS) {}
|
||||||
|
|
||||||
void EmitOp(uint8_t Op, const char* Comment) override;
|
void EmitOp(uint8_t Op, const char *Comment) override;
|
||||||
void EmitSigned(int Value) override;
|
void EmitSigned(int Value) override;
|
||||||
void EmitUnsigned(unsigned Value) override;
|
void EmitUnsigned(unsigned Value) override;
|
||||||
unsigned getFrameRegister() override {
|
unsigned getFrameRegister() override { llvm_unreachable("not available"); };
|
||||||
llvm_unreachable("not available");
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
void DebugLocDwarfExpression::EmitOp(uint8_t Op, const char* Comment) {
|
void DebugLocDwarfExpression::EmitOp(uint8_t Op, const char *Comment) {
|
||||||
BS.EmitInt8(Op, Comment
|
BS.EmitInt8(
|
||||||
? Twine(Comment)+" "+dwarf::OperationEncodingString(Op)
|
Op, Comment ? Twine(Comment) + " " + dwarf::OperationEncodingString(Op)
|
||||||
: dwarf::OperationEncodingString(Op));
|
: dwarf::OperationEncodingString(Op));
|
||||||
}
|
}
|
||||||
void DebugLocDwarfExpression::EmitSigned(int Value) {
|
void DebugLocDwarfExpression::EmitSigned(int Value) {
|
||||||
BS.EmitSLEB128(Value, Twine(Value));
|
BS.EmitSLEB128(Value, Twine(Value));
|
||||||
@ -59,7 +58,6 @@ void DebugLocDwarfExpression::EmitUnsigned(unsigned Value) {
|
|||||||
BS.EmitULEB128(Value, Twine(Value));
|
BS.EmitULEB128(Value, Twine(Value));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//===----------------------------------------------------------------------===//
|
//===----------------------------------------------------------------------===//
|
||||||
// Dwarf Emission Helper Routines
|
// Dwarf Emission Helper Routines
|
||||||
//===----------------------------------------------------------------------===//
|
//===----------------------------------------------------------------------===//
|
||||||
@ -249,8 +247,8 @@ void AsmPrinter::EmitDwarfRegOp(ByteStreamer &Streamer,
|
|||||||
// caller might be in the middle of a dwarf expression. We should
|
// caller might be in the middle of a dwarf expression. We should
|
||||||
// probably assert that Reg >= 0 once debug info generation is more
|
// probably assert that Reg >= 0 once debug info generation is more
|
||||||
// mature.
|
// mature.
|
||||||
return Expr.EmitOp(dwarf::DW_OP_nop,
|
return Expr.EmitOp(dwarf::DW_OP_nop,
|
||||||
"nop (could not find a dwarf register number)");
|
"nop (could not find a dwarf register number)");
|
||||||
|
|
||||||
// Attempt to find a valid super- or sub-register.
|
// Attempt to find a valid super- or sub-register.
|
||||||
return Expr.AddMachineRegPiece(MLoc.getReg());
|
return Expr.AddMachineRegPiece(MLoc.getReg());
|
||||||
|
Loading…
x
Reference in New Issue
Block a user