Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
326 commits
Select commit Hold shift + click to select a range
a3e7a88
AOT: `bun run --aot`, typed validation and JSON parsing, backend benc…
Jarred-Sumner Oct 16, 2026
eaeb888
AOT: plain names, typed results of Bun.parse, a faster front end, fix…
Jarred-Sumner Oct 17, 2026
9219755
AOT: every platform, a tsconfig per file, faster instanceof and JSON,…
Jarred-Sumner Oct 17, 2026
903e97d
Merge branch 'main' into claude/compile-aot-on-check
Jarred-Sumner Oct 17, 2026
5e6409a
AOT: fixes since the merge, and the matching WebKit preview
Jarred-Sumner Oct 17, 2026
2767997
Open the folder `bun run` looks for node_modules/.bin in; allow WTF's…
Jarred-Sumner Oct 17, 2026
2de86b0
Merge branch 'main' into claude/compile-aot-on-check
Jarred-Sumner Oct 17, 2026
41bf314
AOT: fixes from CI and from real test suites
Jarred-Sumner Oct 17, 2026
b1d474d
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2026
3417a0b
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 17, 2026
a1ca90b
AOT: JSON.parse by type, generic records in unions, fixes from CI
Jarred-Sumner Oct 17, 2026
7ac3aec
ci: test/aot runs in steps of its own
Jarred-Sumner Oct 17, 2026
e4c2bd7
Merge the formatter's commits
Jarred-Sumner Oct 17, 2026
e716827
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2026
063c6d5
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 17, 2026
d89c339
AOT: typed node:http without optional fields, fixes for tests of main
Jarred-Sumner Oct 17, 2026
2ddb799
ci: the pipeline step asks git for what its sparse checkout lacks
Jarred-Sumner Oct 17, 2026
751f1a1
ci: the pipeline survives any table of durations
Jarred-Sumner Oct 17, 2026
b2a496c
Merge the formatter's commits
Jarred-Sumner Oct 17, 2026
2ccde3b
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2026
d1b95fb
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 17, 2026
1ce5e15
AOT: --aot-explain, int32 proved at build time, fixes for tests of main
Jarred-Sumner Oct 17, 2026
0b676b5
Merge the formatter's commits
Jarred-Sumner Oct 17, 2026
a288cb7
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2026
5119b92
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 17, 2026
81298d1
AOT: request bodies parsed from UTF-8, cheaper Response clones, clear…
Jarred-Sumner Oct 17, 2026
22e130b
AOT tests: renew the recorded typedness of the test programs
Jarred-Sumner Oct 17, 2026
26189df
Merge the formatter's commits
Jarred-Sumner Oct 17, 2026
d83c5c6
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2026
4ba5f72
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 17, 2026
dcf299a
AOT tests: parsed data that fits and that does not fit reaches typed …
Jarred-Sumner Oct 17, 2026
bb50223
Merge the formatter's commits
Jarred-Sumner Oct 17, 2026
b78cc18
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2026
9b13751
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 17, 2026
dd14690
AOT: fewer wrong refusals, an option to trim the runtime, steadier ty…
Jarred-Sumner Oct 17, 2026
e2d2f7a
AOT tests: a test program declares the module kinds it imports
Jarred-Sumner Oct 17, 2026
8d4d0de
Merge the formatter's commits
Jarred-Sumner Oct 17, 2026
8412a14
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2026
8ad526c
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 17, 2026
5d65fed
AOT: typed literals stay typed at predicted calls, module graph globa…
Jarred-Sumner Oct 17, 2026
0d8f9d3
AOT: URLSearchParams made from what is no string is made as before
Jarred-Sumner Oct 17, 2026
8d2ce9c
AOT: follow the engine, recorded counts renewed
Jarred-Sumner Oct 17, 2026
3e00553
AOT tests: four recorded counts of a Map lookup follow the engine
Jarred-Sumner Oct 17, 2026
8adc2c6
AOT tests: three recorded counts of module-level loops follow the engine
Jarred-Sumner Oct 17, 2026
1c18e54
Merge the formatter's commits
Jarred-Sumner Oct 17, 2026
5a4df18
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2026
22b876b
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 17, 2026
fb834ab
AOT: CI links with the layout that trimming needs, Windows fixes, ass…
Jarred-Sumner Oct 17, 2026
0ba3597
AOT: a container filled from its own elements no longer hangs the build
Jarred-Sumner Oct 17, 2026
f8316ee
Merge the formatter's commits
Jarred-Sumner Oct 17, 2026
2eee707
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2026
2cc3b5d
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 17, 2026
e1be155
AOT: trimming by use, one link for its layout, constant Sets and Maps…
Jarred-Sumner Oct 17, 2026
0c7cf37
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2026
43c2fcf
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 17, 2026
a669007
AOT: the link's graph resolves names as the linker did, 23 more featu…
Jarred-Sumner Oct 17, 2026
79bb122
AOT: follows the engine, a door needs only its own machine's stub
Jarred-Sumner Oct 17, 2026
f2e8343
node:repl: take globalThis from the global scope
Jarred-Sumner Oct 17, 2026
7f83370
Merge the formatter's commits
Jarred-Sumner Oct 17, 2026
31b79bf
AOT: a second check of the trimming layout, ICU's data goes by use
Jarred-Sumner Oct 17, 2026
edf5c51
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2026
54c5048
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 17, 2026
091af75
AOT: Windows links with the trimming layout, 97 features go by use, t…
Jarred-Sumner Oct 17, 2026
c248377
build: linking a built-in function from its text is not a door
Jarred-Sumner Oct 17, 2026
5b22a41
Merge the formatter's commits
Jarred-Sumner Oct 17, 2026
6f9bc56
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 17, 2026
d179c14
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 17, 2026
11982c6
build: Windows lanes link without the trimming layout again
Jarred-Sumner Oct 17, 2026
a4d36e5
Merge the formatter's commits
Jarred-Sumner Oct 17, 2026
be761cb
AOT: copies of class instances, trimmed executables audited against w…
Jarred-Sumner Oct 17, 2026
b587cf6
test: records that follow the copies of class instances
Jarred-Sumner Oct 17, 2026
29ee963
AOT: take out start-up changes that are not part of ahead-of-time com…
Jarred-Sumner Oct 17, 2026
4eae4c3
AOT: a property read by a joined key no longer crashes the front end
Jarred-Sumner Oct 18, 2026
445cf78
AOT: trimmed executables keep less, warnings without process.stderr, …
Jarred-Sumner Oct 18, 2026
1edf2a1
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 18, 2026
2073ef8
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 18, 2026
1c9b3d4
build: Windows lanes link without the trimming layout for one run
Jarred-Sumner Oct 18, 2026
071866d
Merge the formatter's commits
Jarred-Sumner Oct 18, 2026
b4e12fd
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 18, 2026
e9bcb0e
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] Oct 18, 2026
c87d3f8
AOT: a failed build waits for its analysis thread, --disallow-code-ge…
Jarred-Sumner Oct 18, 2026
eba10c6
ci: up to eight shards for the AOT tests on macOS
Jarred-Sumner Oct 18, 2026
3320123
test: AOT expectations follow the checks behind tail calls and the sp…
Jarred-Sumner Oct 18, 2026
addbf7a
Merge the formatter's commits
Jarred-Sumner Oct 18, 2026
70fe2b7
bun compile, bun compile --library, AOT documentation, smaller trimme…
Jarred-Sumner Oct 18, 2026
7d1a454
Validation by type in every mode, compile.trim, features of the runti…
Jarred-Sumner Oct 18, 2026
10affe0
bun compile prints how much of the program is typed, --explain says h…
Jarred-Sumner Oct 18, 2026
2217cac
Trimming keeps eval by default and works in release builds; validatio…
Jarred-Sumner Oct 18, 2026
3a05b36
Ahead-of-time compiler: three days of work on the rewritten front end…
Jarred-Sumner Oct 22, 2026
7c97f44
Merge branch 'main' into claude/compile-aot-on-check
Jarred-Sumner Oct 22, 2026
916a57d
Ahead-of-time compiler: an hour of fixes, tests and docs
Jarred-Sumner Oct 22, 2026
e9a9cd6
Merge commit '7c97f445676cca51e720a2148759d20c29de91c4' into claude/c…
Jarred-Sumner Oct 22, 2026
452adcf
Ahead-of-time compiler: fixes, tests, shorter comments
Jarred-Sumner Oct 22, 2026
b317136
Ahead-of-time compiler: lines inside string literals restored, a preb…
Jarred-Sumner Oct 22, 2026
81e05fb
Ahead-of-time compiler: the tree formatted, bun-types, clippy, finali…
Jarred-Sumner Oct 23, 2026
b773ece
Ahead-of-time compiler: fixes and tests [skip tests]
Jarred-Sumner Oct 23, 2026
62a217c
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 23, 2026
8aad5db
Run CI again: the preview release of the engine is published
Jarred-Sumner Oct 23, 2026
1203d72
Ahead-of-time compiler: a build in CI no longer asks for the list of …
Jarred-Sumner Oct 23, 2026
0a1efdf
Ahead-of-time compiler: links with LTO on the merged tree, fixes, tes…
Jarred-Sumner Oct 23, 2026
5ec0668
Ahead-of-time compiler: results of natives are predictions, one-file …
Jarred-Sumner Oct 23, 2026
88e4b33
Ahead-of-time compiler: Bun compiles the table of built-ins itself, f…
Jarred-Sumner Oct 23, 2026
4b75b40
Merge branch 'main' into claude/compile-aot-on-check
Jarred-Sumner Oct 23, 2026
385c91a
Ahead-of-time compiler: a module parsed anew while binding is kept, f…
Jarred-Sumner Oct 23, 2026
4198786
Ahead-of-time compiler: the trimmable link on macOS, an empty list is…
Jarred-Sumner Oct 23, 2026
b820ab6
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 23, 2026
dac2a0c
Ahead-of-time compiler: the table of built-ins names fewer engine ent…
Jarred-Sumner Oct 23, 2026
32f8fef
Merge the formatters' commit
Jarred-Sumner Oct 23, 2026
327e5f2
Ahead-of-time compiler: one read-only segment in a trimmed Mach-O, th…
Jarred-Sumner Oct 23, 2026
1807f67
Ahead-of-time compiler: the table of built-ins is generated by the en…
Jarred-Sumner Oct 23, 2026
45fdd92
Ahead-of-time compiler: fixes, tests
Jarred-Sumner Oct 23, 2026
0696d7a
Ahead-of-time compiler: generated test programs leave the repository,…
Jarred-Sumner Oct 23, 2026
1deb3bd
Ahead-of-time compiler: code generators find the engine's files besid…
Jarred-Sumner Oct 23, 2026
b5f7b07
Ahead-of-time compiler: the manifest of built-in sources finds the en…
Jarred-Sumner Oct 23, 2026
fdb4fee
Ahead-of-time compiler: less code; test shards as one table, engine t…
Jarred-Sumner Oct 23, 2026
b904b92
AOT: smaller tests from templates and tables; undname from LLVM; fron…
Jarred-Sumner Oct 23, 2026
f57d62f
Merge branch 'main' into claude/compile-aot-on-check
Jarred-Sumner Oct 23, 2026
11c5159
AOT: merge main; trim and test fixes for aarch64, macOS and asan
Jarred-Sumner Oct 23, 2026
7215b5e
Follow the engine: 32-bit BigInt values are gone upstream; test fixes
Jarred-Sumner Oct 23, 2026
f23ec89
AOT: commit test fixtures that .gitignore hid; test fixes
Jarred-Sumner Oct 23, 2026
8211b55
AOT: unit tests back; trim keeps getBuiltinModule where text can run;…
Jarred-Sumner Oct 23, 2026
be4b61b
AOT: on arm64 a run takes every group of directly generated code; mac…
Jarred-Sumner Oct 23, 2026
0019936
AOT: tests of --trim and --aot outside test/aot ride in the aot steps…
Jarred-Sumner Oct 23, 2026
689c233
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 23, 2026
89cffa2
AOT: fixes from CI on Windows, macOS and Alpine; more tests; crash re…
Jarred-Sumner Oct 23, 2026
2c2a23c
AOT: Windows x64 runs every file of test/aot for now [skip size check]
Jarred-Sumner Oct 23, 2026
a3f9056
AOT: twelve tests name executables, line ends and paths as Windows do…
Jarred-Sumner Oct 23, 2026
977c2a1
AOT: fixes from fuzzing and CI; failed calls are reported in the word…
Jarred-Sumner Oct 23, 2026
da8d5a4
AOT: a build option that leaves the compiler out; fixes from fuzzing …
Jarred-Sumner Oct 23, 2026
0bfb671
AOT: two flavours in CI; fixes from CI on Windows; lints; more tests …
Jarred-Sumner Oct 23, 2026
41ef574
AOT: bun hands --aot over to bun-aot; two flavours in CI; module path…
Jarred-Sumner Oct 23, 2026
c013213
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 23, 2026
c16ba4c
AOT: fixes from CI on every platform; tests of work that data causes;…
Jarred-Sumner Oct 23, 2026
afc07ea
Merge the formatters' commit
Jarred-Sumner Oct 23, 2026
ab0d131
AOT: at most 4,096 property orders per object type; the baseline chec…
Jarred-Sumner Oct 23, 2026
4f7d184
AOT: tests of addresses made of 32-bit values, of builders begun late…
Jarred-Sumner Oct 23, 2026
aa4056c
AOT: more tests [skip size check]
Jarred-Sumner Oct 23, 2026
292c369
AOT: Windows module paths, tests that wait for the next engine, more …
Jarred-Sumner Oct 23, 2026
43d39c5
AOT: Bun.FFI.CString holds anything; tests for Windows, macOS and ASA…
Jarred-Sumner Oct 23, 2026
8bb8d41
AOT: CI runs bun with the real bun-aot beside it; tests for arm64, Wi…
Jarred-Sumner Oct 23, 2026
0349723
AOT: tests for the ASAN, arm64 and macOS lanes; the test of the real …
Jarred-Sumner Oct 23, 2026
1d74158
AOT: fixes and tests since the last push; a hardened build in CI; the…
Jarred-Sumner Oct 23, 2026
27d4488
AOT: a trimmed ELF executable keeps four program headers for its payl…
Jarred-Sumner Oct 23, 2026
0786e3c
AOT: an entry point that is not text is carried as a file; a hardened…
Jarred-Sumner Oct 23, 2026
98d1caf
AOT: an executable that cannot read its own file does not start under…
Jarred-Sumner Oct 23, 2026
250744f
AOT: under --minify-identifiers the names of bindings are shown short…
Jarred-Sumner Oct 23, 2026
7fd9048
Merge branch 'main' into claude/compile-aot-on-check
Jarred-Sumner Oct 23, 2026
cfc8287
AOT: one binary a platform, `bun compile --library`, fixes behind the…
Jarred-Sumner Oct 23, 2026
8ad602f
AOT: `--trim` sees what a generated binding reaches, so Shell's minim…
Jarred-Sumner Oct 24, 2026
bce5ea8
AOT: on Windows `bun run --aot` hands its own name and its open descr…
Jarred-Sumner Oct 24, 2026
e2b9326
AOT: `bun compile --library` and `bun build --dts` write a package's …
Jarred-Sumner Oct 24, 2026
cf19c2e
AOT: a package's typed files are checked as a project of their own, u…
Jarred-Sumner Oct 24, 2026
4786496
AOT: a web Worker that `terminate()` reaches before its entry has end…
Jarred-Sumner Oct 24, 2026
4e74401
AOT: cells are not placed in the frame, so a closure that a loop make…
Jarred-Sumner Oct 24, 2026
11d2b38
AOT: the file of a package that keeps its types is called full types:…
Jarred-Sumner Oct 24, 2026
90807a1
Merge branch 'main' into claude/compile-aot-on-check [skip size check]
Jarred-Sumner Oct 24, 2026
4cb5a19
AOT: classes as compilers for ES5 write them get their layout and the…
Jarred-Sumner Oct 24, 2026
8720222
AOT: inner objects are no longer laid into the objects that hold them…
Jarred-Sumner Oct 24, 2026
0b6d053
The stream controller finalizes the HTML rewriter's sink without a re…
Jarred-Sumner Oct 24, 2026
c6a27b5
The differential test of built-ins lists the sink controller's and th…
Jarred-Sumner Oct 24, 2026
698f9e6
AOT: a name that an ES module imports from a CommonJS file may be rea…
Jarred-Sumner Oct 24, 2026
d1ee9de
AOT: each entry point of a build begins a program of its own; a loade…
Jarred-Sumner Oct 24, 2026
9e60cec
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 24, 2026
a44d0a3
compile --aot: a run-time plugin is never offered a module of the pro…
Jarred-Sumner Oct 24, 2026
74a5b0e
Messages between processes are decoded as before; stored answers foll…
Jarred-Sumner Oct 24, 2026
74149e6
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 24, 2026
d1e8dff
AOT: one program where entry points can meet, keys made of constants …
Jarred-Sumner Oct 24, 2026
193dfa9
docs: two rows of the table of libraries are padded as the formatter …
Jarred-Sumner Oct 24, 2026
e9574f2
AOT: a file is paired with an entry point only where the executable h…
Jarred-Sumner Oct 24, 2026
04fa655
The checks of what the back end is told are listed as todo on Linux A…
Jarred-Sumner Oct 24, 2026
4515317
AOT: very long chains are answered at once, an import of a type besid…
Jarred-Sumner Oct 24, 2026
2ea627f
The test of the maps of every image shows what the program wrote to s…
Jarred-Sumner Oct 24, 2026
49db137
The generated module graphs are compared with a `bun run` that transp…
Jarred-Sumner Oct 24, 2026
efbd32b
buffer-oom.test.ts: two rows whose string JavaScriptCore allocates le…
Jarred-Sumner Oct 24, 2026
af72a51
AOT: an executable loads code from disk, the entry points of a build …
Jarred-Sumner Oct 24, 2026
61b67fa
The test of the maps of every image is two tests [skip size check]
Jarred-Sumner Oct 24, 2026
9bc56cb
Tests follow an executable that loads code from disk, and a count of …
Jarred-Sumner Oct 24, 2026
835edb2
A test file that needs no compiler is listed as one, and two counts a…
Jarred-Sumner Oct 24, 2026
c0820a3
AOT: a Worker's file that is embedded is compiled, a `require` that i…
Jarred-Sumner Oct 24, 2026
1db9bb2
Tests: paths, error numbers and folders on Windows, the map for perf …
Jarred-Sumner Oct 24, 2026
4a775f2
AOT: a build finds Bun's types where they are installed, and what Bun…
Jarred-Sumner Oct 24, 2026
abee066
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 24, 2026
c8705f1
AOT: loading code from disk is an option, a file that is queued again…
Jarred-Sumner Oct 24, 2026
26d4864
AOT: a build knows Bun's and Node.js's APIs without installed type de…
Jarred-Sumner Oct 24, 2026
0c04d7e
AOT: a name in `types` that is not installed is a warning where Bun's…
Jarred-Sumner Oct 24, 2026
fae3c2d
AOT: an embedded file pairs with its entry point whichever separator …
Jarred-Sumner Oct 24, 2026
8146e4c
AOT tests: the time one thread spends allocating tagged layouts in a …
Jarred-Sumner Oct 24, 2026
831fcd3
AOT: what a thread does with the files to load is an enum, tidier Rus…
Jarred-Sumner Oct 24, 2026
97f7cde
AOT: tests of names stored by key across collections, of the heap lim…
Jarred-Sumner Oct 24, 2026
947fb6a
AOT: the trimming tests wait for a server that no longer answers [ski…
Jarred-Sumner Oct 24, 2026
1ac9634
AOT: `JSON` from "bun" is an object of its own, validation errors rea…
Jarred-Sumner Oct 24, 2026
9c1d1f5
AOT: `Bun.JSON` has its own entry in the table of built-ins, a type a…
Jarred-Sumner Oct 24, 2026
4e280c3
AOT: a rule of `Schema` that is not as written is an error, one build…
Jarred-Sumner Oct 24, 2026
2057c94
AOT: a list that one arm of a union refuses comes back whole [skip si…
Jarred-Sumner Oct 24, 2026
8614cd7
AOT: `JSON.parse<T>` from "bun" and `validate<T>` validate without `-…
Jarred-Sumner Oct 24, 2026
c65c8c4
AOT: a test of the ways to write a call of `JSON.parse` with a type a…
Jarred-Sumner Oct 24, 2026
7717d2c
AOT: symbol keys under `validate<T>`, what a worker wrote before it e…
Jarred-Sumner Oct 25, 2026
4a3071d
AOT: tests and docs import `JSON` from "bun" [skip size check]
Jarred-Sumner Oct 25, 2026
7feecc8
AOT: the global `JSON.parse` takes no type argument, executables leav…
Jarred-Sumner Oct 25, 2026
f51a0eb
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 25, 2026
0bb3368
AOT: external source maps, `Bun.Validator`, one allocator on macOS, a…
Jarred-Sumner Oct 25, 2026
cfefe11
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 25, 2026
e436476
AOT: packages name their typed source under an "aot" condition, valid…
Jarred-Sumner Oct 25, 2026
99f2f7d
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 25, 2026
5b59847
AOT: the compiler asks Bun's resolver, `bind` in a constructor calls …
Jarred-Sumner Oct 25, 2026
cff9c64
AOT: each test program is also built as it is alone, built-ins are ca…
Jarred-Sumner Oct 25, 2026
109855d
AOT: a module runs under the path that the resolver of Bun gives it, …
Jarred-Sumner Oct 25, 2026
97d9cd0
AOT: tests for null reads in Workers and for require() of modules wit…
Jarred-Sumner Oct 25, 2026
e52f869
AOT: a static field named like a static method is listed, plugin requ…
Jarred-Sumner Oct 25, 2026
58b3677
AOT: `--aot-threads=<n>` starts at most n threads, imported CommonJS …
Jarred-Sumner Oct 25, 2026
9b6e9fa
AOT: the drawn step of CI takes the same sample until `aotSample` cha…
Jarred-Sumner Oct 25, 2026
d9e64c7
CI: `scripts/runner.node.ts` and `.buildkite/ci.ts` are executable ag…
Jarred-Sumner Oct 25, 2026
2961c80
WebKit: the release built from main [skip size check]
Jarred-Sumner Oct 25, 2026
418ca40
AOT: what makes a file CommonJS, the plan of linked files, and tests …
Jarred-Sumner Oct 25, 2026
740e6d9
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 25, 2026
3d1a409
WebKit: the release built from main [skip size check]
Jarred-Sumner Oct 25, 2026
6d5c555
AOT: the order of imported CommonJS files in a test of the plan [skip…
Jarred-Sumner Oct 25, 2026
b37b82b
AOT: every test runs in some step of CI, docs/compiler, int32 members…
Jarred-Sumner Oct 25, 2026
7ac759f
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 25, 2026
80bac9d
AOT: what mordant reports, feature names of --trim as a union, many n…
Jarred-Sumner Oct 26, 2026
741078b
AOT: members the host creates at their first read, closures made in a…
Jarred-Sumner Oct 26, 2026
7b44b41
AOT: int32 fields behind any receiver, names of host functions, tail …
Jarred-Sumner Oct 26, 2026
0eb1a7b
AOT: private names of node:http's own state, where stack frames point…
Jarred-Sumner Oct 26, 2026
d79f6b8
AOT: where an access is written, names that reach a CommonJS file thr…
Jarred-Sumner Oct 26, 2026
b3fd4ef
AOT: modules take the loader on demand, folders under computed names,…
Jarred-Sumner Oct 26, 2026
0d74618
AOT: modules are started by compiled code again, stores entered in a …
Jarred-Sumner Oct 26, 2026
84ec8e7
AOT: tests for suspended functions, cached removals, names in stack f…
Jarred-Sumner Oct 26, 2026
73542cf
AOT: parameters held at suspensions, one check of the address space a…
Jarred-Sumner Oct 26, 2026
a640bf2
AOT: modules run in the order of the language, and the IR names prove…
Jarred-Sumner Oct 26, 2026
a381870
AOT: early errors, paths, names and node:http objects as `bun run` ha…
Jarred-Sumner Oct 26, 2026
0dc696c
AOT: node:http reads what a program replaced, process.nextTick is nat…
Jarred-Sumner Oct 26, 2026
49f9f41
AOT: stack positions of ordinary code, node:http through heirs and pr…
Jarred-Sumner Oct 26, 2026
deed77e
AOT: barrels on import cycles keep their place, defines end in a dot,…
Jarred-Sumner Oct 26, 2026
776d39e
AOT: `await` in computed names at the top of a module, long runs of c…
Jarred-Sumner Oct 26, 2026
82632d8
AOT: a generator of programs in several files checks stack frames, ge…
Jarred-Sumner Oct 26, 2026
a829128
AOT: `export default` of a name that is only a type exports nothing, …
Jarred-Sumner Oct 26, 2026
f73405e
[autofix.ci] apply automated fixes
autofix-ci[bot] Oct 26, 2026
dc5a162
AOT: a namespace makes an object only where `bun run` keeps a stateme…
Jarred-Sumner Oct 26, 2026
0572609
AOT: a file that starts with `// @bun` is the kind of module its firs…
Jarred-Sumner Oct 26, 2026
bee16ec
AOT: `bun:main` and data: URLs imported as data are modules of the im…
Jarred-Sumner Oct 26, 2026
e495745
AOT: a constant key in brackets is parsed as the member name, the pos…
Jarred-Sumner Oct 26, 2026
ad0f610
AOT: strictNullChecks of a file is that of the nearest tsconfig.json,…
Jarred-Sumner Oct 26, 2026
1595de7
AOT: what is no program under `bun run` is refused in files that are …
Jarred-Sumner Oct 27, 2026
5b7501f
Merge branch 'main' into claude/compile-aot-on-check
Jarred-Sumner Oct 27, 2026
aa1c7b9
Merge branch 'main' into claude/compile-aot-on-check
Jarred-Sumner Oct 27, 2026
d0b27e9
AOT: a constant that another file exports decides what is loaded, Bun…
Jarred-Sumner Oct 27, 2026
c84f672
fix(aot): reconstruct retained fork fixes on current upstream
steipete Oct 27, 2026
ca1e894
fix(aot): admit embedded entry resolution through provider gate
steipete Oct 27, 2026
4f43848
test(aot): keep external plugin probe output independent of flags
steipete Oct 27, 2026
ebcdfd5
fix(node): make child process stdio assignable before spawn
steipete Oct 27, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
227 changes: 214 additions & 13 deletions .buildkite/ci.ts

Large diffs are not rendered by default.

14 changes: 14 additions & 0 deletions .buildkite/hooks/post-checkout
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/usr/bin/env bash
# `git fetch` may leave `git gc --auto` packing the repository in the background
# ("Auto packing the repository in background for optimum performance"). The
# darwin agents copy the checkout, .git included, into a guest next, and rsync
# exits 23 when .git/gc.pid or .git/gc.log.lock goes away under the copy: the
# job ends with status 1 before a test has run, and nothing retries it. So the
# packing is waited for here, five minutes at most. Never exits non-zero.

git_directory="${BUILDKITE_BUILD_CHECKOUT_PATH:-.}/.git"
for _ in $(seq 1 300); do
[ -e "$git_directory/gc.pid" ] || [ -e "$git_directory/gc.log.lock" ] || break
sleep 1
done
exit 0
2 changes: 1 addition & 1 deletion .buildkite/update-test-durations.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ steps:
# The scripts read BUILDKITE_API_TOKEN. The agent that runs this step has to
# provide it: `pipeline upload` refuses a pipeline with a secret interpolated in.
command: |
node scripts/update-test-durations.mjs --builds 5
bun scripts/update-test-durations.mjs --builds 5
node scripts/update-parallel-allowlist.mjs --builds 300
buildkite-agent artifact upload test/expected-durations.json
buildkite-agent artifact upload test/parallel-allowlist.json
4 changes: 2 additions & 2 deletions .claude/commands/upgrade-webkit.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ To do that:
- Preview mode: create a working branch (e.g. `bun/upgrade-to-<upstream-short-sha>`) instead of staying on main
- git merge upstream/main
- Fix the merge conflicts (preserve the fork's Bun-specific changes)
- bun run jsc:build:debug — from the bun repo root, builds just JSC
- bun run jsc:build:debug — from the bun repo root, builds just JSC (and its `jsc` shell), in bun's own build graph. File lists come from the checkout, but `scripts/build/deps/webkit.ts` restates WebKit's generator commands, compiler flags and option values by hand, and nothing checks them. Read `git diff $OLD_BASE upstream/main -- Source/cmake Source/JavaScriptCore/CMakeLists.txt Source/WTF/wtf/CMakeLists.txt Source/bmalloc/CMakeLists.txt` for changed `add_custom_command`s (→ `gen()`), compiler flags (→ `webkitFlags()`) and `WEBKIT_OPTION_*` / `SET_AND_EXPOSE_TO_BUILD` (→ `rows`), and carry them over in the bun PR
- While it compiles, in another task review the JSC commits between $OLD_BASE and upstream/main (Source/JavaScriptCore, Source/WTF, Source/bmalloc). Write up a summary in a file called "webkit-changes.md"
- bun run build:local — full Bun build against the local WebKit (reuses the JSC build above)
- bun run build:local — full Bun build with the local WebKit (same build directory and objects as the JSC build above)
- After it compiles, run some code to make sure things work: `bun run build:local -p '42'`
- Publish the new WebKit:
- Direct: cd vendor/WebKit, commit, `git push origin main`. The push triggers a release tagged `autobuild-<full-sha>`.
Expand Down
11 changes: 9 additions & 2 deletions .github/actions/rust-lint-setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,12 @@ inputs:
ninja-targets:
description: "Space-separated build targets (`bun scripts/build.ts --target=…`)."
default: "clone-lolhtml clone-rust-argon2"
webkit-generators-only:
description: >
"1" fetches the code generators of the prebuilt WebKit (half a megabyte)
in place of its tarball (440 MB). For a job whose targets compile and
link no C++: `codegen` reads nothing else of it.
default: "0"

runs:
using: composite
Expand All @@ -34,15 +40,15 @@ runs:

- name: Setup system deps
# cmake/ninja for `--configure-only`; clang for toolchain detection
# (configure resolves cfg.cc/cxx even though nothing here compiles C++).
# (configure resolves cfg.cc/cxx). `engine-test-programs` links with AddressSanitizer.
shell: bash
env:
LLVM_VERSION_MAJOR: ${{ inputs.llvm-version }}
run: |
wget -qO- https://apt.llvm.org/llvm-snapshot.gpg.key | sudo tee /etc/apt/trusted.gpg.d/apt.llvm.org.asc > /dev/null
echo "deb http://apt.llvm.org/$(lsb_release -cs)/ llvm-toolchain-$(lsb_release -cs)-${LLVM_VERSION_MAJOR} main" | sudo tee /etc/apt/sources.list.d/llvm.list > /dev/null
sudo apt-get update -qq
sudo apt-get install -y -qq --no-install-recommends cmake ninja-build nasm clang-${LLVM_VERSION_MAJOR} lld-${LLVM_VERSION_MAJOR} llvm-${LLVM_VERSION_MAJOR}
sudo apt-get install -y -qq --no-install-recommends cmake ninja-build nasm clang-${LLVM_VERSION_MAJOR} lld-${LLVM_VERSION_MAJOR} llvm-${LLVM_VERSION_MAJOR} libclang-rt-${LLVM_VERSION_MAJOR}-dev
- name: Setup Rust
if: inputs.toolchain != ''
Expand Down Expand Up @@ -72,6 +78,7 @@ runs:
shell: bash
env:
NINJA_TARGETS: ${{ inputs.ninja-targets }}
BUN_WEBKIT_GENERATORS_ONLY: ${{ inputs.webkit-generators-only }}
run: |
bun install --frozen-lockfile
bun scripts/build.ts $(printf -- '--target=%s ' $NINJA_TARGETS)
18 changes: 10 additions & 8 deletions .github/workflows/CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,18 +116,20 @@ export LLVM_VERSION_MAJOR=23

## rust-lints.yml Workflow

Four independent jobs over the Rust workspace. They share `.github/actions/rust-lint-setup`, a composite action that installs LLVM from apt.llvm.org (configure resolves a clang even though nothing here compiles C++), Bun, optionally a pinned Rust toolchain plus components, runs `bun install`, then `bun scripts/build.ts --configure-only` and the ninja targets a job asks for: `clone-lolhtml clone-rust-argon2` (cargo cannot resolve the workspace until the vendored `lol_html` and `rust-argon2` path dependencies exist) and, for jobs that check `bun_runtime`/`bun_jsc`/`bun_core`, `codegen` (their `include!()`d sources under `build/debug/codegen`).
Five independent jobs over the Rust workspace. They share `.github/actions/rust-lint-setup`, a composite action that installs LLVM from apt.llvm.org (configure resolves a clang even though nothing here compiles C++), Bun, optionally a pinned Rust toolchain plus components, runs `bun install`, then `bun scripts/build.ts --configure-only` and the ninja targets a job asks for: `clone-lolhtml clone-rust-argon2` (cargo cannot resolve the workspace until the vendored `lol_html` and `rust-argon2` path dependencies exist) and, for jobs that check `bun_runtime`/`bun_jsc`/`bun_core`, `codegen` (their `include!()`d sources under `build/debug/codegen`). `codegen` reads the code generators of the prebuilt WebKit and nothing else of it: a job that links no C++ passes `webkit-generators-only: "1"`, and the build fetches the release's `bun-webkit-aot-sources.tar.gz` (half a megabyte) in place of the tarball (440 MB).

| Job | Check name | Runs | Blocking |
| --------- | --------------------- | ------------------------------------------------------------------- | ------------------------------ |
| `clippy` | `cargo clippy` | `bun run rust:clippy`, then `cargo check --workspace --all-targets` | yes |
| `miri` | `cargo miri test` | `bun run rust:miri` (`scripts/rust-miri.ts`) | yes |
| `lolhtml` | `lol-html cargo test` | `cargo test` in `vendor/lolhtml` | yes |
| `mordant` | `mordant` | `bun run rust:mordant` | advisory (`continue-on-error`) |
| Job | Check name | Runs | Blocking |
| ---------------- | --------------------- | --------------------------------------------------------------------------------------------------------------- | ------------------------------ |
| `clippy` | `cargo clippy` | `bun run rust:clippy`, then `cargo check --workspace --all-targets` | yes |
| `miri` | `cargo miri test` | `bun run rust:miri` (`scripts/rust-miri.ts`) | yes |
| `lolhtml` | `lol-html cargo test` | `cargo test` in `vendor/lolhtml` | yes |
| `aot-rust-tests` | `AoT cargo test` | the schema's `--check` and tests, `cargo test` of the nine AoT crates | yes |
| `mordant` | `mordant` | `bun run rust:mordant` | advisory (`continue-on-error`) |

- `clippy` lints the default targets only (lib and bin): test code was never held to the clippy lint set. Its second step, `cargo check --workspace --all-targets`, type-checks `#[cfg(test)]` code, `tests/` and `benches/` so they keep compiling. Nothing else builds them except the crates `rust:miri` runs.
- `clippy`, `miri` and `lolhtml` pin `RUSTUP_TOOLCHAIN` at the workflow level (kept in sync with `channel` in `rust-toolchain.toml`) so rustup does not install that file's cross-target list; the action installs the toolchain with `--profile minimal` plus the components the job names (`clippy`, `miri rust-src`, none).
- `clippy`, `miri`, `lolhtml` and `aot-rust-tests` pin `RUSTUP_TOOLCHAIN` at the workflow level (kept in sync with `channel` in `rust-toolchain.toml`) so rustup does not install that file's cross-target list; the action installs the toolchain with `--profile minimal` plus the components the job names (`clippy`, `miri rust-src`, none, none).
- `lolhtml` exists because the vendored lol-html is a fork (oven-sh/lol-html, `bun` branch) whose own test suite is the only thing guarding the fork's invariants. It used to trigger only on `scripts/build/deps/lolhtml.ts`; it now shares the workflow's wider path filter.
- `aot-rust-tests` tests the Rust half of the AoT compiler (`bun build --compile --aot`) without linking Bun. Its ninja targets are `codegen engine-test-programs clone-zstd clone-lolhtml clone-rust-argon2`. `codegen` fetches the prebuilt WebKit tarball (about 700 MB) in every job that builds it, because the table of built-ins is generated from the tarball's `Source/JavaScriptCore/aot/builtins/generated` and the schema's Rust files by the tarball's `aot/ir/generator`. `engine-test-programs` (`jsc` and `testaot`) is the only C++ this job compiles and links: the five sources of Bun's table of built-ins, with the tarball's `lib/libjsc-objects.a`, `lib/libtestaot-objects.a` and libraries. The `testaot` in a tarball's `bin/` has another table and reads nothing that Bun's front end writes. `clone-zstd` is for the build script of `bun_sema_standalone`, which compiles zstd's decoder from `vendor/zstd` into the test binaries; the jobs that only check link nothing and do not need it. The tarball is extracted to a cache directory named after the WebKit version and the build configuration, so `bun scripts/build/aot-paths.ts` prints where `testaot`, `jsc`, the schema and the engine's half of the table are, as `NAME=<path>` lines that the job appends to `$GITHUB_ENV`. `bun test test/internal/aot-schema-generator.test.ts` runs here, with `AOT_SCHEMA` set by `aot-paths.ts`: it skips itself without an engine, as on Buildkite's test machines. The Rust files that the schema gives are written by the `codegen` target, by the tarball's generator from the tarball's schema, so they are always those of the **pinned** WebKit. The schema, its generator and its C++ output belong to WebKit, so a schema change is made with `--webkit=local`; it lands in WebKit first, then in Bun as one change: the new `WEBKIT_VERSION` (`scripts/build/deps/webkit.ts`) and the hand-written Rust that follows it.
- `mordant` runs the [mordant](https://github.com/scarletindustries/mordant) lint pack as an advisory (`continue-on-error`) job. Mordant ships its own runner, the way clippy does. `cargo mordant` is `cargo check` with `mordant-driver` (rustc with the lints linked in) as `RUSTC_WORKSPACE_WRAPPER`, and it builds into `target/mordant/check`. The shared action installs mordant's nightly (`MORDANT_TOOLCHAIN`) with `rustc-dev` and `llvm-tools-preview`, and every cargo call in the job names it (`cargo +"$MORDANT_TOOLCHAIN" …`): `cargo install --locked --git … --rev "$MORDANT_REV"` builds the two binaries with it, and `scripts/rust-mordant.ts` runs `cargo mordant` under it. It is not spelled `RUSTUP_TOOLCHAIN` because `test/internal/source-lints/ci-image-pins.test.ts` holds every `RUSTUP_TOOLCHAIN: nightly-…` in a workflow to the channel in `rust-toolchain.toml`, and this one moves with mordant instead. One cache covers them: `~/.cargo/bin/{cargo-mordant,mordant-driver}`, keyed on the nightly and the rev. The job restores it with `actions/cache/restore` and saves it with `actions/cache/save` right after the build, because the post step of `actions/cache` does not run in a job that failed, and a pull request with a finding over the baseline would then build mordant again on every push. Because that nightly is older than ours, the script passes `-A unknown_lints` through `MORDANT_RUSTFLAGS`. It is skipped on `merge_group`.
- Mordant's nightly is the compiler that checks this workspace while the lints run, so it must still be able to compile it. When a `rust-toolchain.toml` bump brings in an API that nightly lacks, the job fails on every PR until mordant moves to a newer nightly and the pin here follows. #42851 was one: the job was off from then until mordant moved to 2026-09-01.

Expand Down
10 changes: 10 additions & 0 deletions .github/workflows/bun-types.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,5 +43,15 @@ jobs:
run: |
bun install
bun install --cwd test
- name: Fetch the engine's code generators
# The code generators import TypeScript of the engine. A release of WebKit has it as an asset of its own; an
# older one only inside its tarballs.
run: |
version=$(sed -n 's/^export const WEBKIT_VERSION = "\(.*\)";$/\1/p' scripts/build/deps/webkit.ts)
release="https://github.com/oven-sh/WebKit/releases/download/autobuild-${version#autobuild-}"
mkdir -p vendor/WebKit
curl -fsSL --retry 3 -o "$RUNNER_TEMP/engine.tar.gz" "$release/bun-webkit-aot-sources.tar.gz" ||
curl -fsSL --retry 3 -o "$RUNNER_TEMP/engine.tar.gz" "$release/bun-webkit-linux-amd64-lto.tar.gz"
tar -xzf "$RUNNER_TEMP/engine.tar.gz" -C vendor/WebKit --strip-components=1 --exclude=bun-webkit/Source/JavaScriptCore/aot/tests bun-webkit/Source/JavaScriptCore/aot
- name: Check types
run: bun test test/integration/bun-types/bun-types.test.ts
29 changes: 29 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,16 @@ jobs:
run: |
bun x tsc --noEmit -p scripts/build/tsconfig.json
bun x tsc --noEmit -p scripts/tsconfig.json
- name: Fetch the engine's code generators
# The code generators and their types import TypeScript of the engine. A release of WebKit has it as an asset of its
# own; an older one only inside its tarballs.
run: |
version=$(sed -n 's/^export const WEBKIT_VERSION = "\(.*\)";$/\1/p' scripts/build/deps/webkit.ts)
release="https://github.com/oven-sh/WebKit/releases/download/autobuild-${version#autobuild-}"
mkdir -p vendor/WebKit
curl -fsSL --retry 3 -o "$RUNNER_TEMP/engine.tar.gz" "$release/bun-webkit-aot-sources.tar.gz" ||
curl -fsSL --retry 3 -o "$RUNNER_TEMP/engine.tar.gz" "$release/bun-webkit-linux-amd64-lto.tar.gz"
tar -xzf "$RUNNER_TEMP/engine.tar.gz" -C vendor/WebKit --strip-components=1 --exclude=bun-webkit/Source/JavaScriptCore/aot/tests bun-webkit/Source/JavaScriptCore/aot
- name: Typecheck the built-in modules
# The code generators write the types src/js/builtins.d.ts references (build/types) and the enums the dev
# server's sources import (src/runtime/bake/generated.ts).
Expand All @@ -45,3 +55,22 @@ jobs:
run: |
bun x tsc --noEmit -p src/tsconfig.json
bun x tsc --noEmit -p src/runtime/bake/tsconfig.json
- name: Check that every name of the compiler's schema has a use
# The uses are in the engine's C++ and in Bun's Rust. The build looks for them only where it compiles the engine,
# and CI links a prebuilt one.
run: |
version=$(sed -n 's/^export const WEBKIT_VERSION = "\(.*\)";$/\1/p' scripts/build/deps/webkit.ts)
git init --quiet "$RUNNER_TEMP/WebKit"
git -C "$RUNNER_TEMP/WebKit" remote add origin https://github.com/oven-sh/WebKit.git
git -C "$RUNNER_TEMP/WebKit" sparse-checkout set Source/JavaScriptCore
git -C "$RUNNER_TEMP/WebKit" fetch --quiet --depth=1 --filter=blob:none origin "refs/tags/autobuild-${version#autobuild-}"
git -C "$RUNNER_TEMP/WebKit" checkout --quiet FETCH_HEAD
BUN_WEBKIT_PATH="$RUNNER_TEMP/WebKit" bun test test/internal/build-aot-codegen-declared-outputs.test.ts -t "finds a use for every name of the schema"
- name: Run the tests that read the engine's sources
# The machines that run test/aot have no sources of the engine, so these files skip themselves there.
# The step ends where grep finds no file: `bun test` without a file runs every test.
env:
AOT_REQUIRE_ENGINE_SOURCES: "1"
run: |
files=$(grep -l "harness/engine-text" test/aot/*.test.ts)
BUN_WEBKIT_PATH="$RUNNER_TEMP/WebKit" bun test $files
Loading
Loading