RFR(S): 8005885: enhance PrintCodeCache to print more data

Chris Plummer chris.plummer at oracle.com
Tue Aug 27 13:02:31 PDT 2013


Hi Albert,

Looks much better.

PrintCodeCacheOnCompilation and PrintCodeCacheAllocation both of the
same help text. Can you clarify the difference between the two.

Have you considered having the detailed output include the name and size
of each buffer blob?

thanks,

Chris

On 8/26/13 11:44 PM, Albert Noll wrote:
>/  Hi,
/>/
/>/  Chris P., Vladimir, and Christian T., thanks for looking at the code.
/>/
/>/  One note: We currently have a lot of -XX flags to provide information
/>/  about the code
/>/  cache (PrintCodeCache, PrintCodeCacheDetails, +Verbose,
/>/  PrintCodecacheOnCompilation,
/>/  and PrintCodeCacheAllocation.
/>/
/>/  We could combine these flags (or at least some of them) into one Integer
/>/  flag that gives the
/>/  level of detail that is printed. For example, we could make
/>/  -XX:PrintCodeCache=int
/>/  where: (this suggestion is not contained in the current patch)
/>/
/>/  int==0 -> no debug output
/>/  int==1 -> same debug output is PrintCodeCache
/>/  int==2 -> same debug output as PrintCodeCodeCacheDetails
/>/  int==3 -> same debug output as with int==1 and int==2 + Verbose
/>/  int==4 -> same debug output as with int==3 + PrintCodeCacheOnCompilation
/>/  int==5-> same debug output as with int==4 + PrintCodeCacheAllocation
/>/
/>/  Having levels of detail that can be specified via a variable seems
/>/  intuitive to
/>/  me. Please let me know what you think.
/>/
/>/  Here is the new webrev:
/>/  http://cr.openjdk.java.net/~anoll/8005885/webrev.01/  <http://cr.openjdk.java.net/%7Eanoll/8005885/webrev.01/>   
/>/  <http://cr.openjdk.java.net/%7Eanoll/8005885/webrev.01/>
/>/
/>/
/>/  I modified the patch so that the output is less verbose. Here are samples of
/>/  the output:
/>/
/>/
/>/  java -XX:+PrintCodeCache ...
/>/  CodeCache: size=245760kB used=8862kB max_used=9120kB free=236897kB
/>/     Interpreter=799kB live_nmethods=1565(6894kB) dead_nmethods=34(196kB)
/>/  stubs=77(1518kB) adapters=212(159kB)
/>/     bounds [0x00007f1195000000, 0x00007f1195900000, 0x00007f11a4000000]
/>/     compilation: enabled
/>/
/>/  java -XX:+PrintCodeCache -XX:+PrintCodeCacheDetails
/>/  CodeCache: size=245760kB used=9110kB max_used=9126kB free=236649kB
/>/     Interpreter=799kB live_nmethods=1607(7267kB) dead_nmethods=11(71kB)
/>/  stubs=77(1515kB) adapters=212(159kB)
/>/     bounds [0x00007f81cbb7c000, 0x00007f81cc47c000, 0x00007f81dab7c000]
/>/     compilation: enabled
/>/
/>/  Code cache entries: (total of #1907)
/>/  nmethods:    #1618    7338kB
/>/      Java:        #1576    7295kB
/>/       Tier 1:    #236    213kB
/>/       Tier 2:    #792    3280kB
/>/       Tier 3:    #358    2349kB
/>/       Tier 4:    #190    1451kB
/>/      Native:    #42    43kB
/>/  runtime-stubs:    #59    44kB
/>/  adapters:    #212    159kB
/>/  buffer blobs:    #12    1467kB
/>/  deopt-stubs:    #1    1kB
/>/  uncommon-traps:    #1    0kB
/>/  others:        #4    2kB
/>/
/>/  nmethod state distribution
/>/      in-use:    #1562    6596kB
/>/      not-entrant:    #45    670kB
/>/      zombie:    #11    71kB
/>/      unloaded:    #0    0kB
/>/
/>/  java -XX:+PrintCodeCache -XX:+PrintCodeCacheDetails -XX:+Verbose
/>/  CodeCache: size=245760kB used=8907kB max_used=8995kB free=236852kB
/>/     Interpreter=799kB live_nmethods=1584(6973kB) dead_nmethods=29(164kB)
/>/  stubs=78(1517kB) adapters=212(159kB)
/>/     bounds [0x00007f4c4bda8000, 0x00007f4c4c688000, 0x00007f4c5ada8000]
/>/     compilation: enabled
/>/
/>/  Code cache entries: (total of #1903)
/>/  nmethods:    #1613    7137kB
/>/      Java:        #1572    7095kB
/>/       Tier 1:    #245    221kB
/>/       Tier 2:    #792    3261kB
/>/       Tier 3:    #343    2238kB
/>/       Tier 4:    #192    1373kB
/>/      Native:    #41    42kB
/>/  runtime-stubs:    #59    44kB
/>/  adapters:    #212    159kB
/>/  buffer blobs:    #13    1469kB
/>/  deopt-stubs:    #1    1kB
/>/  uncommon-traps:    #1    0kB
/>/  others:        #4    2kB
/>/
/>/  nmethod state distribution
/>/      in-use:    #1537    6447kB
/>/      not-entrant:    #47    526kB
/>/      zombie:    #29    164kB
/>/      unloaded:    #0    0kB
/>/
/>/  nmethod size distribution (non-zombie java)
/>/  0 - 512 bytes                           556
/>/  512 - 1024 bytes                        318
/>/  1024 - 1536 bytes                       156
/>/  1536 - 2048 bytes                       109
/>/  2048 - 2560 bytes                       87
/>/  2560 - 3072 bytes                       56
/>/  3072 - 3584 bytes                       40
/>/  3584 - 4096 bytes                       32
/>/  4096 - 4608 bytes                       28
/>/  4608 - 5120 bytes                       31
/>/  5120 - 5632 bytes                       10
/>/  5632 - 6144 bytes                       12
/>/  6144 - 6656 bytes                       8
/>/  6656 - 7168 bytes                       11
/>/  7168 - 7680 bytes                       12
/>/  7680 - 8192 bytes                       14
/>/  8192 - 8704 bytes                       2
/>/  8704 - 9216 bytes                       7
/>/  9216 - 9728 bytes                       6
/>/  9728 - 10240 bytes                      4
/>/  10240 - 10752 bytes                     5
/>/  10752 - 11264 bytes                     7
/>/  11264 - 11776 bytes                     1
/>/  11776 - 12288 bytes                     2
/>/  12288 - 12800 bytes                     1
/>/  12800 - 13312 bytes                     3
/>/  13312 - 13824 bytes                     2
/>/  13824 - 14336 bytes                     3
/>/  14336 - 14848 bytes                     2
/>/  14848 - 15360 bytes                     6
/>/  15360 - 15872 bytes                     5
/>/  15872 - 16384 bytes                     1
/>/  16896 - 17408 bytes                     1
/>/  17408 - 17920 bytes                     1
/>/  17920 - 18432 bytes                     3
/>/  18432 - 18944 bytes                     2
/>/  18944 - 19456 bytes                     2
/>/  19968 - 20480 bytes                     2
/>/  22016 - 22528 bytes                     3
/>/  22528 - 23040 bytes                     1
/>/  23552 - 24064 bytes                     2
/>/  25088 - 25600 bytes                     1
/>/  25600 - 26112 bytes                     2
/>/  26112 - 26624 bytes                     1
/>/  27136 - 27648 bytes                     1
/>/  27648 - 28160 bytes                     1
/>/  28672 - 29184 bytes                     1
/>/  30208 - 30720 bytes                     1
/>/  31744 - 32256 bytes                     1
/>/  35328 - 35840 bytes                     1
/>/  35840 - 36352 bytes                     1
/>/  36864 - 37376 bytes                     1
/>/  37376 - 37888 bytes                     1
/>/  41472 - 41984 bytes                     1
/>/  43520 - 44032 bytes                     1
/>/  47104 - 47616 bytes                     1
/>/  49664 - 50176 bytes                     1
/>/  58368 - 58880 bytes                     1
/>/  nmethod dependency checking time 0.205156
/>/
/>/  java -XX:+PrintCodeCacheOnCompilation
/>/  CodeCache: size=245760kB used=1610kB max_used=1610kB free=244149kB
/>/
/>/  java -XX:PrintCodeCacheAllocation:
/>/  CodeCache allocation:  addr: 0x00007f7ed1190850, size: 1984B
/>/
/>/  Best,
/>/  Albert
/



More information about the hotspot-compiler-dev mailing list