1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158
| "C:\Program Files\Java\jdk1.8.0_152\bin\javap.exe" -v -c com.sunld.thread.lock.TestSynchronized Classfile /D:/workspace/learning/target/classes/com/sunld/thread/lock/TestSynchronized.class Last modified 2020-5-30; size 834 bytes MD5 checksum 9806782e622d7e5e193f3d1b5b8cf61e Compiled from "TestSynchronized.java" public class com.sunld.thread.lock.TestSynchronized minor version: 0 major version: 52 flags: ACC_PUBLIC, ACC_SUPER Constant pool: #1 = Methodref #3.#25 // java/lang/Object."<init>":()V #2 = Class #26 // com/sunld/thread/lock/TestSynchronized #3 = Class #27 // java/lang/Object #4 = Utf8 <init> #5 = Utf8 ()V #6 = Utf8 Code #7 = Utf8 LineNumberTable #8 = Utf8 LocalVariableTable #9 = Utf8 this #10 = Utf8 Lcom/sunld/thread/lock/TestSynchronized; #11 = Utf8 test1 #12 = Utf8 test2 #13 = Utf8 test3 #14 = Utf8 StackMapTable #15 = Class #26 // com/sunld/thread/lock/TestSynchronized #16 = Class #27 // java/lang/Object #17 = Class #28 // java/lang/Throwable #18 = Utf8 test4 #19 = Utf8 main #20 = Utf8 ([Ljava/lang/String;)V #21 = Utf8 args #22 = Utf8 [Ljava/lang/String; #23 = Utf8 SourceFile #24 = Utf8 TestSynchronized.java #25 = NameAndType #4:#5 // "<init>":()V #26 = Utf8 com/sunld/thread/lock/TestSynchronized #27 = Utf8 java/lang/Object #28 = Utf8 java/lang/Throwable { public com.sunld.thread.lock.TestSynchronized(); descriptor: ()V flags: ACC_PUBLIC Code: stack=1, locals=1, args_size=1 0: aload_0 1: invokespecial #1 // Method java/lang/Object."<init>":()V 4: return LineNumberTable: line 9: 0 LocalVariableTable: Start Length Slot Name Signature 0 5 0 this Lcom/sunld/thread/lock/TestSynchronized;
public static synchronized void test1(); descriptor: ()V flags: ACC_PUBLIC, ACC_STATIC, ACC_SYNCHRONIZED Code: stack=0, locals=0, args_size=0 0: return LineNumberTable: line 13: 0
public synchronized void test2(); descriptor: ()V flags: ACC_PUBLIC, ACC_SYNCHRONIZED Code: stack=0, locals=1, args_size=1 0: return LineNumberTable: line 17: 0 LocalVariableTable: Start Length Slot Name Signature 0 1 0 this Lcom/sunld/thread/lock/TestSynchronized;
public void test3(); descriptor: ()V flags: ACC_PUBLIC Code: stack=2, locals=3, args_size=1 0: aload_0 1: dup 2: astore_1 3: monitorenter 4: aload_1 5: monitorexit 6: goto 14 9: astore_2 10: aload_1 11: monitorexit 12: aload_2 13: athrow 14: return Exception table: from to target type 4 6 9 any 9 12 9 any LineNumberTable: line 20: 0 line 22: 4 line 23: 14 LocalVariableTable: Start Length Slot Name Signature 0 15 0 this Lcom/sunld/thread/lock/TestSynchronized; StackMapTable: number_of_entries = 2 frame_type = 255 offset_delta = 9 locals = [ class com/sunld/thread/lock/TestSynchronized, class java/lang/Object ] stack = [ class java/lang/Throwable ] frame_type = 250 offset_delta = 4
public static void test4(); descriptor: ()V flags: ACC_PUBLIC, ACC_STATIC Code: stack=2, locals=2, args_size=0 0: ldc #2 // class com/sunld/thread/lock/TestSynchronized 2: dup 3: astore_0 4: monitorenter 5: aload_0 6: monitorexit 7: goto 15 10: astore_1 11: aload_0 12: monitorexit 13: aload_1 14: athrow 15: return Exception table: from to target type 5 7 10 any 10 13 10 any LineNumberTable: line 26: 0 line 28: 5 line 29: 15 StackMapTable: number_of_entries = 2 frame_type = 255 offset_delta = 10 locals = [ class java/lang/Object ] stack = [ class java/lang/Throwable ] frame_type = 250 offset_delta = 4
public static void main(java.lang.String[]); descriptor: ([Ljava/lang/String;)V flags: ACC_PUBLIC, ACC_STATIC Code: stack=0, locals=1, args_size=1 0: return LineNumberTable: line 33: 0 LocalVariableTable: Start Length Slot Name Signature 0 1 0 args [Ljava/lang/String; } SourceFile: "TestSynchronized.java"
|