Stream: git-wasmtime

Topic: wasmtime / PR #8151 Delay argument location use in `CallS...


view this post on Zulip Wasmtime GitHub notifications bot (Mar 15 2024 at 18:51):

elliottt opened PR #8151 from elliottt:trevor/gen-arg-locs to bytecodealliance:main:

In preparation for handling callee-save registers in the tail calling convention, split the logic for handling argument locations out of CallSite::gen_arg. This allows us to process the arguments as normal, but delay the actual move to the stack until later.
<!--
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 (Mar 15 2024 at 18:51):

elliottt requested cfallin for a review on PR #8151.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 15 2024 at 18:51):

elliottt requested wasmtime-compiler-reviewers for a review on PR #8151.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 15 2024 at 18:57):

elliottt updated PR #8151.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 15 2024 at 18:59):

elliottt edited PR #8151:

In preparation for handling callee-save registers in the tail calling convention, split the logic for handling argument locations out of CallSite::gen_arg. This allows us to process the arguments as normal, but delay the actual move to the stack until later.

I also took the opportunity to directly emit the instruction vector at the end of CallSite::gen_arg instead of returning it, as this is what's done at every use of CallSite::gen_arg already. Unfortunately the intermediate vector is still necessary as all calls to emit would be underneath an immutable borrow of ctx, but this does clean things up a little bit.
<!--
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 (Mar 15 2024 at 19:00):

elliottt updated PR #8151.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 15 2024 at 19:03):

elliottt updated PR #8151.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 15 2024 at 19:15):

cfallin submitted PR review:

Seems reasonable to me!

view this post on Zulip Wasmtime GitHub notifications bot (Mar 15 2024 at 21:03):

elliottt merged PR #8151.


Last updated: Dec 23 2024 at 13:07 UTC