+#ifdef PROFILING
+ // @LDV profiling
+ //
+ // Note:
+ // We do not need to perform a major garbage collection because all the
+ // closures created since the last census will not affect the profiling
+ // statistics anyhow.
+ //
+ // Note:
+ // We ignore any object created afterwards.
+ // finalizeWeakPointersNow() may corrupt the heap (because it executes
+ // rts_evalIO(), which adds an initial evaluation stack again).
+ // Thus, we call LdvCensusKillAll() here, and prohibit LDV profiling
+ // afterwards.
+ // Acutally, it is pointless to call LdvCensusKillAll() any later because
+ // no object created later will be taken into account for profiling.
+ if (RtsFlags.ProfFlags.doHeapProfile == HEAP_BY_LDV)
+ LdvCensusKillAll();
+#endif
+