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

Support floats with some atomic operations #3683

Merged
merged 3 commits into from Dec 31, 2019
Merged

Conversation

Vexu
Copy link
Member

@Vexu Vexu commented Nov 13, 2019

Adds support for floats in @atomicLoad, @atomicStore and @atomicRmw with .Xchg, .Add and .Sub.

Support for LLVMAtomicRMWBinOpFSub and LLVMAtomicRMWBinOpFAddin LLVM c API was added a week after 9.0.0 was released so this is waiting for 9.0.1.

@daurnimator daurnimator added the upstream An issue with a third party project that Zig uses. label Nov 20, 2019
@andrewrk
Copy link
Member

andrewrk commented Dec 16, 2019

Support for LLVMAtomicRMWBinOpFSub and LLVMAtomicRMWBinOpFAddin LLVM c API was added a week after 9.0.0 was released so this is waiting for 9.0.1.

I propose to make it work with 9.0.0 by adding the relevant wrapper code in src/zig_llvm.cpp / src/zig_llvm.h. Then we don't have to deal with people filing bug reports when their system package managers have 9.0.0 and getting compile errors when building Zig.

@andrewrk
Copy link
Member

andrewrk commented Dec 16, 2019

Also, note the official github repo is https://github.com/llvm/llvm-project, and the commit you noted there did not make it into the release/9.x branch, so the new LLVM API won't be available until llvm 10.0.0.

@andrewrk andrewrk removed the upstream An issue with a third party project that Zig uses. label Dec 16, 2019
@Vexu Vexu marked this pull request as ready for review December 16, 2019 22:35
@andrewrk andrewrk merged commit 73e535e into ziglang:master Dec 31, 2019
@Vexu Vexu deleted the atomic-float branch December 31, 2019 09:04
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.

None yet

3 participants