Stream: git-wasmtime

Topic: wasmtime / PR #11647 [Cranelift] `(X | Y) + (X & Y) --> X...


view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 01:04):

bongjunj opened PR #11647 from bongjunj:fold-add-or-and to bytecodealliance:main:

<!--
Please make sure you include the following information:

Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.html

Please ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->

This adds (X | Y) + (X & Y) --> X +Y

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 01:04):

bongjunj requested alexcrichton for a review on PR #11647.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 01:04):

bongjunj requested wasmtime-compiler-reviewers for a review on PR #11647.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 01:08):

bongjunj edited PR #11647.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 03:03):

github-actions[bot] commented on PR #11647:

Subscribe to Label Action

cc @cfallin, @fitzgen

<details>
This issue or pull request has been labeled: "cranelift", "isle"

Thus the following users have been cc'd because of the following labels:

To subscribe or unsubscribe from this label, edit the <code>.github/subscribe-to-label.json</code> configuration file.

Learn more.
</details>

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 03:31):

bongjunj updated PR #11647.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 03:36):

bongjunj updated PR #11647.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 03:37):

bongjunj updated PR #11647.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 03:38):

bongjunj edited PR #11647.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 03:38):

bongjunj edited PR #11647:

<!--
Please make sure you include the following information:

Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.html

Please ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->

This adds two simplifications (X | Y) + (X & Y) --> X +Y

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 03:38):

bongjunj edited PR #11647:

<!--
Please make sure you include the following information:

Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.html

Please ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->

This adds two simplifications (X | Y) + (X & Y) --> X +Y and (X & Y) + (X ^ Y) --> X | Y.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 15:16):

alexcrichton submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 15:16):

alexcrichton created PR review comment:

Also, for the bxor/band -> bor reduction mind swapping the y x parameters to being x y like most other rules?

view this post on Zulip Wasmtime GitHub notifications bot (Sep 09 2025 at 15:16):

alexcrichton created PR review comment:

Could the commutative versions of these rules be added as well? For example

(rule (simplify (iadd ty (bxor ty y x) (band ty y x))) (bor ty y x))
(rule (simplify (iadd ty (band ty x y) (bor ty x y))) (iadd ty x y))

view this post on Zulip Wasmtime GitHub notifications bot (Sep 10 2025 at 01:09):

bongjunj submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 10 2025 at 01:09):

bongjunj created PR review comment:

Thanks! I missed that.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 10 2025 at 06:24):

bongjunj updated PR #11647.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 10 2025 at 06:26):

bongjunj updated PR #11647.

view this post on Zulip Wasmtime GitHub notifications bot (Sep 10 2025 at 14:46):

alexcrichton merged PR #11647.


Last updated: Dec 06 2025 at 06:05 UTC