mirror of
https://github.com/golang/go
synced 2024-11-25 06:57:58 -07:00
parent
b7e9e9188a
commit
d64a2bddf0
@ -301,9 +301,9 @@ doelf(void)
|
||||
elfstr[ElfStrGosymcounts] = addstring(shstrtab, ".gosymcounts");
|
||||
elfstr[ElfStrGosymtab] = addstring(shstrtab, ".gosymtab");
|
||||
elfstr[ElfStrGopclntab] = addstring(shstrtab, ".gopclntab");
|
||||
elfstr[ElfStrSymtab] = addstring(shstrtab, ".symtab");
|
||||
elfstr[ElfStrStrtab] = addstring(shstrtab, ".strtab");
|
||||
dwarfaddshstrings(shstrtab);
|
||||
elfstr[ElfStrSymtab] = addstring(shstrtab, ".symtab");
|
||||
elfstr[ElfStrStrtab] = addstring(shstrtab, ".strtab");
|
||||
dwarfaddshstrings(shstrtab);
|
||||
}
|
||||
elfstr[ElfStrShstrtab] = addstring(shstrtab, ".shstrtab");
|
||||
|
||||
@ -644,10 +644,10 @@ asmb(void)
|
||||
elfsymsize = elfstro - elfsymo;
|
||||
write(cout, elfstrdat, elfstrsize);
|
||||
|
||||
if(debug['v'])
|
||||
Bprint(&bso, "%5.2f dwarf\n", cputime());
|
||||
if(debug['v'])
|
||||
Bprint(&bso, "%5.2f dwarf\n", cputime());
|
||||
|
||||
dwarfemitdebugsections();
|
||||
dwarfemitdebugsections();
|
||||
}
|
||||
} else if(dlm){
|
||||
seek(cout, HEADR+textsize+datsize, 0);
|
||||
@ -923,21 +923,21 @@ asmb(void)
|
||||
sh->addralign = 1;
|
||||
sh->addr = symdatva + 8 + symsize;
|
||||
|
||||
sh = newElfShdr(elfstr[ElfStrSymtab]);
|
||||
sh->type = SHT_SYMTAB;
|
||||
sh->off = elfsymo;
|
||||
sh->size = elfsymsize;
|
||||
sh->addralign = 8;
|
||||
sh->entsize = 24;
|
||||
sh->link = eh->shnum; // link to strtab
|
||||
sh = newElfShdr(elfstr[ElfStrSymtab]);
|
||||
sh->type = SHT_SYMTAB;
|
||||
sh->off = elfsymo;
|
||||
sh->size = elfsymsize;
|
||||
sh->addralign = 8;
|
||||
sh->entsize = 24;
|
||||
sh->link = eh->shnum; // link to strtab
|
||||
|
||||
sh = newElfShdr(elfstr[ElfStrStrtab]);
|
||||
sh->type = SHT_STRTAB;
|
||||
sh->off = elfstro;
|
||||
sh->size = elfstrsize;
|
||||
sh->addralign = 1;
|
||||
sh = newElfShdr(elfstr[ElfStrStrtab]);
|
||||
sh->type = SHT_STRTAB;
|
||||
sh->off = elfstro;
|
||||
sh->size = elfstrsize;
|
||||
sh->addralign = 1;
|
||||
|
||||
dwarfaddelfheaders();
|
||||
dwarfaddelfheaders();
|
||||
}
|
||||
|
||||
sh = newElfShstrtab(elfstr[ElfStrShstrtab]);
|
||||
@ -993,7 +993,7 @@ cflush(void)
|
||||
vlong
|
||||
cpos(void)
|
||||
{
|
||||
return seek(cout, 0, 1) + sizeof(buf.cbuf) - cbc;
|
||||
return seek(cout, 0, 1) + sizeof(buf.cbuf) - cbc;
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -576,7 +576,7 @@ loop:
|
||||
histfrogp++;
|
||||
} else
|
||||
collapsefrog(s);
|
||||
dwarfaddfrag(s->value, s->name);
|
||||
dwarfaddfrag(s->value, s->name);
|
||||
}
|
||||
goto loop;
|
||||
}
|
||||
|
@ -294,7 +294,7 @@ doelf(void)
|
||||
elfstr[ElfStrGosymcounts] = addstring(shstrtab, ".gosymcounts");
|
||||
elfstr[ElfStrGosymtab] = addstring(shstrtab, ".gosymtab");
|
||||
elfstr[ElfStrGopclntab] = addstring(shstrtab, ".gopclntab");
|
||||
dwarfaddshstrings(shstrtab);
|
||||
dwarfaddshstrings(shstrtab);
|
||||
}
|
||||
elfstr[ElfStrShstrtab] = addstring(shstrtab, ".shstrtab");
|
||||
|
||||
@ -660,11 +660,11 @@ asmb(void)
|
||||
lputl(symsize);
|
||||
lputl(lcsize);
|
||||
cflush();
|
||||
if(HEADTYPE != 10 && !debug['s']) {
|
||||
seek(cout, symo+8+symsize+lcsize, 0);
|
||||
if(debug['v'])
|
||||
Bprint(&bso, "%5.2f dwarf\n", cputime());
|
||||
dwarfemitdebugsections();
|
||||
if(HEADTYPE != 10 && !debug['s']) {
|
||||
seek(cout, symo+8+symsize+lcsize, 0);
|
||||
if(debug['v'])
|
||||
Bprint(&bso, "%5.2f dwarf\n", cputime());
|
||||
dwarfemitdebugsections();
|
||||
}
|
||||
} else if(dlm){
|
||||
seek(cout, HEADR+textsize+datsize, 0);
|
||||
@ -1059,7 +1059,7 @@ asmb(void)
|
||||
sh->addralign = 1;
|
||||
sh->addr = symdatva + 8 + symsize;
|
||||
|
||||
dwarfaddelfheaders();
|
||||
dwarfaddelfheaders();
|
||||
}
|
||||
|
||||
sh = newElfShstrtab(elfstr[ElfStrShstrtab]);
|
||||
@ -1140,7 +1140,7 @@ cflush(void)
|
||||
vlong
|
||||
cpos(void)
|
||||
{
|
||||
return seek(cout, 0, 1) + sizeof(buf.cbuf) - cbc;
|
||||
return seek(cout, 0, 1) + sizeof(buf.cbuf) - cbc;
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -605,7 +605,7 @@ loop:
|
||||
histfrogp++;
|
||||
} else
|
||||
collapsefrog(s);
|
||||
dwarfaddfrag(s->value, s->name);
|
||||
dwarfaddfrag(s->value, s->name);
|
||||
}
|
||||
goto loop;
|
||||
}
|
||||
|
@ -867,11 +867,11 @@ dwarfaddmachoheaders(void)
|
||||
|
||||
vlong fakestart;
|
||||
|
||||
// Zero vsize segments won't be loaded in memory, even so they
|
||||
// have to be page aligned in the file.
|
||||
// Zero vsize segments won't be loaded in memory, even so they
|
||||
// have to be page aligned in the file.
|
||||
fakestart = abbrevo & ~0xfff;
|
||||
|
||||
ms = newMachoSeg("__DWARF", 3);
|
||||
ms = newMachoSeg("__DWARF", 3);
|
||||
ms->fileoffset = fakestart;
|
||||
ms->filesize = abbrevo-fakestart + abbrevsize+linesize+infosize;
|
||||
|
||||
|
@ -324,8 +324,8 @@ loop:
|
||||
if (*p == ' ' && !inquote)
|
||||
break;
|
||||
|
||||
if(*p == '\\')
|
||||
p++;
|
||||
if(*p == '\\')
|
||||
p++;
|
||||
else if(*p == '"')
|
||||
inquote = !inquote;
|
||||
|
||||
|
@ -619,7 +619,7 @@ asmbmacho(vlong symdatva, vlong symo)
|
||||
md->fileoffset = symo+8+symsize;
|
||||
md->filesize = lcsize;
|
||||
|
||||
dwarfaddmachoheaders();
|
||||
dwarfaddmachoheaders();
|
||||
}
|
||||
|
||||
a = machowrite();
|
||||
|
Loading…
Reference in New Issue
Block a user