Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

testing: "B.Loop called with timer stopped" regression in 1.24.2 #73150

Closed
jakebailey opened this issue Apr 3, 2025 · 1 comment
Closed

testing: "B.Loop called with timer stopped" regression in 1.24.2 #73150

jakebailey opened this issue Apr 3, 2025 · 1 comment

Comments

@jakebailey
Copy link
Contributor

Go version

go version go1.24.2 linux/amd64

Output of go env in your module/workspace:

AR='ar'
CC='gcc'
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_ENABLED='1'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
CXX='g++'
GCCGO='gccgo'
GO111MODULE=''
GOAMD64='v1'
GOARCH='amd64'
GOAUTH='netrc'
GOBIN=''
GOCACHE='/home/jabaile/.cache/go-build'
GOCACHEPROG=''
GODEBUG=''
GOENV='/home/jabaile/.config/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFIPS140='off'
GOFLAGS=''
GOGCCFLAGS='-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=/tmp/go-build515752239=/tmp/go-build -gno-record-gcc-switches'
GOHOSTARCH='amd64'
GOHOSTOS='linux'
GOINSECURE=''
GOMOD='/home/jabaile/work/TypeScript-go/go.mod'
GOMODCACHE='/home/jabaile/go/pkg/mod'
GONOPROXY=''
GONOSUMDB=''
GOOS='linux'
GOPATH='/home/jabaile/go'
GOPRIVATE=''
GOPROXY='https://proxy.golang.org,direct'
GOROOT='/usr/local/go'
GOSUMDB='sum.golang.org'
GOTELEMETRY='local'
GOTELEMETRYDIR='/home/jabaile/.config/go/telemetry'
GOTMPDIR=''
GOTOOLCHAIN='auto'
GOTOOLDIR='/usr/local/go/pkg/tool/linux_amd64'
GOVCS=''
GOVERSION='go1.24.2'
GOWORK=''
PKG_CONFIG='pkg-config'

What did you do?

$ git clone --depth=1 https://github.com/microsoft/typescript-go.git
$ cd typescript-go
$ go test -run=- -bench=BenchmarkGetNormalizedAbsolutePath -benchtime=1x ./internal/tspath

What did you see happen?

$ go1.24.2 test -run=- -bench=BenchmarkGetNormalizedAbsolutePath -benchtime=1x ./internal/tspath
--- FAIL: BenchmarkGetNormalizedAbsolutePath/non-normalized_inputs/GetNormalizedAbsolutePath
    benchmark.go:417: B.Loop called with timer stopped
--- FAIL: BenchmarkGetNormalizedAbsolutePath/non-normalized_inputs/GetNormalizedAbsolutePath_(old)
    benchmark.go:417: B.Loop called with timer stopped
--- FAIL: BenchmarkGetNormalizedAbsolutePath/non-normalized_inputs
--- FAIL: BenchmarkGetNormalizedAbsolutePath/normalized_inputs/GetNormalizedAbsolutePath
    benchmark.go:417: B.Loop called with timer stopped
--- FAIL: BenchmarkGetNormalizedAbsolutePath/normalized_inputs/GetNormalizedAbsolutePath_(old)
    benchmark.go:417: B.Loop called with timer stopped
--- FAIL: BenchmarkGetNormalizedAbsolutePath/normalized_inputs
--- FAIL: BenchmarkGetNormalizedAbsolutePath/normalized_inputs_(long)/GetNormalizedAbsolutePath
    benchmark.go:417: B.Loop called with timer stopped
--- FAIL: BenchmarkGetNormalizedAbsolutePath/normalized_inputs_(long)/GetNormalizedAbsolutePath_(old)
    benchmark.go:417: B.Loop called with timer stopped
--- FAIL: BenchmarkGetNormalizedAbsolutePath/normalized_inputs_(long)
--- FAIL: BenchmarkGetNormalizedAbsolutePath
FAIL
exit status 1
FAIL    github.com/microsoft/typescript-go/internal/tspath      0.009s
FAIL

What did you expect to see?

$ go1.24.1 test -run=- -bench=BenchmarkGetNormalizedAbsolutePath -benchtime=1x ./internal/tspath
goos: linux
goarch: amd64
pkg: github.com/microsoft/typescript-go/internal/tspath
cpu: Intel(R) Core(TM) i9-10900K CPU @ 3.70GHz
BenchmarkGetNormalizedAbsolutePath/non-normalized_inputs/GetNormalizedAbsolutePath-20                  1              1461 ns/op               0 B/op          0 allocs/op
BenchmarkGetNormalizedAbsolutePath/non-normalized_inputs/GetNormalizedAbsolutePath_(old)-20            1             11891 ns/op              96 B/op          5 allocs/op
BenchmarkGetNormalizedAbsolutePath/normalized_inputs/GetNormalizedAbsolutePath-20                      1              1252 ns/op               0 B/op          0 allocs/op
BenchmarkGetNormalizedAbsolutePath/normalized_inputs/GetNormalizedAbsolutePath_(old)-20                1             10325 ns/op             240 B/op          9 allocs/op
BenchmarkGetNormalizedAbsolutePath/normalized_inputs_(long)/GetNormalizedAbsolutePath-20               1              1147 ns/op               0 B/op          0 allocs/op
BenchmarkGetNormalizedAbsolutePath/normalized_inputs_(long)/GetNormalizedAbsolutePath_(old)-20                 1             12934 ns/op            2080 B/op         12 allocs/op
PASS
ok      github.com/microsoft/typescript-go/internal/tspath      0.010s

The -benchtime=1x doesn't affect anything; removing it shows the same problem (just slower).

@jakebailey
Copy link
Contributor Author

No, this is our fault. We're calling b.Loop in a loop itself, which shouldn't work.

I'll fix this, but I guess this isn't a regression per se. Sorry!

@jakebailey jakebailey closed this as not planned Won't fix, can't repro, duplicate, stale Apr 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant