-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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]: bfloat16 cast fails #1297
Comments
I failed to reproduce this on MacOS. I'll try again later on Ubuntu. |
|
Possibly related: JuliaLang/julia#52067 My device is an Intel on an ASUS machine. |
I also can't reproduce this. In the repl I get this:
and when i run it in a file, i also doesn't give me an error. |
I get the error regardless of let
|
Maybe it's the clang/LLVM version on my machine? Regardless, it's bad that it happens. |
Hmm, it seems like, you don't have the newest version of modular installed. Can you update it and reinstall mojo? I don't really think that is fixing that, but it was at leased tried then. |
OK, I spun up an Intel Ubuntu VM and was able to reproduce this in the repl but not in a file. We'll look into this. |
Interesting though I couldn't reproduce this. This might be for the same reason it also doesn't fail on MacOS. Might be depending on some CPU features |
Hmm, weird, when I run on file, it prints nothing. def main():
from random import rand
let image = rand[DType.float32](10)
let a = image.data().simd_load[1]().cast[DType.bfloat16]()
print(a, "something") # prints ' something' |
On mojo 0.7.0 (af002202) I get the same error: from random import rand
fn main():
let image = rand[DType.float32](10)
let a = image.data().simd_load[1]().cast[DType.bfloat16]()
let b = a.cast[DType.float32]()
print(str(b)) gives:
This is on a Intel(R) Xeon(R) w5-2455X |
This should be fixed in the next release! |
Bug description
Steps to reproduce
Repro
System information
The text was updated successfully, but these errors were encountered: