<feed xmlns='http://www.w3.org/2005/Atom'>
<title>npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/runtime/test/startup_trace_test.cpp, branch codex/full-precompile-default</title>
<subtitle>[no description]</subtitle>
<id>https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/atom?h=codex%2Ffull-precompile-default</id>
<link rel='self' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/atom?h=codex%2Ffull-precompile-default'/>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/'/>
<updated>2026-11-28T19:01:06+00:00</updated>
<entry>
<title>tests: derive every test's scratch folder from test_temp_dir::temp_dir, not GetTempPath (TEST-TEMPDIR-STRIPPED-ENV)</title>
<updated>2026-11-28T19:01:06+00:00</updated>
<author>
<name>thiefyzheng</name>
<email>thiefyzheng@users.noreply.github.com</email>
</author>
<published>2026-11-25T05:33:21+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=b17397f0dd77280e107de489fc0f2a92471ace60'/>
<id>urn:sha1:b17397f0dd77280e107de489fc0f2a92471ace60</id>
<content type='text'>
With TMP, TEMP and USERPROFILE all unset, GetTempPathW returns C:\Windows\, and the throwing create_directories/copy_file/ofstream on C:\Windows\leonida_* aborts with 0xc0000409 before the test body runs. runtime/test/test_temp_dir.h grows one entry, testfiles::temp_dir(): LEONIDA_TEST_DIR when set, the current directory when the temp environment is stripped (Windows), else the standard temp resolution. Fifty-two test files and the tiny_game fixture that called GetTempPathA/W or temp_directory_path directly now use it; d3d12_queue_handover_test.cpp also checks the _sopen_s result in capture_stderr instead of silently returning empty stderr. One runtime source function needed the same fallback because tests exercise it: tls_host_clone_dir in runtime/src/pe_loader.cpp (the loader_tls tests). Rebased onto current main after its D3D-448 additions to d3d12_mesh_test.cpp (3-way; the mesh test keeps both). Verification on a Windows VM: stripped environment - the previously crashing d3d12 tests exit 77 (no usable Vulkan device) instead of aborting, file_system_test runs all 505 checks and loader_test all 95 with zero failures; normal environment - identical outcomes; LEONIDA_TEST_DIR honored under a fully stripped environment (the scratch folder observed mid-run inside it, cleaned up after the pass). The finding is whoalin1's (coordination issue #14, 02:37:44Z).

AI-assisted.
</content>
</entry>
<entry>
<title>Merge main into delay-import-thread-order-notes</title>
<updated>2026-11-25T21:38:51+00:00</updated>
<author>
<name>Jan Trencansky</name>
<email>jan.trencansky@protonmail.com</email>
</author>
<published>2026-11-25T21:38:51+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=afea66650c7eb88823ce9fa9090ae0250bd72530'/>
<id>urn:sha1:afea66650c7eb88823ce9fa9090ae0250bd72530</id>
<content type='text'>
runtime/shims/startup_trace.h: main added the tls_index0 example event
and the exception's region/regs fields to the header comment; keep them,
add this branch's delay_import_unimplemented example and renumber seq.

Co-Authored-By: Claude Opus 5.5 &lt;noreply@anthropic.com&gt;
</content>
</entry>
<entry>
<title>[integration] Linux/Proton and native Windows: boot through the story load (RT-PROTON-STORY-LOAD)</title>
<updated>2026-11-24T17:42:12+00:00</updated>
<author>
<name>Moriz82</name>
<email>72836413+Moriz82@users.noreply.github.com</email>
</author>
<published>2026-11-24T17:42:12+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=273b3bdf9d6e736442ad584ad464df6e86ee928b'/>
<id>urn:sha1:273b3bdf9d6e736442ad584ad464df6e86ee928b</id>
<content type='text'>
One squashed commit of a fork that was developed on a Linux/Proton machine and
tested on two native Windows machines. On all of them the retail 1.0.2.1
package now launches, shows its launch movie, first-run pages and landing
prompt, runs the story load to its end with the loading slideshow drawing its
artwork, and enters the world phase. A first world frame is not verified yet.
docs/linux_proton.md has the setup, a healthy boot's timeline, the machines
and where it stops.

Runtime: frames in the title's own window; DirectStorage pinned reads,
page-list scatter/gather, BCPack and unshuffle with a locally generated
predictor file; pooled, device-local and deferred image backing for streamed
and placed textures; enhanced barriers into LAYOUT_UNDEFINED; a bindless table
that degrades instead of refusing a submission; a descriptor hash finalizer
(off until a library carries it); directly indexed heap offsets for compute
dispatches and VS/PS/GS draws; title buffer windows outside a fragmented
arena; opt-in device-local copies of streamed buffer views; write-fault
retries under the tracker lock, shared trackers and write-watched title memory
for native Windows; device-loss, compute-input and memory probes.

Translator: loop bounds at structured exits, the eight FidelityFX programs
that use a packed-dot form the disassembler skips, buffer bounds modes per
view kind, a compaction option, the hash finalizer option.

Tools and scripts: Linux boot scripts (Wine/Proton, no network), a Windows
boot script, the paired compute translation script.

No game data. AI-assisted (Claude Code and Codex agents), reviewed and booted
by people on the machines named in docs/linux_proton.md.

Co-authored-by: Plaaasma &lt;47513553+Plaaasma@users.noreply.github.com&gt;
Co-Authored-By: Claude Fable 5.2 &lt;noreply@anthropic.com&gt;
</content>
</entry>
<entry>
<title>pe_loader: trace delay imports bound to an unimplemented thunk; note delay-load and thread-attach order</title>
<updated>2026-11-24T10:46:57+00:00</updated>
<author>
<name>Jan Trencansky</name>
<email>jan.trencansky@protonmail.com</email>
</author>
<published>2026-11-23T16:41:08+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=82d6883bed1c18dfb4d409314e7805262aded79e'/>
<id>urn:sha1:82d6883bed1c18dfb4d409314e7805262aded79e</id>
<content type='text'>
Delay imports are bound eagerly (deliberate: --dry-run shows the whole import surface). A delay-loaded DLL or
function that nothing serves becomes an unimplemented thunk returning 0 at its first call, where Windows'
delay-load helper raises 0xC06D007E / 0xC06D007F, which a title can catch for a fallback. The binding is
unchanged; --trace now writes a delay_import_unimplemented event (module, import) for each such import at load,
so the first boot names them before any image code runs.

docs/runtime_imports.md gets two notes on where the loader differs from Windows: the eager delay binding above,
and that DLL_THREAD_ATTACH reaches TLS callbacks in TLS slot order, which puts the executable before the DLLs it
imports (Windows' order is undocumented). runtime/README.md lists the new trace event and now says the loader
applies DIR64 and HIGHLOW relocations and rejects HIGH, LOW and HIGHADJ (old upstream 761).

startup_trace_test gets a synthetic DLL with one ordinary and two delay imports (one missing, one bound to
kernel32): exactly one delay_import_unimplemented event, naming the missing delay import.

Findings by cynbun in the old upstream coordination issue (old upstream 7231).

Co-Authored-By: Claude Opus 5.5 &lt;noreply@anthropic.com&gt;
</content>
</entry>
<entry>
<title>startup trace: log OutputDebugStringW once, not again as its lossy ANSI fallback</title>
<updated>2026-11-22T22:59:12+00:00</updated>
<author>
<name>AAyberkU</name>
<email>97833630+AAyberkU@users.noreply.github.com</email>
</author>
<published>2026-11-22T22:59:12+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=3ac0ee5f34c41b60bb916c4ae2634acafe3b6d17'/>
<id>urn:sha1:3ac0ee5f34c41b60bb916c4ae2634acafe3b6d17</id>
<content type='text'>
With no debugger attached, OutputDebugStringW raises DBG_PRINTEXCEPTION_WIDE_C and, when nothing
handles it, calls OutputDebugStringA on its own ANSI copy of the text, which raises
DBG_PRINTEXCEPTION_C. The trace handler logged both, so every wide debug line appeared twice, the
second one lossy (characters outside the ANSI code page became "?").

Remember the wide exception's ANSI pointer (ExceptionInformation[3]) in a thread_local and skip the
ANSI exception whose string pointer ([1]) matches it. Every debug string on the thread resets the
marker, so only the exception right after the wide one is ever skipped and a later
OutputDebugStringA is still logged. startup_trace_test checks one UTF-8 line for a non-ASCII
OutputDebugStringW and that the OutputDebugStringA after it is still there.

Co-Authored-By: Claude Opus 5.5 &lt;noreply@anthropic.com&gt;
</content>
</entry>
<entry>
<title>fix(startup_trace): guard SEH unwind in VEH handler and tear down safely at exit</title>
<updated>2026-11-22T17:58:44+00:00</updated>
<author>
<name>totonii</name>
<email>totonicontato@gmail.com</email>
</author>
<published>2026-11-22T17:58:44+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=0e70866b9ab1c1d641380f94676b92838cfede1f'/>
<id>urn:sha1:0e70866b9ab1c1d641380f94676b92838cfede1f</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Startup trace: never replace an existing file; write UTF-8 only</title>
<updated>2026-11-22T15:06:49+00:00</updated>
<author>
<name>Leonardo Guimaraes</name>
<email>leozinhoszg@gmail.com</email>
</author>
<published>2026-11-22T15:06:49+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=d6443b152469c467f6295889de855b2931095161'/>
<id>urn:sha1:d6443b152469c467f6295889de855b2931095161</id>
<content type='text'>
Review on #1756 (Vonsek):
- The trace is opened before the loader reads the image, so `wb` could
  truncate an input named by mistake (the image itself). open() now
  uses "x" mode and fails with EEXIST on an existing path; gta6rt says
  so and exits with 2.
- OutputDebugStringA text is in the ANSI code page. It is converted
  to UTF-8 before quoting, so a byte such as 0xE9 no longer breaks the
  JSON lines. Host module names now come from GetModuleFileNameW,
  converted to UTF-8, for the same reason.

startup_trace_test: an existing file is refused with EEXIST and its
bytes survive, the trace stays off; an ANSI debug string with 0xE9
appears as its UTF-8 form and the whole file is valid UTF-8.
</content>
</entry>
<entry>
<title>Runtime: opt-in startup trace (gta6rt --trace FILE)</title>
<updated>2026-11-22T15:03:22+00:00</updated>
<author>
<name>Leonardo Guimaraes</name>
<email>leozinhoszg@gmail.com</email>
</author>
<published>2026-11-22T04:24:50+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=2dca597bd9f143992032010037f2d5c3b970d312'/>
<id>urn:sha1:2dca597bd9f143992032010037f2d5c3b970d312</id>
<content type='text'>
Writes one JSON object per line, flushed per event: module maps, TLS
callbacks, DllMain results, the first call of each unimplemented import
with its caller as module+RVA, OutputDebugString text, exceptions with
module+RVA and a short unwind, and the exit code. A vectored handler
records and returns EXCEPTION_CONTINUE_SEARCH, so behaviour is unchanged.
Off by default.

startup_trace_test builds a synthetic DLL image (no game data) and
checks each event kind.
</content>
</entry>
</feed>
