Figure 8 shows the Suspects TAB from the analysis result of two heap dumps taken from a memory leak case involving an infinite loop.
图8中的Suspects选项卡显示了从涉及无限循环的内存泄漏案例中获取的两个堆转储的分析结果。
Thus the garbage collector can reclaim most of the memory allocated on each loop, but it can't reclaim the arrays that are added to the list.
因此,垃圾收集器可以回收在每个循环上分配的大多数内存,但它不能回收添加到列表中的数组。
For example, a compiler may choose to optimize a loop index variable by storing it in a register, or the cache may delay flushing a new value of a variable to main memory until a more opportune time.
例如,编译器为了优化一个循环索引变量,可能会选择把它存储到一个寄存器中,或者缓存会延迟到一个更适合的时间,才把一个新的变量值存入主存。
应用推荐