Stream: git-wasmtime

Topic: wasmtime / PR #4107 Don't make a value label range smalle...


view this post on Zulip Wasmtime GitHub notifications bot (May 06 2022 at 10:20):

bnjbvr opened PR #4107 from fix-value-label-range to release-0.36.0:

I see this code has disappeared from main with the port to regalloc2,
but it seems there was a bug affecting 0.36.0 (and previous versions)
where the end of a range could end up being placed before the start of
that range, triggering an assertion in ValueLabelRangeBuilders::process_label (assert_lt!(range_start, range_end);). I think the only way this could happen was that, during construction of these value label ranges, we'd
"extend" a range with the new end of an instruction, but the end of that
instruction is located before the end of the range we're overwriting, so we'd end up incorrectly "compressing" a value range to the left! The fix is quite simple and consists in taking the maximum value of the new end offset and the previous end offset, I think.

Upstreaming in case it's of interest to get a tiny dot release (or have this patch ride along other security fixes) for this in
0.36.0, otherwise I can put it on an internal fork if preferred, as this
is a real-world issue affecting our users who are trying to use debugging.

view this post on Zulip Wasmtime GitHub notifications bot (May 09 2022 at 18:55):

bnjbvr closed without merge PR #4107.


Last updated: Oct 23 2024 at 20:03 UTC