Stream: git-wasmtime

Topic: wasmtime / PR #7465 Cranelift: Fix union node bitpacking


view this post on Zulip Wasmtime GitHub notifications bot (Nov 02 2023 at 20:11):

fitzgen requested abrown for a review on PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 02 2023 at 20:11):

fitzgen opened PR #7465 from fitzgen:fix-egraph-union to bytecodealliance:main:

It turns out we have just been taking the newest rewrite's value for a eclass union and never actually comparing costs and taking the value with the minimum cost. Whoops!

Fixing this made some test expectations fail, which we resolved by tweaking the cost function to give materializing constants nonzero cost. This way we prefer -x to 0 - x.

We also made elaboration function break ties between values with the same cost with the value index. It prefers larger value indices, since the original value's index will be lower than all of its rewritten values' indices. This heuristically prefers rewritten values because we hope our rewrites are all improvements even when the cost function can't show that.

<!--
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
-->

view this post on Zulip Wasmtime GitHub notifications bot (Nov 02 2023 at 20:11):

fitzgen requested wasmtime-compiler-reviewers for a review on PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 02 2023 at 20:14):

cfallin submitted PR review:

LGTM, and thanks for finding this!

view this post on Zulip Wasmtime GitHub notifications bot (Nov 02 2023 at 20:14):

cfallin has enabled auto merge for PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 03 2023 at 16:06):

fitzgen updated PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 03 2023 at 18:14):

fitzgen updated PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 03 2023 at 21:56):

fitzgen updated PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 03 2023 at 21:58):

fitzgen has enabled auto merge for PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 03 2023 at 22:20):

fitzgen updated PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 03 2023 at 22:20):

fitzgen has disabled auto merge for PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 03 2023 at 22:30):

fitzgen updated PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 06 2023 at 18:07):

fitzgen updated PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 06 2023 at 22:07):

fitzgen updated PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 07 2023 at 17:59):

fitzgen updated PR #7465.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 07 2023 at 19:37):

fitzgen merged PR #7465.


Last updated: Nov 22 2024 at 16:03 UTC