Repository activity
40458 results across all weeks
Compiler: link the base64 decoder in build-fs output
Since #2432, large binary strings are emitted as base64 literals decoded by caml_jsbytes_of_base64. This also applies to the files embedded by build-fs.
Romain Beauxis (@toots)Compiler: sink pure instructions into the branch that uses them
New IR pass (Branch_sinking), run just before JavaScript code generation.
hhugoCompiler: split switches above 256 cases, or spanning more than 1000
Large switches are split into a binary tree of smaller switches (build_switch). The limit of 60 cases dates from Crankshaft: up to V8 3.28, a function containing a switch with more than 128 cases was not optimized. This PR raises the default switch_size to 256, and also splits switches whose case values span more than 1000.
hhugoEnsure empty float arrays use tag 0 rather than 254
The following paths in wasm emit an empty float array with tag 254 rather than 0, leading to behaviour mismatches with native code:
Leo Lee (@smjleo)Improve variable naming (Js_assign)
@hhugo: I run some test locally. it looks ok
Jérôme Vouillon (@vouillon)Platform-portable Integer
A rebased version of the origin/portint branch.
Robin Ricard (@rricard)Prepare for Oxcaml 5.4
Jérôme Vouillon (@vouillon)Runtime: faster multi-byte reads and writes on bytes
caml_bytes_get{16,32,64}u read the Uint8Array directly when the bytes are in the array representation, instead of going through caml_bytes_unsafe_get for each byte (and allocating an 8-element array for 64-bit reads).
Jérôme Vouillon (@vouillon)Runtime: hash strings in a single pass
caml_hash checked whether a JavaScript string was an OCaml string with caml_is_ml_string, which scans it with a regular expression, before hashing it; caml_hash_mix_jsstring then scanned it a second time to check that its code units fit in a byte. This showed up at about 7% of a Hashtbl-with-string-keys profile in the default (use-js-string) mode.
hhugoRuntime: write the tag of Array.sub results with fill
Stacked on #2609.
hhugoWasm: make Binaryen optional
Binaryen's wasm-opt is now the only Binaryen tool wasm_of_ocaml uses (linking and dead code elimination moved to our linker in #2506, and Wax assembles the runtime since #2373). This makes it optional.
hhugojs_of_ocaml: only double-translate functions that may run below an effect handler
Jérôme Vouillon (@vouillon)No partial upgrades on Arch
Such a strange package manager...
David Allsopp (@dra27-js)-dflambda-heavy-invariants aborts on object method calls
Calling an object method with -dflambda-heavy-invariants aborts:
KC Sivaramakrishnan (@kayceesrk)Add `-frametable-sections`
Currently, the frametable is always one giant table per compilation
Luke Maurer (@lukemaurer)Add a machtype field to `Cmm.symbol`
Currently, the machtype is always typ_int, but a subsequent PR will change some instances to new machtypes.
James Rayman (@jra4)Add off-heap pointer and static block machtypes
This splits off some dubious use-cases of Int. See the diff in cmm.ml/mli for specifics. In short, 3 new machtypes are added:
James Rayman (@jra4)Checked 256-bit stores write the low half before raising
set256 with a partially out-of-bounds index raises and leaves the low 16 bytes written:
KC Sivaramakrishnan (@kayceesrk)Deduplicate shared types in the zero-alloc backend
Share structures that are currently defined identically in multiple places (e.g. { nor; exn; div }). This is also necessary for later reuse in [@zero_alloc conditional].
Will Sturgeon (@wrsturgeon)Detect ARM64 architecture extensions in the runtime
This threads the ARM arch extension configure options into the runtime + tries detecting them. Currently only doing this for LSE (in anticipation of #6539)
yusumez-js