Robbepop opened issue #10486:
When Wasmtime's CLI returns a
v128
value, it is formatted asu128
value.
In Wasmi I have had a lot of thoughts about the formatting ofv128
values and came to the conclusion that it is probably best to format it as hex-dec number with leading zeros. For example:0x616E5F6E61635F6E61635F6E61635F6E
Was there a specific reason Wasmtime chose to format
v128
as a simpleu128
?Ideally Wasmi has the same formatting as Wasmtime (or more generally: Wasm runtimes share the same formatting), but at this point I find the
u128
formatting to be very weird and thus I suppose I am missing something here.
abrown commented on issue #10486:
Yeah, I also prefer the hex format; that's what I think of when I'm thinking about lanes. Not sure why we used the u128 formatting. Convenience perhaps?
Robbepop edited issue #10486:
When Wasmtime's CLI returns a
v128
value, it is formatted asu128
value.
In Wasmi I have made some thoughts about the formatting ofv128
values and came to the conclusion that it is probably best to format it as hex-dec number with leading zeros. For example:0x616E5F6E61635F6E61635F6E61635F6E
Was there a specific reason Wasmtime chose to format
v128
as a simpleu128
?Ideally Wasmi has the same formatting as Wasmtime (or more generally: Wasm runtimes share the same formatting), but at this point I find the
u128
formatting to be very weird and thus I suppose I am missing something here.
Robbepop edited issue #10486:
When Wasmtime's CLI returns a
v128
value, it is formatted asu128
value.
In Wasmi I have made some thoughts about the formatting ofv128
values and came to the conclusion that it is probably best to format it as hex-dec number with leading zeros. For example:0x006E006E61635F6E61635F6E61635F6E
Was there a specific reason Wasmtime chose to format
v128
as a simpleu128
?Ideally Wasmi has the same formatting as Wasmtime (or more generally: Wasm runtimes share the same formatting), but at this point I find the
u128
formatting to be very weird and thus I suppose I am missing something here.
alexcrichton commented on issue #10486:
Yeah I think the reason for the current formatting is that prior to
v128
everything printed as a number, so "why not also print as a number". I think it'd be reasonable to change as we don't guarantee the formatting at this time.
Last updated: Apr 18 2025 at 16:03 UTC