-
Notifications
You must be signed in to change notification settings - Fork 17.7k
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
cmd/compile: panic: branch too far on arm64 #23889
Comments
Oh, I found another, much bigger reproducer that causes the crash even without
So this has nothing to do with optimizations, it just happen to be easier to trigger when optimizations are disabled. |
Change https://golang.org/cl/94902 mentions this issue: |
btw. I see this issue while compiling influxdb master using 1.10 on aarch64 and the patch above fixes the problem. So it might be a candidate for backport to 1.10 release.
|
@gopherbot please consider this for backport to 1.10. I just come cross this bug in my ios project with go version go1.10.3 darwin/amd64. Follow golang version do not have this bug in my ios project: |
Backport issue(s) opened: #25794 (for 1.10). Remember to create the cherry-pick CL(s) as soon as the patch is submitted to master, according to https://golang.org/wiki/MinorReleases. |
Change https://golang.org/cl/147057 mentions this issue: |
…th TBZ like instructions The compiler now emits TBZ like instructions, but the assembler's too-far-branch patch code didn't include that case. Add it. Updates #23889 Fixes #25794 Change-Id: Ib75f9250c660b9fb652835fbc83263a5d5073dc5 Reviewed-on: https://go-review.googlesource.com/94902 Run-TryBot: Cherry Zhang <cherryyz@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: David Chase <drchase@google.com> (cherry picked from commit 911839c) Reviewed-on: https://go-review.googlesource.com/c/147057 Reviewed-by: Cherry Zhang <cherryyz@google.com> Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
The program at the end of this report crashes the tip compiler when built for arm64 with optimizations disabled, as
GOARCH=arm64 go build -gcflags -N crash.go
, with the following error:go tool compile
says:The issue is not present in 1.10, and it was introduced in commit cdd9616 (cmd/compile: generate tbz/tbnz when comparing against zero on arm64).
Apologies for the reproducer length. The program was generated by a fuzzer and deleting any line makes the crash go away.
The text was updated successfully, but these errors were encountered: