Is it possible to skip the nursery?

▼魔方 西西 提交于 2019-12-02 19:00:21

In the GHC garbage collector there are no hooks for hinting at the generation an object should be allocated to. However, you might be able to exploit the operational behavior in a couple of ways:

  • depending on the data type, you may be able to exploit the pinned object region to bypass the generational stages altogether.

  • exploit eager promotion by ensuring your long lived object is pointed out by something itself long lived...

  • make the data into a CAF and bypass dynamic allocation altogether.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!