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: export data doesn't need to record type parameter indices #47451

Closed
griesemer opened this issue Jul 28, 2021 · 6 comments
Closed

cmd/compile: export data doesn't need to record type parameter indices #47451

griesemer opened this issue Jul 28, 2021 · 6 comments
Assignees
Labels
Milestone

Comments

@griesemer
Copy link
Contributor

@griesemer griesemer commented Jul 28, 2021

Reminder issue:
With CL 338192 we don't need to record type parameter indices in the export data anymore.
Should adjust the format at some point.

cc: @mdempsky

@griesemer griesemer added this to the Go1.18 milestone Jul 28, 2021
@gopherbot
Copy link

@gopherbot gopherbot commented Jul 28, 2021

Change https://golang.org/cl/338192 mentions this issue: [dev.typeparams] cmd/compile: set type parameter indices when they are bound

Loading

@mdempsky
Copy link
Member

@mdempsky mdempsky commented Jul 28, 2021

The unified IR export data format has never used type parameter indices.

Loading

@mdempsky
Copy link
Member

@mdempsky mdempsky commented Jul 28, 2021

Sorry, I confused this to be about the debug IDs (which unified IR has never used at all).

Unified IR uses the indices for writing out export data, but they're not encoded into the export data at all. I've also played with even removing uses of them within the writer, and can do that if you'd like to remove TypeParam.Index from the API.

Loading

@griesemer
Copy link
Contributor Author

@griesemer griesemer commented Jul 28, 2021

I filed this issue because of this change on line 371. It seems to me that we read an index on that line that we don't need anymore?

Loading

@mdempsky
Copy link
Member

@mdempsky mdempsky commented Jul 28, 2021

Loading

gopherbot pushed a commit that referenced this issue Jul 29, 2021
…e bound

This is a port of CL 336249 with adjustments due to slightly
different handling of type parameter declaration in types2.

The CL also contains adjustments to the compiler front-end.

With this change it is not necessary to export type parameter
indices. Filed issue #47451 so we don't forget.

Change-Id: I2834f7be313fcb4763dff2a9058f1983ee6a81b3
Reviewed-on: https://go-review.googlesource.com/c/go/+/338192
Trust: Robert Griesemer <gri@golang.org>
Run-TryBot: Robert Griesemer <gri@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Findley <rfindley@google.com>
@gopherbot
Copy link

@gopherbot gopherbot commented Aug 6, 2021

Change https://golang.org/cl/340532 mentions this issue: [dev.typeparams] cmd/compile: don't export/import type parameter indices anymore

Loading

@gopherbot gopherbot closed this in d10a904 Aug 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants