-
Notifications
You must be signed in to change notification settings - Fork 42
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
Compiling with stable Rust #69
Comments
+1 [warezovvv@atlas rust-opencl]$ cargo build
Compiling opencl v0.3.0-dev (file:///home/warezovvv/Documents/Work/Projects/Robotics/rust-opencl)
src/lib.rs:5:1: 5:22 error: unstable feature
src/lib.rs:5 #![feature(std_misc)]
^~~~~~~~~~~~~~~~~~~~~
note: this feature may not be used in the stable release channel
error: aborting due to previous error
Could not compile `opencl`.
To learn more, run the command again with --verbose. |
If you want to be more efficient you can install (from brew for example)
|
I'd really like to see this in stable rust :) |
One thing holding this back right now is needing static mutexes. It looks like some OpenCL implementations do not properly handle multiple calls into the API, so we use a mutex to work around this. Line 134 in 282293c
It may be that OpenCL implementations are better now than when we added that code, or maybe we can just decide not to support broken implementations. I'm not sure whether calling |
Removed the mutex around clGetPlatformIDs, which may cause instability on some platforms. Also commented out the memory tests because they use slice_bytes.
I just started a branch that compiles on stable Rust: https://github.com/eholk/rust-opencl/tree/rust-stable I removed the platform lock, so we'll need some testing and experimentation to see if that was safe. Also, I commented out the memory tests because they use |
I am evaluating writing a project in Rust instead of C++. I am not sure if rust-opencl works with the stable Rust compilers. I have tried compiling rust-opencl with rustc 1.1.0 but I am getting "unstable feature" error.
Thanks,
Geoffrey
The text was updated successfully, but these errors were encountered: