runtime: preserve line directive caller filenames#1903
Draft
cpunion wants to merge 3 commits into
Draft
Conversation
Collaborator
Author
|
CI follow-up for 82d126f:
Local verification:
This PR still stacks on the caller-frame/debugline work from #1884; this commit makes the stacked PR suitable for regular PR CI without pushing anything to |
|
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
//linefilenames back to Go runtime spelling (foo.go,c:/foo/bar.go) and map empty directive filenames to??test/gocoverage for runtime.Caller / FuncForPC.FileLine under absolute, Windows-style, relative, and empty filename line directivesfixedbugs/issue18149.goandfixedbugs/issue22662.goStack note
This branch includes the caller-frame metadata commit from PR #1884 because these fixedbugs exercise
runtime.Caller; without that dependency, the current mainline placeholder returns???:1. The second commit is the scoped line-directive/source-position fix.Testing
go test ./test/goroot -count=1 -run TestGoRootRunCases -args -goroot "$(go env GOROOT)" -dirs fixedbugs -case '^fixedbugs/(issue18149|issue22662)\\.go$' -xfail /tmp/llgo-no-xfail.yaml -run-timeout 30sgo test ./test/go -run 'TestRuntimeCaller' -count=1go build -tags=dev -o /tmp/llgo-linedir-test ./cmd/llgoLLGO_ROOT=$PWD /tmp/llgo-linedir-test test ./test/go/runtime_caller_test.gogo test ./cl -run 'TestEmitDo|TestExplicitDefer|Test.*Rewrite|TestOffsetOfHelpersAndSourceLineCache' -count=1go test ./ssa -run 'TestFuncCall|TestSetBlockEx|TestClosureFuncPtrValue' -count=1(cd runtime && go test ./internal/runtime -count=1)go test ./test/goroot -count=1 -run TestGoRootRunCases -args -goroot "$(go env GOROOT)" -llgo /tmp/llgo-linedir-test -dirs fixedbugs -case '^fixedbugs/(issue18149|issue22662)\\.go$' -xfail /tmp/llgo-no-xfail.yaml -run-timeout 30sgo test ./test/goroot -count=1 -run TestGoRootRunCases -args -goroot "$(go env GOROOT)" -llgo /tmp/llgo-linedir-test -dirs fixedbugs -case '^fixedbugs/(issue18149|issue22662)\\.go$' -run-timeout 30sGOROOT CI is slow/disabled in this repo, so this PR relies on the targeted GOROOT runs above plus normal PR CI from the fork branch. I did not push any branch to
xgo-dev/llgo; the head branch is oncpunion/llgo.