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

fix: detect avx2 in base64 #740

Closed
wants to merge 1 commit into from
Closed

fix: detect avx2 in base64 #740

wants to merge 1 commit into from

Conversation

equal-l2
Copy link

@equal-l2 equal-l2 commented Jul 16, 2022

Currently, bun doesn't even build on non-AVX2 environment.
some package managers intentionally disable AVX2 to support older systems.

This PR fixes the build on non-AVX2 env, though I don't assure bun runs properly.

Disclaimer: I have not tested this because I don't have a non-AVX2 machine.

@equal-l2
Copy link
Author

Would anyone approve the workflows?

@KevinBLT
Copy link

I would also need a non-AVX2 build 👍

@memothelemo
Copy link

There's also a file that fails to compile on my non-AVX2 machine (src/base64/fastavxbase64.c).

You can add this condition as well if it has AVX2 capability. ;-)

@equal-l2
Copy link
Author

@memothelemo Thank you for pointing it out. I added a check.
Would you try again?

@equal-l2
Copy link
Author

@oven-sh Could you approve running workflows?
I can't build bun on my local env at this moment.

@memothelemo
Copy link

memothelemo commented Jul 22, 2022

@equal-l2 I was able to compile Base64 with some modifications with the header files before I send a comment to you.

I do not quite sure if it would compile the entire bun program successfully.
I'm still on my way to test your PR repository. ;)

@equal-l2
Copy link
Author

equal-l2 commented Jul 23, 2022

The same change has been made and merged in #824, which is contained in the new release 0.1.5.
This should enable you to build bun from source on non-AVX2 machines.

Closing now.

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

Successfully merging this pull request may close these issues.

3 participants