mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
[dev.cc] cmd/internal/obj: reconvert from liblink
cmd/internal/obj reconverted using rsc.io/c2go rev 2a95256.
- Brings in new, more regular Prog, Addr definitions
- Add Prog* argument to oclass in liblink/asm[68].c, for c2go conversion.
- Update objwriter for change in TEXT size encoding.
- Merge 5a, 6a, 8a, 9a changes into new5a, new6a, new8a, new9a (by hand).
- Add +build ignore to cmd/asm/internal/{addr,arch,asm}, cmd/asm.
They need to be updated for the changes.
- Reenable verifyAsm in cmd/go.
- Reenable GOOBJ=2 mode by default in liblink.
All architectures build successfully again.
Change-Id: I2c845c5d365aa484b570476898171bee657b626d
Reviewed-on: https://go-review.googlesource.com/3963
Reviewed-by: Rob Pike <r@golang.org>
This commit is contained in:
parent
8db173b85e
commit
1fc330d8fe
54 changed files with 6531 additions and 6787 deletions
|
|
@ -46,10 +46,6 @@ var headers = []struct {
|
|||
name string
|
||||
val int
|
||||
}{
|
||||
struct {
|
||||
name string
|
||||
val int
|
||||
}{"android", Hlinux},
|
||||
struct {
|
||||
name string
|
||||
val int
|
||||
|
|
@ -70,6 +66,10 @@ var headers = []struct {
|
|||
name string
|
||||
val int
|
||||
}{"linux", Hlinux},
|
||||
struct {
|
||||
name string
|
||||
val int
|
||||
}{"android", Hlinux}, // must be after "linux" entry or else headstr(Hlinux) == "android"
|
||||
struct {
|
||||
name string
|
||||
val int
|
||||
|
|
@ -129,6 +129,8 @@ func Linknew(arch *LinkArch) *Link {
|
|||
var p string
|
||||
var buf string
|
||||
|
||||
linksetexp()
|
||||
|
||||
ctxt = new(Link)
|
||||
ctxt.Arch = arch
|
||||
ctxt.Version = HistVersion
|
||||
|
|
@ -151,7 +153,6 @@ func Linknew(arch *LinkArch) *Link {
|
|||
// Record thread-local storage offset.
|
||||
// TODO(rsc): Move tlsoffset back into the linker.
|
||||
switch ctxt.Headtype {
|
||||
|
||||
default:
|
||||
log.Fatalf("unknown thread-local storage offset for %s", Headstr(ctxt.Headtype))
|
||||
|
||||
|
|
@ -194,7 +195,6 @@ func Linknew(arch *LinkArch) *Link {
|
|||
*/
|
||||
case Hdarwin:
|
||||
switch ctxt.Arch.Thechar {
|
||||
|
||||
default:
|
||||
log.Fatalf("unknown thread-local storage offset for darwin/%s", ctxt.Arch.Name)
|
||||
|
||||
|
|
@ -211,12 +211,10 @@ func Linknew(arch *LinkArch) *Link {
|
|||
|
||||
// On arm, record goarm.
|
||||
if ctxt.Arch.Thechar == '5' {
|
||||
|
||||
p = Getgoarm()
|
||||
if p != "" {
|
||||
ctxt.Goarm = int32(Atoi(p))
|
||||
} else {
|
||||
|
||||
ctxt.Goarm = 6
|
||||
}
|
||||
}
|
||||
|
|
@ -281,6 +279,5 @@ func Linklookup(ctxt *Link, name string, v int) *LSym {
|
|||
|
||||
// read-only lookup
|
||||
func linkrlookup(ctxt *Link, name string, v int) *LSym {
|
||||
|
||||
return _lookup(ctxt, name, v, 0)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue