-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Make Pulley pass simd_f32x4_arith.wast
#9897
base: main
Are you sure you want to change the base?
Conversation
Adds float SIMD instructions on 4 lanes (f32x4) for subtraction, multiplication, division, and negation. `vtrunc32x4` and `vmuli32x4` were used as basis on how to organize things.
To be exact: `spec_testsuite/simd_f32x4_arith.wast` has been removed from the should fail list for Pulley.
Subscribe to Label Actioncc @fitzgen
This issue or pull request has been labeled: "cranelift", "pulley"
Thus the following users have been cc'd because of the following labels:
To subscribe or unsubscribe from this label, edit the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
pulley/src/lib.rs
Outdated
/// `low128(dst) = low128(src1) - low128(src2)` | ||
vsub32x4 = Vsub32x4 { operands: BinaryOperands<VReg> }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mind using f32x4
in the opcodes (e.g. vsubf32x4
) to clearly indicate that it's for floats and not integers?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be done
Specifically: - "vsub32x4" -> "vsubf32x4" - "vmul32x4" -> "vmulf32x4" - "vdiv32x4" -> "vdivf32x4"
Helping towards issue #9783.
This PR makes Pulley pass
spec_testsuite/simd_f32x4_arith.wast
, by adding f32x4 instructions for subtraction, negation, multiplication, and division.Random notes:
pulley/src/lib.rs
are based on what is done withvtrunc32x4
.vmuli32x4
.ftrunc32
,vtrunc32x4
, andvtrunc64x2
are together, butftrunc64
isn't near there.f
at the end, e.g.vtrunc32x4
vs.vabsf32x4
.