v test reporter crashes with memory allocation failure (heap corruption)
Nobody has claimed this yet.
- Dominant language
- V
- Stars
- 37.9k
- Forks
- 2.3k
- Avg merge
- 17h 8m
- Merged PRs (30d)
- 448
Description
V version
V 0.5.2 aca60a4 (master HEAD, 2026-09-17). The weekly.2026.08 prebuilt
runs the same suite green.
Repro
Any multi-test _test.v file of reasonable size, e.g. the
audit_checks_test.v in HorneroOS/hornero (main branch,
cli/modules/hornero_core/, run with VMODULES=$PWD/modules v test ./modules/hornero_core/audit_checks_test.v):
---- Testing... ----------------------------------------------------------------
malloc(0x3f94c34e73700)
V panic: memory allocation failure
v hash: aca60a4
src.c:20170: at v_panic: Backtrace
src.c:7564: by _memory_panic
src.c:20141: by v_malloc
src.c:10412: by new_dense_array
src.c:7455: by VMapData__set
src.c:10243: by map__set
src.c:17228: by testing__NormalReporter__report
src.c:5822: by testing__Reporter__report
src.c:17777: by testing__TestSession__print_messages
The crash is inside the test reporter itself (map__set while printing
test messages), before any test result is shown. The same tree compiled
with the weekly toolchain passes fully. Single tiny test files pass;
the corruption needs a larger suite, and manifests nondeterministically
(sometimes a hang instead of the panic).
Related: #28692 (same class of memory corruption in v vet's
diagnostic strings on the same toolchain).
Expected
Test reporter prints results instead of corrupting the heap.
[!NOTE]
You can use the 👍 reaction to increase the issue's priority for developers.Please note that only the 👍 reaction to the issue itself counts as a vote.
Other reactions and those to comments will not be taken into account.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce with VMODULES=$PWD/modules v test ./modules/hornero_core/audit_checks_test.v and compare the current toolchain with the weekly.2026.08 build. Start at testing__NormalReporter__report in the stack trace, where map__set fails while printing test messages; use the single-test and larger-suite cases to narrow the corruption. Done means the multi-test file prints its results without a panic or hang.
Written by the indexing model from the issue text.
Assessment
- Domain
- compilers, testing-qa
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100