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

test with posits #77

Closed
oscardssmith opened this issue May 10, 2022 · 3 comments
Closed

test with posits #77

oscardssmith opened this issue May 10, 2022 · 3 comments
Assignees
Labels
duplicate ⏬ This issue or pull request already exists low precision 🚂 Low precision arithmetics, rounding, 32 or 16-bit.

Comments

@oscardssmith
Copy link

the performance would be awful (cause emulated floating point), but it would be interesting to use https://github.com/milankl/SoftPosit.jl to test posit accuracy at 16 bit.

@milankl
Copy link
Member

milankl commented May 10, 2022

Posit arithmetic is actually emulated using (un)signed integers. So on every operation a 16-bit posit is disassembled into its different bits (sign, regime, exp and fraction) and then afterwards they are concatenated again. But its slow, yes 😄

For SpeedyWeather.jl to run in 16-bit posits there are currently two bottlenecks

  • a type-flexible fourier transform (everything else is type flexible at the moment), see 16-bit FFT #31
  • (a much bigger bottleneck) rewriting the precision-critical algorithms for low precision. At the moment everything works fine in Float32, but lower precision will likely fail. So tricks like scaling, reordering, compensation have to be further build in.

@milankl milankl added the low precision 🚂 Low precision arithmetics, rounding, 32 or 16-bit. label May 10, 2022
@milankl
Copy link
Member

milankl commented Jun 13, 2022

See also milankl/SoftPosit.jl#64

@milankl milankl self-assigned this Jun 13, 2022
@milankl milankl added the duplicate ⏬ This issue or pull request already exists label May 16, 2023
@milankl
Copy link
Member

milankl commented May 16, 2023

closed in favour of #137

@milankl milankl closed this as completed May 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate ⏬ This issue or pull request already exists low precision 🚂 Low precision arithmetics, rounding, 32 or 16-bit.
Projects
None yet
Development

No branches or pull requests

2 participants