Stream: git-wasmtime

Topic: wasmtime / Issue #2256 Benchmark clearing splat register;...


view this post on Zulip Wasmtime GitHub notifications bot (Oct 02 2020 at 15:41):

abrown opened Issue #2256:

As suggested by @bnjbvr in https://github.com/bytecodealliance/wasmtime/pull/2248#issuecomment-702627995, we should benchmark whether clearing a register with PXOR before emitting the sequence for splat will cause a slowdown on x64. Currently, #2248 adds a weird meta-instruction, XmmUninitializedValue, that tells the register allocator that the dst register is a def, not a mod, because the sequence of instructions emitted for splat will overwrite all lanes of dst. XmmUninitializedValue is dangerous, though, because we must be very careful to ensure the "overwrite all lanes" invariant holds--it would be preferable to remove it. One way to do so would be to initially emit a PXOR dst, dst, which the new backend recognizes as a def. I avoided this in #2248 because of increased code size, potential slowdown, and the fact that the old backend did not have it, but if we find that its emission causes no slowdown, we should add it and remove XmmUninitializedValue.

view this post on Zulip Wasmtime GitHub notifications bot (Oct 02 2020 at 15:42):

abrown labeled Issue #2256:

As suggested by @bnjbvr in https://github.com/bytecodealliance/wasmtime/pull/2248#issuecomment-702627995, we should benchmark whether clearing a register with PXOR before emitting the sequence for splat will cause a slowdown on x64. Currently, #2248 adds a weird meta-instruction, XmmUninitializedValue, that tells the register allocator that the dst register is a def, not a mod, because the sequence of instructions emitted for splat will overwrite all lanes of dst. XmmUninitializedValue is dangerous, though, because we must be very careful to ensure the "overwrite all lanes" invariant holds--it would be preferable to remove it. One way to do so would be to initially emit a PXOR dst, dst, which the new backend recognizes as a def. I avoided this in #2248 because of increased code size, potential slowdown, and the fact that the old backend did not have it, but if we find that its emission causes no slowdown, we should add it and remove XmmUninitializedValue.


Last updated: Oct 23 2024 at 20:03 UTC