提問
http://stackoverflow.com/questions/40593304/where-to-get-fastdebug-debug-build-of-jdk-8-for-windows
安裝使用
http://lovespss.blog.51cto.com/1907593/535219
下載
https://github.com/alexkasko/openjdk-unofficial-builds/releases
http://download.java.net/jdk7/archive/b142/binaries/
最后
+表示開啟
打印編譯信息的參數(shù)是-XX:+PrintCompilation车胡,但不包括編譯后的代碼。若要看編譯后的代碼照瘾,需要加參數(shù)-XX:+PrintAssembly匈棘,再加上HSDIS插件
-XX:+UnlockExperimentalVMOptions 開啟
-XX:+LogCompilation 開啟日志打印。其打印出來的日志為XML格式析命,而非PrintCompilation簡單的文本輸出主卫,并且這些日志比較大,通常會(huì)到達(dá)幾百M(fèi)B鹃愤。它會(huì)影響正在運(yùn)行的程序(默認(rèn)情況下主要來自日志輸出的影響)
-XX:+PrintOptoAssembly 查看編譯后的代碼
-XX:+PrintCompilation 簇搅、輸出結(jié)果會(huì)提供運(yùn)行時(shí)正在編譯的方法的信息, 翻譯信息http://blog.joda.org/2011/08/printcompilation-jvm-flag.html 輸出的結(jié)果中未包含方法的簽名软吐,如果存在重載方法瘩将,區(qū)分起來則比較困難。
-XX:CompileThreshold=8000 方法或循環(huán) 被標(biāo)記8000 次 則優(yōu)化
-XX:+CITime
倒數(shù)第二
{method}
- this oop: 0x000000001c5712e0
- method holder: 'com/nbugs/logging/ManyThreadTest'
- constants: 0x000000001c570d78 constant pool [80] {0x000000001c570d80} for 'com/nbugs/logging/ManyThreadTest' cache=0x000000001c5a2da8
- access: 0xc1000001 public
- name: 'threadTest'
- signature: '()V'
- max stack: 3
- max locals: 3
- size of params: 1
- method size: 12
- vtable index: 5
- i2i entry: 0x00000000030d5b00
- adapters: AHE@0x000000001cb38468: 0xb0000000 i2c: 0x00000000031e6b20 c2i: 0x00000000031e6c5a c2iUV: 0x00000000031e6c2d
- compiled entry 0x00000000031e6c5a
- code size: 38
- code start: 0x000000001c571278
- code end (excl): 0x000000001c57129e
- method data: 0x0000000026740dc8
- checked ex length: 0
- linenumber start: 0x000000001c57129e
- localvar length: 3
- localvar start: 0x000000001c5712b2
#
# void ( rawptr:BotPTR )
#
#r016 rdx:rdx : parm 0: rawptr:BotPTR
# -- Old rsp -- Framesize: 80 --
#r191 rsp+76: in_preserve
#r190 rsp+72: return address
#r189 rsp+68: in_preserve
#r188 rsp+64: saved fp register
#r187 rsp+60: pad2, stack alignment
#r186 rsp+56: pad2, stack alignment
#r185 rsp+52: Fixed slot 1
#r184 rsp+48: Fixed slot 0
#r203 rsp+44: spill
#r202 rsp+40: spill
#r201 rsp+36: spill
#r200 rsp+32: spill
#r199 rsp+28: outgoing argument
#r198 rsp+24: outgoing argument
#r197 rsp+20: outgoing argument
#r196 rsp+16: outgoing argument
#r195 rsp+12: outgoing argument
#r194 rsp+ 8: outgoing argument
#r193 rsp+ 4: outgoing argument
#r192 rsp+ 0: outgoing argument
#
000 N83: # B1 <- BLOCK HEAD IS JUNK Freq: 1
000 # breakpoint
nop # 15 bytes pad for loops and calls
010 B1: # B6 B2 <- BLOCK HEAD IS JUNK Freq: 1
010 # stack bang (128 bytes)
pushq rbp # Save rbp
subq rsp, #64 # Create frame
01c movl R13, [RDX + #8 (8-bit)] # int
020 movq RBP, [RDX + #16 (8-bit)] # ptr
024 movq RCX, RDX # spill
027 call_leaf,runtime OSR_migration_end
No JVM State Info
#
034 testq RBP, RBP # ptr
037 je,s B6 P=0.001000 C=-1.000000
037
039 B2: # B8 B3 <- B1 Freq: 0.999
039 movl R10, [RBP + #8 (8-bit)] # compressed klass ptr
03d cmpl R10, narrowklass: precise klass com/nbugs/logging/ManyThreadTest: 0x000000001fd79cb0:Constant:exact * # compressed klass ptr
044 jne,us B8 P=0.000001 C=-1.000000
044
046 B3: # B4 <- B2 Freq: 0.998999
046 # checkcastPP of RBP
046
046 B4: # B7 B5 <- B3 B6 Freq: 0.999999
046 movq R10, java/lang/Class:exact * # ptr
050 movl R10, [R10 + #104 (8-bit)] # int ! Field: com/nbugs/logging/ManyThreadTest.sum
054 cmpl R10, #100
058 jge,s B7 P=0.000001 C=-1.000000
058
05a B5: # B5 <- B4 B5 top-of-loop Freq: 1e-035
05a testl rax, [rip + #offset_to_poll_page] # Safepoint: poll for GC # com.nbugs.logging.ManyThreadTest::threadTest @ bci:34 L[0]=RBP L[1]=R13 L[2]=_
# OopMap{rbp=Oop off=90}
060 jmp,s B5
060
062 B6: # B4 <- B1 Freq: 0.000999987
062 xorl RBP, RBP # ptr
064 jmp,s B4
064
066 B7: # N83 <- B4 Freq: 1.01328e-006
066 movl RDX, #-122 # int
06b movl [rsp + #32], R13 # spill
nop # 3 bytes pad for loops and calls
073 call,static wrapper for: uncommon_trap(reason='predicate' action='maybe_recompile')
# com.nbugs.logging.ManyThreadTest::threadTest @ bci:26 L[0]=RBP L[1]=rsp + #32 L[2]=_
# OopMap{rbp=Oop off=120}
078 int3 # ShouldNotReachHere
078
079 B8: # N83 <- B2 Freq: 9.99e-007
079 movl RDX, #-99 # int
07e movl [rsp + #32], R13 # spill
083 call,static wrapper for: uncommon_trap(reason='constraint' action='reinterpret')
# com.nbugs.logging.ManyThreadTest::threadTest @ bci:26 L[0]=RBP L[1]=rsp + #32 L[2]=_
# OopMap{rbp=Oop off=136}
088 int3 # ShouldNotReachHere
088