News for hackers. Stuff that matters.
Re:Shenandoah in OpenJDK 17: Sub-millisecond GC pauses by yakubin on Saturday September 18, 2021 @05:46AM (#28574925)
If the array is stack-allocated and the elements are boxed (i.e. heap-allocated) or have destructors, you are still going to need to call the destructors or the free on the elements when the array goes out of scope.
Re:Shenandoah in OpenJDK 17: Sub-millisecond GC pauses by ncmncm on Sunday September 19, 2021 @03:55PM (#28587373)
Such a layout, and all it costs, is typically unavoidable in GC languages, and usually easily avoided in non-GC languages, particularly in cases where it would matter.

Thus, it is incorrect to talk about multiple calls to a deallocator. You get just one for the whole array.

Re:Shenandoah in OpenJDK 17: Sub-millisecond GC pauses by Skinney on Monday September 20, 2021 @02:11AM (#28590776)
My point was: it still takes longer time to de-allocate a large array even if the only thing that needs to be freed is the array itself, when compared to a GC. GC never needs to free anything, it instead overwrites garbage memory with live memory.