From 29e874dd2e7e40a3276af38bc2cfafd3af8230f6 Mon Sep 17 00:00:00 2001 From: Eric Christopher Date: Fri, 7 Mar 2014 22:40:37 +0000 Subject: Two part patch: First: refactor out the emission of entries into the .debug_loc section into its own routine. Second: add a new class ByteStreamer that can be used to either emit using an AsmPrinter or hash using DIEHash the series of bytes that would be emitted. Use this in all of the location emission routines for the .debug_loc section. No functional change intended outside of a few additional comments in verbose assembly. llvm-svn: 203304 --- llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h') diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h index 1373e96d009..0dadb73562e 100644 --- a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h +++ b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h @@ -31,6 +31,7 @@ namespace llvm { +class ByteStreamer; class DwarfUnit; class DwarfCompileUnit; class ConstantInt; @@ -587,6 +588,9 @@ class DwarfDebug : public AsmPrinterHandler { /// \brief Emit visible names into a debug str section. void emitDebugStr(); + /// \brief Emit an entry for the debug loc section. + void emitDebugLocEntry(ByteStreamer &Streamer, const DotDebugLocEntry &Entry); + /// \brief Emit visible names into a debug loc section. void emitDebugLoc(); -- cgit v1.2.3