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

cmd/compile: Compiler regression in Go 1.16 - internal compiler error: child dcl collision on symbol [1.16 backport] #44433

Closed
gopherbot opened this issue Feb 19, 2021 · 3 comments
Assignees
Milestone

Comments

@gopherbot
Copy link

@gopherbot gopherbot commented Feb 19, 2021

@thanm requested issue #44378 to be considered for backport to the next 1.16 minor release.

@gopherbot please consider this for backport to 1.16

@gopherbot
Copy link
Author

@gopherbot gopherbot commented Feb 22, 2021

Change https://golang.org/cl/294789 mentions this issue: [release-branch.go1.16] cmd/compile: fix panic in DWARF-gen handling obfuscated code

@cagedmantis
Copy link
Contributor

@cagedmantis cagedmantis commented Feb 25, 2021

Approved. This is a serious issue.

@gopherbot
Copy link
Author

@gopherbot gopherbot commented Mar 1, 2021

Closed by merging 18e5d75 to release-branch.go1.16.

@gopherbot gopherbot closed this Mar 1, 2021
gopherbot pushed a commit that referenced this issue Mar 1, 2021
…obfuscated code

DWARF generation uses variable source positions (file/line/col) as a
way to uniquely identify locals and parameters, as part of the process
of matching up post-optimization variables with the corresponding
pre-optimization versions (since the DWARF needs to be in terms of the
original source constructs).

This strategy can run into problems when compiling obfuscated or
machine-generated code, where you can in some circumstances wind up
with two local variables that appear to have the same name, file,
line, and column. This patch changes DWARF generation to skip over
such duplicates as opposed to issuing a fatal error (if an
obfuscation tool is in use, it is unlikely that a human being will be
able to make much sense of DWARF info in any case).

Fixes #44433.

Change-Id: I198022d184701aa9ec3dce42c005d29b72d2e321
Reviewed-on: https://go-review.googlesource.com/c/go/+/294289
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: David Chase <drchase@google.com>
Reviewed-by: Jeremy Faller <jeremy@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
Trust: Than McIntosh <thanm@google.com>
Run-TryBot: Than McIntosh <thanm@google.com>
(cherry picked from commit e78e04c)
Reviewed-on: https://go-review.googlesource.com/c/go/+/294789
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants