mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
runtime: TestGdbPython 'print mapvar' should not need unwinding
issue #10017: TestGdbPython 'print mapvar' is reported to fail on ppc64. issue #10002: TestGdbPython 'print mapvar' is reported to fail on arm hardfloat. The testcase now uses plain line number in main. Unwinding issues are unrelated to the GDB map prettyprinter feature. Remove arch-specific t.Skip()s from those two issues. Fixes #10017 Fixes #10002 Change-Id: I9d50ffe2f3eb7bf65dd17c8c76a2677571de68ba Reviewed-on: https://go-review.googlesource.com/6267 Reviewed-by: Minux Ma <minux@golang.org>
This commit is contained in:
parent
e6248c9c99
commit
cb37cfa01c
1 changed files with 2 additions and 14 deletions
|
|
@ -9,7 +9,6 @@ import (
|
|||
"path/filepath"
|
||||
"regexp"
|
||||
"runtime"
|
||||
"strings"
|
||||
"testing"
|
||||
)
|
||||
|
||||
|
|
@ -28,14 +27,11 @@ func checkGdbPython(t *testing.T) {
|
|||
const helloSource = `
|
||||
package main
|
||||
import "fmt"
|
||||
func finish() {
|
||||
fmt.Println("hi")
|
||||
}
|
||||
func main() {
|
||||
mapvar := make(map[string]string,5)
|
||||
mapvar["abc"] = "def"
|
||||
mapvar["ghi"] = "jkl"
|
||||
finish()
|
||||
fmt.Println("hi") // line 8
|
||||
}
|
||||
`
|
||||
|
||||
|
|
@ -43,13 +39,6 @@ func TestGdbPython(t *testing.T) {
|
|||
if runtime.GOOS == "darwin" {
|
||||
t.Skip("gdb does not work on darwin")
|
||||
}
|
||||
if strings.HasPrefix(runtime.GOARCH, "ppc64") {
|
||||
t.Skip("gdb does not work on ppc64 - issue 10017")
|
||||
}
|
||||
|
||||
if runtime.GOOS == "linux" && runtime.GOARCH == "arm" {
|
||||
t.Skip("issue 10002")
|
||||
}
|
||||
|
||||
checkGdbPython(t)
|
||||
|
||||
|
|
@ -74,9 +63,8 @@ func TestGdbPython(t *testing.T) {
|
|||
|
||||
got, _ := exec.Command("gdb", "-nx", "-q", "--batch", "-iex",
|
||||
fmt.Sprintf("add-auto-load-safe-path %s/src/runtime", runtime.GOROOT()),
|
||||
"-ex", "br 'main.finish'",
|
||||
"-ex", "br main.go:8",
|
||||
"-ex", "run",
|
||||
"-ex", "up",
|
||||
"-ex", "echo BEGIN info goroutines\n",
|
||||
"-ex", "info goroutines",
|
||||
"-ex", "echo END\n",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue