Skip to content

fix: repair four pre-existing main CI failures (#3135) - #3139

Closed
localai-org-maint-bot wants to merge 1 commit into
mainfrom
fix/main-red
Closed

fix: repair four pre-existing main CI failures (#3135)#3139
localai-org-maint-bot wants to merge 1 commit into
mainfrom
fix/main-red

Conversation

@localai-org-maint-bot

@localai-org-maint-bot localai-org-maint-bot commented Sep 11, 2026

Copy link
Copy Markdown
Collaborator

fix: repair four pre-existing main CI failures (#3135)

Four independent failures on main block all open pull requests.

macos-metal-mlx: SpeechEngine explicitly defaulted its copy and move
special member functions, but a std::mutex member makes them implicitly
deleted. Clang promoted -Wdefaulted-function-deleted to an error under
-Werror. Changed all four to = delete.

sanitize-cpu address: the elementwise GEMM scalar fallback dereferenced
unaligned uint16_t pointers in ElemA::Cvt and F16ToF32 at 11 call
sites across four files. Wrapped each dereference with
vt::LoadUnaligned for a safe scalar load.

sanitize-cpu thread: the gemma4_moe FP8-native branch at line 1637
matched on CPU, called EnsureGemma4Fp8NativeOnDevice which returns false
on every non-ROCm build, then had no fallback. The output buffer y was
never written. Under TSan the allocator zero-fills memory, exposing the
use of uninitialized memory as all-zeros output. Added an else clause
that falls back to the same host computation path the adjacent branch
uses.

windows-msvc: host_available_memory_bytes passed the glibc-only "e"
(close-on-exec) flag to fopen. MSVC UCRT treats unknown mode flags as an
invalid parameter and calls __fastfail, killing the process with
0xC0000409 before fopen returns. Changed the mode to "r" so fopen returns
nullptr on Windows where /proc/meminfo does not exist, and the existing
nullptr guard returns 0 as callers expect. The fopen fix exposed a
latent second issue: the post-build CRT audit calls dumpbin directly, but
dumpbin is not on PATH on windows-2022 runners (the VS cmake generator
finds cl.exe internally without exporting the toolchain). Added a
vswhere lookup that prepends the MSVC bin directory to PATH before the
CRT audit runs. The vswhere lookup alone was not sufficient: dumpbin calls
used 2>&1 to merge stderr into stdout, but under $ErrorActionPreference =
"Stop" (line 13) PowerShell 7 wraps native command stderr as ErrorRecord
objects and promotes them to terminating errors, swallowing dumpbin's
stdout and leaving the directive output empty. Removed 2>&1 from all
dumpbin and cl call sites, added /nologo to suppress the banner, and
added a dumpbin availability check after the vswhere block. The cl banner
call temporarily relaxes ErrorActionPreference to Continue since cl writes
its banner to stderr.

Closes #3135

FOLLOWING_AGENTS_PROTOCOL

Following-Agents-Protocol: true
AI-Assisted: true
Assisted-by: AGENT:regolo-glm5.2 [maki]

@mudler
mudler force-pushed the fix/main-red branch 2 times, most recently from fa02a1d to bd1e70e Compare September 11, 2026 18:17
Four independent failures on main block all open pull requests.

macos-metal-mlx: SpeechEngine explicitly defaulted its copy and move
special member functions, but a std::mutex member makes them implicitly
deleted. Clang promoted -Wdefaulted-function-deleted to an error under
-Werror. Changed all four to = delete.

sanitize-cpu address: the elementwise GEMM scalar fallback dereferenced
unaligned uint16_t pointers in ElemA<K>::Cvt and F16ToF32 at 11 call
sites across four files. Wrapped each dereference with
vt::LoadUnaligned<T> for a safe scalar load.

sanitize-cpu thread: the gemma4_moe FP8-native branch at line 1637
matched on CPU, called EnsureGemma4Fp8NativeOnDevice which returns false
on every non-ROCm build, then had no fallback. The output buffer y was
never written. Under TSan the allocator zero-fills memory, exposing the
use of uninitialized memory as all-zeros output. Added an else clause
that falls back to the same host computation path the adjacent branch
uses.

windows-msvc: host_available_memory_bytes passed the glibc-only "e"
(close-on-exec) flag to fopen. MSVC UCRT treats unknown mode flags as an
invalid parameter and calls __fastfail, killing the process with
0xC0000409 before fopen returns. Changed the mode to "r" so fopen returns
nullptr on Windows where /proc/meminfo does not exist, and the existing
nullptr guard returns 0 as callers expect. The fopen fix exposed a
latent second issue: the post-build CRT audit calls dumpbin directly, but
dumpbin is not on PATH on windows-2022 runners (the VS cmake generator
finds cl.exe internally without exporting the toolchain). Added a
vswhere lookup that prepends the MSVC bin directory to PATH before the
CRT audit runs. The vswhere lookup alone was not sufficient: dumpbin calls
used 2>&1 to merge stderr into stdout, but under $ErrorActionPreference =
"Stop" (line 13) PowerShell 7 wraps native command stderr as ErrorRecord
objects and promotes them to terminating errors, swallowing dumpbin's
stdout and leaving the directive output empty. Removed 2>&1 from all
dumpbin and cl call sites, added /nologo to suppress the banner, and
added a dumpbin availability check after the vswhere block. The cl banner
call temporarily relaxes ErrorActionPreference to Continue since cl writes
its banner to stderr.

Closes #3135

FOLLOWING_AGENTS_PROTOCOL

Following-Agents-Protocol: true
AI-Assisted: true
Assisted-by: AGENT:regolo-glm5.2 [maki]
@localai-org-maint-bot

Copy link
Copy Markdown
Collaborator Author

Closing as redundant. The four CI failures this PR addressed have all been fixed independently:

The enforcement floor advance (#3142) is tracked separately and supersedes any remaining main-CI repair work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

main CI is red: macos build, address sanitizer, thread sanitizer, Windows api_server

2 participants