Page 1 of 1

2.0.72 Crash operator new, DrawCommandBatch-flushSpritesBatch

Posted: Fri Nov 07, 2025 6:01 pm
by Messer1024
Hello, playing around a bit inside the map editor and got a random crash

Did I read this right and it just tried to allocate ~2.9TB of memory? :D

Code: Select all

85364.926 Popped blueprint record (player-index: 0, ID: 1200) from book (player-index: 0, ID: 1182)
85368.128 Popped blueprint record (player-index: 0, ID: 1202) from book (player-index: 0, ID: 1182)
85368.928 Popped blueprint record (player-index: 0, ID: 1200) from book (player-index: 0, ID: 1182)
85371.777 Popped blueprint record (player-index: 0, ID: 1194) from book (player-index: 0, ID: 1182)
85372.843 Popped blueprint record (player-index: 0, ID: 1202) from book (player-index: 0, ID: 1182)
85375.793 Popped blueprint record (player-index: 0, ID: 1194) from book (player-index: 0, ID: 1182)
86809.260 Error CrashHandler.cpp:503: Exception Code: e06d7363, Address: 0x00007ffcb21f804a
ModuleBase: 0x00007ff6317c0000, ImageSize: 02a11000, RelativeAddress: 80a3804a
86809.260 Error CrashHandler.cpp:523: Exception Context:
rax=000000003f800000, rbx=0000001afa4fc338, rcx=0000001afa4fbcf0,
rdx=0000000000000000, rsi=0000000000000001, rdi=00000000e06d7363,
rip=00007ffcb21f804a, rsp=0000001afa4fc210, rbp=0000000000000004,
 r8=0000001e00000099,  r9=0000016e9b78bc38, r10=0000016e9a6e6f40,
r11=0000001afa4fbbb9, r12=0000000000000000, r13=0000016e9d694080,
r14=0000016e9d77e100, r15=0000016e9d82c660
86809.260 Crashed in C:\WINDOWS\System32\KERNELBASE.dll (0x00007ffcb2130000 - 0x00007ffcb2522000)
Factorio crashed. Generating symbolized stacktrace, please wait ...
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\libraries\StackWalker\StackWalker.cpp(924): StackWalker::ShowCallstack
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Util\Logger.cpp(339): Logger::writeStacktrace
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Util\Logger.cpp(381): Logger::logStacktrace
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Util\CrashHandler.cpp(183): CrashHandler::writeStackTrace
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Util\CrashHandler.cpp(552): CrashHandler::SehHandler
ERROR: SymGetLineFromAddr64, GetLastError: 487 (Address: 00007FFCB2246FD3)
00007FFCB2246FD3 (KERNELBASE): (filename not available): UnhandledExceptionFilter
ERROR: SymGetLineFromAddr64, GetLastError: 487 (Address: 00007FFCB4A6A623)
00007FFCB4A6A623 (ntdll): (filename not available): strncpy
ERROR: SymGetLineFromAddr64, GetLastError: 487 (Address: 00007FFCB4A219B3)
00007FFCB4A219B3 (ntdll): (filename not available): _C_specific_handler
ERROR: SymGetLineFromAddr64, GetLastError: 487 (Address: 00007FFCB4A6632F)
00007FFCB4A6632F (ntdll): (filename not available): _chkstk
ERROR: SymGetLineFromAddr64, GetLastError: 487 (Address: 00007FFCB4912327)
00007FFCB4912327 (ntdll): (filename not available): RtlLocateExtendedFeature
ERROR: SymGetLineFromAddr64, GetLastError: 487 (Address: 00007FFCB490A961)
00007FFCB490A961 (ntdll): (filename not available): RtlRaiseException
ERROR: SymGetLineFromAddr64, GetLastError: 487 (Address: 00007FFCB21F804A)
00007FFCB21F804A (KERNELBASE): (filename not available): RaiseException
D:\a\_work\1\s\src\vctools\crt\vcruntime\src\eh\throw.cpp(75): _CxxThrowException
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Util\CrashHandler.cpp(602): CrashHandler::NewHandler
minkernel\crts\ucrt\src\appcrt\heap\new_handler.cpp(79): _callnewh
D:\a\_work\1\s\src\vctools\crt\vcstartup\src\heap\new_scalar.cpp(40): operator new
C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\include\xmemory(229): std::_Allocate<16,std::_Default_allocate_traits,0>
C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\include\vector(1229): std::vector<PipelineBindings::Bind,std::allocator<PipelineBindings::Bind> >::_Resize_reallocate<std::_Value_init_tag>
C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\include\vector(1278): std::vector<PipelineBindings::Bind,std::allocator<PipelineBindings::Bind> >::resize
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Util\Container\SmallVector.hpp(151): SmallVector<PipelineBindings::Bind,12,0>::resize
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Graphics\DrawCommandBatch.cpp(337): DrawCommandBatch::flushSpritesBatch
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Graphics\CloudShaderRenderLogic.cpp(32): CloudShaderRenderLogic::render
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Graphics\DrawEngine.cpp(298): DrawEngine::render
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Graphics\GameRenderer.cpp(236): GameRenderer::renderInternal
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Graphics\GameRenderer.cpp(187): GameRenderer::render
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\MainLoop.cpp(1520): MainLoop::render
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\MainLoop.cpp(730): MainLoop::mainLoopStep
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\MainLoop.cpp(414): MainLoop::run
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Main.cpp(906): fmain
C:\Users\build\AppData\Local\Temp\factorio-build-FWjsjC\src\Main.cpp(928): wmain
D:\a\_work\1\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl(288): __scrt_common_main_seh
ERROR: SymGetLineFromAddr64, GetLastError: 487 (Address: 00007FFCB398E8D7)
00007FFCB398E8D7 (KERNEL32): (filename not available): BaseThreadInitThunk
ERROR: SymGetLineFromAddr64, GetLastError: 487 (Address: 00007FFCB498C53C)
00007FFCB498C53C (ntdll): (filename not available): RtlUserThreadStart
Stack trace logging done
86818.842 Error CrashHandler.cpp:190: Map tick at moment of crash: 6270388
86819.201 Info CrashHandler.cpp:318: Executable CRC: 68572744
86819.201 Error Util.cpp:95: Unexpected error occurred. If you're running the latest version of the game you can help us solve the problem by posting the contents of the log file on the Factorio forums.
Please also include the save file(s), any mods you may be using, and any steps you know of to reproduce the crash.
86822.403 Uploading log file
86822.427 Error CrashHandler.cpp:270: Heap validation: success.
86822.429 Creating crash dump.
86823.443 CrashDump success
86823.443 Error CrashHandler.cpp:421: Unhandled exception type: .?AVBadAllocation@@
86823.443 Error CrashHandler.cpp:435: Unhandled exception: memory allocation of 3149198430215 bytes failed! RAM: 9494/16276, Page: 19551/26516.
86823.443 ProcessMemoryCounters: PageFaultCount=22507816, PeakWorkingSetSize=4588113920, WorkingSetSize=728264704, QuotaPeakPagedPoolUsage=1195248, QuotaPagedPoolUsage=1015584, QuotaPeakNonPagedPoolUsage=433248, QuotaNonPagedPoolUsage=110120, PagefileUsage=5671653376, PeakPagefileUsage=3160989306880
86823.443 PerformanceInformation: CommitTotal=5206645, CommitLimit=6788268, CommitPeak=5394840, PhysicalTotal=4166828, PhysicalAvailable=1561248, SystemCache=1303244, KernelTotal=293646, KernelPaged=145717, KernelNonpaged=147929, PageSize=4096, HandleCount=149944, ProcessCount=277, ThreadCount=4346

Re: 2.0.72 Crash operator new, DrawCommandBatch-flushSpritesBatch

Posted: Fri Nov 07, 2025 7:30 pm
by Loewchen
Post the complete log, the save file and steps to reproduce the crash please, see 3638.

Re: 2.0.72 Crash operator new, DrawCommandBatch-flushSpritesBatch

Posted: Sat Nov 08, 2025 8:26 pm
by Messer1024
Added the full crash log as an attachment
I do not have a save file and I cannot reproduce the issue

What did you do?
- I was sitting inside the map editor, I was using blueprints and copying blueprints with guesstimate ~100 to 500 entities in a 'kinda small' area. Did the same thing >100 times prior to it inside the editor and session that had been going on for a couple of days (hibernated computer).

What happened?
- Game crashed, didn't notice anything weird prior to it. During this ~30h session (spread over many days, computer hibernated) I kinda feel that I have experienced some random stalls, that kinda felt like it might have something to do with how my blueprint interacts with moving clouds/environment. Or something completely different

What did you expect to happen instead? It might be obvious to you, but do it anyway!
- Since the game crashed, my expectancy was that the game should not crash. I reported it primarily for tracking purposes. Felt like the stack trace should be able to pinpoint the underlying issue if it something you want to prioritize.

Does it happen always, once, or sometimes?
- This happened once on my machine.

Re: 2.0.72 Crash operator new, DrawCommandBatch-flushSpritesBatch

Posted: Sat Nov 08, 2025 8:35 pm
by Rseding91
Thanks for the report however there’s nothing useful in the stack trace to work with. From what it shows it looks like the CPU executed an instruction wrong or there was some kind of memory corruption. There’s no normal scenario where the logic would attempt to allocate that much memory without first allocating increasingly larger chunks up until the failure.

If that was happening, it would have failed long before that point and would be reproducible.