want to know precise GC benchmarks

Mike Parker aldacron at gmail.com
Tue Oct 1 17:06:47 UTC 2019


On Tuesday, 1 October 2019 at 16:24:49 UTC, a11e99z wrote:

>
> why I want to know such info?
> CodinGame sometimes use time-limit for bot move for example 
> 100ms, and bot will be disqualified in case no answer

Simple solution: don't allocate every frame. The GC only runs 
when it needs to and it only needs to if an allocation request 
takes it over a certain threshold. If you need to allocate at 
all, do it up front. Or better, do it statically. Then the GC 
won't run at all.

What sort of CodinGame bot would you need to allocate from the GC 
for anyway?


More information about the Digitalmars-d-learn mailing list