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

Posit to uint64_t conversion #267

Open
MJChku opened this issue Dec 17, 2021 · 3 comments
Open

Posit to uint64_t conversion #267

MJChku opened this issue Dec 17, 2021 · 3 comments
Assignees

Comments

@MJChku
Copy link

MJChku commented Dec 17, 2021

Is it possible to convert posit to uint64_t which result the same as (uint64_t) &( posit to double) without converting to double first? In fact, I can't use xmm register at conversion.

@Ravenwater
Copy link
Contributor

Yes, I can add that to the library. I need to think through the rounding behavior.

@Ravenwater Ravenwater self-assigned this Dec 21, 2021
@MJChku
Copy link
Author

MJChku commented Dec 22, 2021

Thanks, I have a highly hacked use case of posit number, so I asked.

@Ravenwater
Copy link
Contributor

Picked this back up, but now I realize that I do not quite understand the ask. I thought initially that you simply wanted the posit bits returned in a uint64_t. But (uint64_t) &(posit to double) would imply that you want the address of a double conversion result, which would require a conversion to double, conflicting with your request.

So, I need a little bit more information about what you need in the API.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Backlog
Development

No branches or pull requests

2 participants