// dwarf_reader.h -- parse dwarf2/3 debug information for gold -*- C++ -*-
-// Copyright 2007, 2008, 2009 Free Software Foundation, Inc.
+// Copyright 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
// Written by Ian Lance Taylor <iant@google.com>.
// This file is part of gold.
class Track_relocs;
struct LineStateMachine;
-uint64_t
-read_unsigned_LEB_128(const unsigned char* buffer, size_t* len);
-
-int64_t
-read_signed_LEB_128(const unsigned char* buffer, size_t* len);
-
// We can't do better than to keep the offsets in a sorted vector.
// Here, offset is the key, and file_num/line_num is the value.
struct Offset_to_lineno_entry
int header_num; // which file-list to use (i.e. which .o file are we in)
int file_num; // a pointer into files_
int line_num; // the line number in the source file
- // Offsets are unique within a section, so that's a sufficient sort key.
+
+ // When we add entries to the table, we always use the last entry
+ // with a given offset. Given proper DWARF info, this should ensure
+ // that the offset is a sufficient sort key.
bool operator<(const Offset_to_lineno_entry& that) const
{ return this->offset < that.offset; }
};
// This has relocations that point into buffer.
Track_relocs<size, big_endian> track_relocs_;
+ // The type of the reloc section in track_relocs_--SHT_REL or SHT_RELA.
+ unsigned int track_relocs_type_;
// This is used to figure out what section to apply a relocation to.
const unsigned char* symtab_buffer_;