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

[WASM] Use rounding_mul_shift_right for q15mulr_sat_s pattern #7134

Merged
merged 1 commit into from
Oct 29, 2022

Conversation

rootjalex
Copy link
Member

Noticed that the q15mulr_sat_s rule didn't use the corresponding intrinsic - meaning we'd lower rounding_mul_shift_right just to match the rule before.

@steven-johnson
Copy link
Contributor

Do we need an updated test in simd_op_check?

@rootjalex
Copy link
Member Author

rootjalex commented Oct 28, 2022

No, this change should have not introduce any code generation change - it just makes code generation (slightly) faster.

find_intrinsics will have already lifted the target pattern to a rounding_mul_shift_right. Before, when CodeGen_LLVM lowers that intrinsic (because CodeGen_WebAssembly doesn't pattern match it), the exact expected pattern is reproduced and then matched to the pattern that has the lowered form. Now we just side-step the lowering.

@rootjalex
Copy link
Member Author

Test failure appears unrelated

@rootjalex rootjalex merged commit bd15cee into main Oct 29, 2022
@rootjalex rootjalex deleted the rootjalex/wasm-q15mulr branch October 29, 2022 21:19
ardier pushed a commit to ardier/Halide-mutation that referenced this pull request Mar 3, 2024
…#7134)

Use rounding_mul_shift_right for WASM q15mulr_sat_s pattern
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

Successfully merging this pull request may close these issues.

2 participants