return nil
}
-// Used to avoid string allocation when looking up dwarf symbols
-var prefixBuf = []byte(dwarf.InfoPrefix)
-
// find looks up the loader symbol for the DWARF DIE generated for the
// type with the specified name.
func (d *dwctxt2) find(name string) loader.Sym {
return expandGoroot(fname)
}
-func expandFileSym(l *loader.Loader, fsym loader.Sym) string {
- return expandFile(l.SymName(fsym))
-}
-
func (d *dwctxt2) writelines(unit *sym.CompilationUnit, ls loader.Sym) {
is_stmt := uint8(1) // initially = recommended default_is_stmt = 1, tracks is_stmt toggles.
return dwarfSecInfo{syms: append([]loader.Sym{locsym}, syms...)}
}
-/*
- * Elf.
- */
-func (d *dwctxt2) dwarfaddshstrings(ctxt *Link, shstrtab loader.Sym) {
- panic("not yet implemented")
-}
-
-// dwarfcompress compresses the DWARF sections. Relocations are applied
-// on the fly. After this, dwarfp will contain a different (new) set of
-// symbols, and sections may have been replaced.
-func (d *dwctxt2) dwarfcompress(ctxt *Link) {
- panic("not yet implemented")
-}
-
// getPkgFromCUSym returns the package name for the compilation unit
// represented by s.
// The prefix dwarf.InfoPrefix+".pkg." needs to be removed in order to get
DynStr2 loader.Sym
}
-const BeforeLoadlibFull = 1
-const AfterLoadlibFull = 2
-
// mkArchSym is a helper for setArchSyms, to set up a special symbol.
func (ctxt *Link) mkArchSym(name string, ver int, ls *loader.Sym) {
*ls = ctxt.loader.LookupOrCreateSym(name, ver)
}
// setArchSyms sets up the ArchSyms structure, and must be called before
-// relocations are applied. This function is invoked twice, once prior
-// to loadlibfull(), and once after the work of loadlibfull is complete.
+// relocations are applied.
func (ctxt *Link) setArchSyms() {
ctxt.mkArchSym(".got", 0, &ctxt.GOT2)
ctxt.mkArchSym(".plt", 0, &ctxt.PLT2)