Skip to content

fcvt.bf16.s encoding collides with fround.h from zfa #33

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

Closed
asb opened this issue Mar 27, 2023 · 12 comments
Closed

fcvt.bf16.s encoding collides with fround.h from zfa #33

asb opened this issue Mar 27, 2023 · 12 comments

Comments

@asb
Copy link
Contributor

asb commented Mar 27, 2023

The Zfa extension describes fround.h as "encoded like FCVT.H.S, but with rs2=4". This collides with the proposed fcvt.bf16.s encoding which also uses 4 in the rs2 position:

field bits<32> Inst = { 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, rs1{4}, rs1{3}, rs1{2}, rs1{1}, rs1{0}, frm{2}, frm{1}, frm{0}, rd{4}, rd{3}, rd{2}, rd{1}, rd{0}, 1, 0, 1, 0, 0, 1, 1 };
@asb
Copy link
Contributor Author

asb commented Apr 3, 2023

Just a ping on this.

@kdockser
Copy link
Collaborator

kdockser commented Apr 5, 2023

Thanks for pointing this out Alex. I'm looking into a new encoding for fcvt.bf16.s.

@kdockser
Copy link
Collaborator

kdockser commented Apr 6, 2023

fcvt.bf16.s is now encoded like FCVT.H.S, but with rs2=8
This will be updated in the spec soon.

@kdockser kdockser closed this as completed Apr 6, 2023
@preames
Copy link

preames commented Apr 10, 2023

@kdockser Could I ask you to roll a new release artifact with this change and a new version number? Having a cite-able PDF with a distinct version will make it easier to do change tracking for downstream projects. In particular, this should unblock us landing experimental support in LLVM.

@kdockser
Copy link
Collaborator

Reopened until the change is pushed (which will be soon).

@asb
Copy link
Contributor Author

asb commented Apr 19, 2023

I see the change is pushed now (thanks!), but a new PDF build and an incremented spec version number would be much appreciated. I could commit the experimental support for bfloat16 with reference to the current commit id, but it's not ideal that people wanting to review the implementation can't easily access a PDF.

@asb
Copy link
Contributor Author

asb commented Apr 26, 2023

The spec number is now incremented (thanks!) - would it be possible to get a new PDF release?

@kdockser
Copy link
Collaborator

A new PDF has been released. This includes that changes suggested by the AR Committee.

@asb
Copy link
Contributor Author

asb commented Apr 30, 2023

@kdockser I'm not seeing the new PDF? The last tagged release is https://github.com/riscv/riscv-bfloat16/releases/tag/20230322 (March 22nd)

@asb
Copy link
Contributor Author

asb commented May 10, 2023

@kdockser I'm not seeing the new PDF? The last tagged release is https://github.com/riscv/riscv-bfloat16/releases/tag/20230322 (March 22nd)

Another ping, as the PDF still doesn't seem to be posted. Many thanks.

@asb
Copy link
Contributor Author

asb commented May 17, 2023

It seems a new PDF was posted last week, so this request can be considered answered. Thank you.

@asb
Copy link
Contributor Author

asb commented May 17, 2023

With the PDF now available, I've been able to update the LLVM assembler/disassembler patches based on the v0.6 version of the spec:

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

3 participants