proc: replace use of runtime.GOARCH with Arch.Name (#3442)

This commit is contained in:
Alessandro Arzilli 2023-07-26 17:33:31 +02:00 committed by GitHub
parent 34104fb65d
commit 7db57df266
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -8,7 +8,6 @@ import (
"go/ast"
"go/token"
"path/filepath"
"runtime"
"strings"
"golang.org/x/arch/ppc64/ppc64asm"
@ -918,7 +917,7 @@ func setStepIntoBreakpoint(dbp *Target, curfn *Function, text []AsmInstruction,
pc := instr.DestLoc.PC
fn := instr.DestLoc.Fn
if runtime.GOARCH == "ppc64le" && instr.Inst.OpcodeEquals(uint64(ppc64asm.BCLRL)) {
if dbp.BinInfo().Arch.Name == "ppc64le" && instr.Inst.OpcodeEquals(uint64(ppc64asm.BCLRL)) {
regs, err := dbp.CurrentThread().Registers()
if err != nil {
return err