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
{{ message }}
Repository navigation
comptime evaluator: std.string parse/string_to_int reaches extern with_parse_i64_ref and is not comptime-callable #2460
Found by the SDK rebuild (run 39152082294, windows-x86_64 job 117747635584):
error: action target 'sdk-windows-libc' failed during comptime evaluation: <embedded-std>/std/string.w:6:1: 'with_parse_i64_ref' has no With body to evaluate at compile time (an extern or a runtime intrinsic); reached through run_sdk_windows_libc_action -> sdk_compile_all -> par_run -> parse -> string_to_int
build/par.w:60 calls std.string's parse on WITH_BUILD_JOBSERVER_SLOTS. On hosts where build actions run in the comptime evaluator, any std helper backed by an extern is unreachable. rt_core's with_parse_i64_ref is a pure digit loop (rt/rt_core.w:3131), so parse is comptime-able in principle: either the evaluator should be able to evaluate it (its string/memory model), or std.string's parse should be a With digit loop over the &str view instead of an extern call (parse_u128_magnitude already is one, lib/std/string.w:435).
Near-term workaround landing separately: build/par.w parses digits locally. This issue is the root: a build-layer author cannot tell which std calls are evaluator-safe. Cousin of #2220 (comptime allocator).
Second instance, same path: SDK run 39171886271's Windows jobs got past parse (#2461) and failed at par_slot_acquire -> pid -> with_getpid, same refusal. #2462 fixes the par.w chain at its owners: string_to_int becomes a With body (parse evaluable everywhere, not just tool mode), tool mode's allowed runtime calls gain with_getpid/with_fs_symlink/with_fs_remove_file (the evaluator is the build process; the jobserver slot pair is driver state), and par_lane_critical reads through ToolFs. The general question - a build author cannot tell which std helpers are evaluator-safe - remains this issue's.
Activity
SDK rebuild: the four host failures of run 39152082294, each at its l…
ehartford commentedon Oct 19, 2026
Second instance, same path: SDK run 39171886271's Windows jobs got past parse (#2461) and failed at
par_slot_acquire -> pid -> with_getpid, same refusal. #2462 fixes the par.w chain at its owners: string_to_int becomes a With body (parse evaluable everywhere, not just tool mode), tool mode's allowed runtime calls gain with_getpid/with_fs_symlink/with_fs_remove_file (the evaluator is the build process; the jobserver slot pair is driver state), and par_lane_critical reads through ToolFs. The general question - a build author cannot tell which std helpers are evaluator-safe - remains this issue's.comptime: parse is a With body, and tool mode may ask its own pid and…
ehartford commentedon Oct 25, 2026
Triage 2026-10-25,
with v0.15.3.0(main a261b65): does not reproduce; f081060 (#2462) gaveparsea With body.