You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Malloc supports loading external arraybuffers, that possibly was created & used on a device with different endianness.
For example: passing arraybuffer as binary data from server to client.
None Goal:
Fix the whole endianness issue for userspace values.
Possible things to do about it:
Nothing: almost everything is LE
Add a header flag, that is readable in an endianness-agnostic way to tell on which endianness the pool's arraybuffer was created on. so we can make sanity check and bail.
Add static function on the lib to sniff the endianness on a given arraybuffer, to use before passing to a new instance of pool
let malloc sniff it when providing existing arraybuffer and fail/transform the arraybuffer to the appropriate endianness.
The text was updated successfully, but these errors were encountered:
@Bnaya haven't done anything specific on this yet, but just wanted to record a mental note here that the thi.ng/binary package now includes a IS_LE constant which will be true if the runtime env is little endian...
following discussion on discord,
https://discordapp.com/channels/445761008837984256/445761258696736790/657739072470646794
TypedArray endianness is platform specific
Malloc supports loading external arraybuffers, that possibly was created & used on a device with different endianness.
For example: passing arraybuffer as binary data from server to client.
None Goal:
Fix the whole endianness issue for userspace values.
Possible things to do about it:
Nothing: almost everything is LE
Add a header flag, that is readable in an endianness-agnostic way to tell on which endianness the pool's arraybuffer was created on. so we can make sanity check and bail.
Add static function on the lib to sniff the endianness on a given arraybuffer, to use before passing to a new instance of pool
let malloc sniff it when providing existing arraybuffer and fail/transform the arraybuffer to the appropriate endianness.
The text was updated successfully, but these errors were encountered: