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

Bug Error compiling with flash attn #2753

Closed
super-fun-surf opened this issue Jan 28, 2025 · 2 comments
Closed

Bug Error compiling with flash attn #2753

super-fun-surf opened this issue Jan 28, 2025 · 2 comments

Comments

@super-fun-surf
Copy link

this was working fine until recent commit

cargo run --example stable-diffusion-3 --features cuda,cudnn,flash-attn -- --prompt "donkey" --which 3.5-large --use-flash-attn

gives error

error[E0384]: cannot assign twice to immutable variable `builder`
  --> candle-flash-attn/build.rs:93:13
   |
76 |     let builder = bindgen_cuda::Builder::default()
   |         ------- first assignment to `builder`
...
93 |             builder = builder.arg("-D_USE_MATH_DEFINES");
   |             ^^^^^^^ cannot assign twice to immutable variable
   |
help: consider making this binding mutable
   |
76 |     let mut builder = bindgen_cuda::Builder::default()
   |         +++

For more information about this error, try `rustc --explain E0384`.
error: could not compile `candle-flash-attn` (build script) due to 1 previous error
@LaurentMazare
Copy link
Collaborator

Sorry about that, fix in #2754

@super-fun-surf
Copy link
Author

Works great. Thanks!

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

2 participants