From: Doug Coleman Date: Tue, 10 Mar 2020 08:31:23 +0000 (-0500) Subject: vm/allot.hpp: Print more room info when allot() fails. X-Git-Tag: 0.99~3377 X-Git-Url: https://gitweb.factorcode.org/gitweb.cgi?p=factor.git;a=commitdiff_plain;h=fcc225466fa2fbb29e2f42eb582160de4d04de91 vm/allot.hpp: Print more room info when allot() fails. This is to help debug win64. Some interesting observations: fails without any error: factor.com -codeheap=74000 fails with VirtualAlloc error: factor.com -codeheap=80000 --- diff --git a/vm/allot.hpp b/vm/allot.hpp index b6bb8c1b71..1987b2b0e4 100644 --- a/vm/allot.hpp +++ b/vm/allot.hpp @@ -20,9 +20,10 @@ inline code_block* factor_vm::allot_code_block(cell size, // Insufficient room even after code GC, give up if (block == NULL) { - std::cout << "Code heap used: " << code->allocator->occupied_space() - << "\n"; - std::cout << "Code heap free: " << code->allocator->free_space << "\n"; + std::cout << "Code heap used: " << code->allocator->occupied_space() << "\n"; + std::cout << "Code heap free: " << code->allocator->free_space << "\n"; + std::cout << "Code heap free_block_count: " << code->allocator->free_block_count << "\n"; + std::cout << "Code heap largest_free_block: " << code->allocator->largest_free_block() << "\n"; std::cout << "Request : " << block_size << "\n"; fatal_error("Out of memory in allot_code_block", 0); }