Is permanent generation part of the heap or does it lies in a different space of itself in jvm

前端 未结 5 444
挽巷
挽巷 2021-01-02 14:39

I have seen multiple comments regarding this question - some say yes and some say no, and many of the answers are ambiguous. Can anyone please describe in simpler terms wher

5条回答
  •  青春惊慌失措
    2021-01-02 14:53

    Original (perhaps mistaken) answer: If wikipedia is to be believed, it's part of the heap.

    Edit: I've looked around at this more, including the site referenced in a comment by the OP. During this research I came across this SO question, which references this document, which indicates that for Sun Java (version 6), the permanent collection is actually outside the heap. That said, I'm no Java expert and wasn't previously aware of the memory management details at this level. If my reading is correct, the placement - or even the existence - of the permanent generation is a jvm implementation detail.

提交回复
热议问题