Open command prompt (for Windows).
Type the below one
java -XX:+PrintFlagsFinal -version | findstr /i "HeapSize PermSize ThreadStackSize"
Note: In Java 8, permGen has been removed. Then what is been added, how to find out. Check out this link.
Hope this helps you. Please comment if any doubts and subscribe my blog.