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

Handle microarchitectures #161

Open
WillAbides opened this issue Jun 3, 2023 · 0 comments
Open

Handle microarchitectures #161

WillAbides opened this issue Jun 3, 2023 · 0 comments

Comments

@WillAbides
Copy link
Owner

WillAbides commented Jun 3, 2023

Make it simpler to handle micro-architectures so that the same dependency can target multiple microarchitectures for the same arch. For instance both binname-linux-armv5 and binname-linux-armv6.

Considerations

Systems

Currently a system is "os/arch". I think we will need to expand this to "os/arch[/microarch]" with unspecified microarch defaulting to go's default when unspecified. So linux/arm/v5 will download binname-linux-armv5 while both linux/arm and linux/arm/v6 will download binname-linux-armv6.

Multiple types of microarchitecture.

Go defines microarchitecture with different variables depending on the GOARCH. Those vars are currently:

var arches values default
GO386 386 softfloat, sse2 sse2
GOARM arm 5, 6, 7 6
GOAMD64 amd64 v1, v2, v3, v4 v1
GOMIPS mips, mipsle hardfloat, softfloat hardfloat
GOPPC64 ppc64 power8, power9 power8

Because no arch has more than one var, we may be able to have one template var for all archs. Something like {{ .microArch }}. We should also populate {{ .go386 }}, {{ .goarm }}, etc.

This assumes there will never by a single GOARCH that can have multiple microarchs. I think that's a safe assumption. If this changes, we may need to make a breaking change.

add-by-*

No more details...just need to remember to consider dependency add-by-urls and dependency add-by-github-release.

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