all: remove scattered remnants of darwin/arm

This removes all conditions and conditional code (that I could find)
that depended on darwin/arm.

Fixes #35439 (since that only happened on darwin/arm)
Fixes #37611.

Change-Id: Ia4c32a5a4368ed75231075832b0b5bfb1ad11986
Reviewed-on: https://go-review.googlesource.com/c/go/+/227198
Run-TryBot: Austin Clements <austin@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
This commit is contained in:
Austin Clements 2020-04-03 12:22:27 -04:00
parent da8591b61c
commit f7e6ab44b4
50 changed files with 81 additions and 174 deletions

View file

@ -789,11 +789,6 @@ func asmb(ctxt *ld.Link) {
}
func asmb2(ctxt *ld.Link) {
machlink := uint32(0)
if ctxt.HeadType == objabi.Hdarwin {
machlink = uint32(ld.Domacholink(ctxt))
}
/* output symbol table */
ld.Symsize = 0
@ -811,9 +806,6 @@ func asmb2(ctxt *ld.Link) {
case objabi.Hplan9:
symo = uint32(ld.Segdata.Fileoff + ld.Segdata.Filelen)
case objabi.Hdarwin:
symo = uint32(ld.Segdwarf.Fileoff + uint64(ld.Rnd(int64(ld.Segdwarf.Filelen), int64(*ld.FlagRound))) + uint64(machlink))
case objabi.Hwindows:
symo = uint32(ld.Segdwarf.Fileoff + ld.Segdwarf.Filelen)
symo = uint32(ld.Rnd(int64(symo), ld.PEFILEALIGN))
@ -845,11 +837,6 @@ func asmb2(ctxt *ld.Link) {
case objabi.Hwindows:
// Do nothing
case objabi.Hdarwin:
if ctxt.LinkMode == ld.LinkExternal {
ld.Machoemitreloc(ctxt)
}
}
}
@ -872,9 +859,6 @@ func asmb2(ctxt *ld.Link) {
objabi.Hopenbsd:
ld.Asmbelf(ctxt, int64(symo))
case objabi.Hdarwin:
ld.Asmbmacho(ctxt)
case objabi.Hwindows:
ld.Asmbpe(ctxt)
}