hotspotコトハジメ
TRANSCRIPT
![Page 1: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/1.jpg)
末永 恭正 @YaSuenag
![Page 2: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/2.jpg)
今日はGCの話をあまりしません!他の方の資料等をご覧ください…
OracleとJavaは、Oracle Corporation及びその子会社、関連会社の米国及びその他の国における登録商標です。文中の社名、商品名等は各社の商標または登録商標である場合があります。本資料の実装確認はOpenJDK8 8u-dev(HotSpot rev. 7164:bf68e15dc8fe)で行っています。
![Page 3: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/3.jpg)
ハードウェアをちょっと気にしてHotSpotを気持ちよく動かしてあげよう!
※AMD64 Linuxを中心にお話しします
![Page 4: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/4.jpg)
•
•
•
•
•
http://icedtea.classpath.org/wiki/HeapStats/jp
![Page 5: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/5.jpg)
![Page 6: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/6.jpg)
•
•
•
•
•
•
•
•
![Page 7: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/7.jpg)
•
•
•
•
•
•
•
•
![Page 8: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/8.jpg)
$ java -versionopenjdk version "1.8.0_31"OpenJDK Runtime Environment (build 1.8.0_31-b13)OpenJDK 64-Bit Server VM (build 25.31-b07, mixed mode)
$ java -versionjava version "1.8.0"Java(TM) SE Runtime Environment (build 1.8.0-b132)Java HotSpot(TM) Client VM (build 25.0-b70, mixed mode)
![Page 9: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/9.jpg)
•
•
•
•
•
•
•
•
• http://docs.oracle.com/javase/jp/8/technotes/guides/vm/index.html
![Page 10: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/10.jpg)
•
•
• http://otndnld.oracle.co.jp/ondemand/javaday2014/pdf/C
2-JavaDay-304328.pdf
![Page 11: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/11.jpg)
•
•
• http://docs.oracle.com/javase/jp/8/technotes/guides/vm/s
erver-class.html
注: Java SE 6の場合、server-classマシンとは、少なくとも2つのCPU
と、最少でも2Gバイトの物理メモリーを備えているマシンを指します。
![Page 12: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/12.jpg)
![Page 13: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/13.jpg)
•
•
•
•
![Page 14: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/14.jpg)
•
•
•
•
•
•
![Page 15: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/15.jpg)
•
•
•
•
•
•
• MetaspaceはGC対象ではありません!
•
•
ちょっとだけ
![Page 16: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/16.jpg)
•
•
• http://www.slideshare.net/YujiKubota/concurrent-
marksweep-garbage-collection
![Page 18: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/18.jpg)
• CodeCacheはGCでクリアされません!
•
•
•
ちょっとだけ
Java HotSpot(TM) 64-Bit Server VM warning: CodeCache is full. Compiler has been disabled.Java HotSpot(TM) 64-Bit Server VM warning: Try increasing the code cache size using -XX:ReservedCodeCacheSize=CodeCache: size=2496Kb used=1955Kb max_used=1969Kb free=540Kbbounds [0x00007f50c844b000, 0x00007f50c86bb000, 0x00007f50c86bb000]total_blobs=578 nmethods=353 adapters=139compilation: disabled (not enough contiguous free space left)
![Page 19: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/19.jpg)
•
•
•
•
![Page 20: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/20.jpg)
•
•
• http://www.oracle.com/webfolder/technetwork/jp/javama
gazine/Java-JA13-Architect-evans.pdf
![Page 21: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/21.jpg)
![Page 22: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/22.jpg)
•
•
•
•
$ ulimit -v 102400$ /usr/local/jdk1.8.0/bin/java -version## There is insufficient memory for the Java Runtime Environment to continue.# Native memory allocation (malloc) failed to allocate 80 bytes for AllocateHeap# An error report file with more information is saved as:# /home/xxx/hs_err_pid8664.log
![Page 23: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/23.jpg)
•
•
•
•
• http://www.oracle.com/technetwork/jp/articles/java/compressedoops-
427542-ja.html
•
•
•
![Page 24: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/24.jpg)
•
•
•
•
•
•
•
![Page 25: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/25.jpg)
•
•
•
•
•
•
![Page 26: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/26.jpg)
•
•
•
•
# cat /sys/kernel/mm/transparent_hugepage/enabled
always [madvise] never
![Page 27: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/27.jpg)
import java.nio.*;
import java.nio.file.*;
import javax.crypto.*;
import javax.crypto.spec.*;
import java.security.*;
public class AESTest{
public static void main(String[] args) throws Exception{
Key key = new SecretKeySpec("passwordpassword".getBytes(), "AES");
Cipher cipher = Cipher.getInstance("AES/CBC/NoPadding");
cipher.init(Cipher.ENCRYPT_MODE, key);
byte[] plain = Files.readAllBytes(Paths.get(args[0]));
long start = System.currentTimeMillis();
cipher.doFinal(plain);
long end = System.currentTimeMillis();
long elapsedTime = end - start;
System.out.println("Elapsed time: " + elapsedTime + " ms");
}
}
![Page 28: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/28.jpg)
$ java -Xms2g -Xmx2g AESTest /tmp/test.dat
Elapsed time: 1654 ms$ java -Xms2g -Xmx2g -XX:+UseTransparentHugePages AESTest /tmp/test.dat
Elapsed time: 1613 ms
約40msの差!
ソフトウェア環境:• Fedora21 x86_64
• kernel-3.18.7-200.fc21.x86_64• glibc-2.20-8.fc21.x86_64
• java-1.8.0-openjdk-1.8.0.31-5.b13.fc21.x86_64
ハードウェア環境:• CPU:Intel Core i5 2500T• MB:GIGABYTE GA-H67A-UD3H-B3• メモリ:DDR3 1333MHz 2GB×2
テストデータ:• /tmp/test.dat
• /dev/urandomから500MBを/tmp配下にコピー• /tmpはtmpfs
![Page 29: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/29.jpg)
$ perf stat -e dTLB-load-misses,dTLB-store-misses java -Xms2g -Xmx2g AESTest /tmp/test.datElapsed time: 1654 ms
Performance counter stats for 'java -Xms2g -Xmx2g AESTest /tmp/test.dat':
826,055 dTLB-load-misses1,648,456 dTLB-store-misses
2.300445236 seconds time elapsed
$ perf stat -e dTLB-load-misses,dTLB-store-misses java -Xms2g -Xmx2g -XX:+UseTransparentHugePages AESTest /tmp/test.datElapsed time: 1613 ms
Performance counter stats for 'java -Xms2g -Xmx2g -XX:+UseTransparentHugePages AESTest /tmp/test.dat':
623,795 dTLB-load-misses576,097 dTLB-store-misses
2.165985041 seconds time elapsed
TLBミスヒットが激減!
![Page 30: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/30.jpg)
•
•
•
•
•
•
![Page 31: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/31.jpg)
![Page 32: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/32.jpg)
•
•
•
![Page 33: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/33.jpg)
論理プロセッサ数が8以下のとき
論理プロセッサ数が9以上のとき
論理プロセッサ数と同数
8 +5 <論理プロセッサ数 > −8
8
![Page 35: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/35.jpg)
•
•
•
•
•
•
•
•
![Page 36: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/36.jpg)
•
• http://openjdk.java.net/projects/code-tools/jol/
![Page 37: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/37.jpg)
import sun.misc.Contended;
@Contended
public class Test{
public int val1;
public int val2;
public int val3;
public int val4;
public int val5;
}
![Page 38: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/38.jpg)
$ java -cp jol-cli-0.3.1-full.jar:. \org.openjdk.jol.Main internals Test
:Test object internals:OFFSET SIZE TYPE DESCRIPTION VALUE
:12 4 int Test.val1 016 4 int Test.val2 020 4 int Test.val3 024 4 int Test.val4 028 4 int Test.val5 0
Instance size: 32 bytes (reported by Instrumentation API)Space losses: 0 bytes internal + 0 bytes external = 0 bytes total
$ java -XX:-RestrictContended -cp jol-cli-0.3.1-full.jar:. \org.openjdk.jol.Main internals Test
:Test object internals:OFFSET SIZE TYPE DESCRIPTION VALUE
:
12 128 (alignment/padding gap) N/A140 4 int Test.val1 0144 4 int Test.val2 0148 4 int Test.val3 0152 4 int Test.val4 0156 4 int Test.val5 0
160 128 (loss due to the next object alignment)
Instance size: 288 bytes (reported by Instrumentation API)Space losses: 128 bytes internal + 128 bytes external = 256 bytes total
@Contended無効 @Contended有効
ソフトウェア環境:• Fedora21 x86_64
• kernel-3.18.7-200.fc21.x86_64• glibc-2.20-8.fc21.x86_64
• java-1.8.0-openjdk-1.8.0.31-5.b13.fc21.x86_64
![Page 39: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/39.jpg)
import sun.misc.Contended;
public class Test2{
@Contended("group")
public int val1;
@Contended("group")
public int val2;
public int val3;
public int val4;
@Contended
public int val5;
}
![Page 40: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/40.jpg)
$ java -cp jol-cli-0.3.1-full.jar:. \org.openjdk.jol.Main internals Test2
:Test2 object internals:OFFSET SIZE TYPE DESCRIPTION VALUE
:12 4 int Test2.val1 016 4 int Test2.val2 020 4 int Test2.val3 024 4 int Test2.val4 028 4 int Test2.val5 0
Instance size: 32 bytes (reported by Instrumentation API)Space losses: 0 bytes internal + 0 bytes external = 0 bytes total
$ java -XX:-RestrictContended -cp jol-cli-0.3.1-full.jar:. \org.openjdk.jol.Main internals Test2
:Test2 object internals:OFFSET SIZE TYPE DESCRIPTION VALUE
:12 4 int Test2.val3 016 4 int Test2.val4 0
20 128 (alignment/padding gap) N/A148 4 int Test2.val5 0152 128 (alignment/padding gap) N/A280 4 int Test2.val1 0284 4 int Test2.val2 0288 128 (loss due to the next object alignment)
Instance size: 416 bytes (reported by Instrumentation API)Space losses: 256 bytes internal + 128 bytes external = 384 bytes total
@Contended無効 @Contended有効
ソフトウェア環境:• Fedora21 x86_64
• kernel-3.18.7-200.fc21.x86_64• glibc-2.20-8.fc21.x86_64
• java-1.8.0-openjdk-1.8.0.31-5.b13.fc21.x86_64
![Page 41: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/41.jpg)
•
•
• http://www.oracle.com/technetwork/java/faq-sun-packages-
142232.html
sun.miscパッケージです!
![Page 42: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/42.jpg)
![Page 43: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/43.jpg)
•
•
•
•
•
•
•
•
•
![Page 44: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/44.jpg)
UseSSE
UseAVX
UseAES
UseCLMUL
UseXmmLoadAndClearUpper UseXmmRegToRegMoveAll
UseXMMForArrayCopy
UseUnalignedLoadStores
UseCountLeadingZerosInstruction
UseCountTrailingZerosInstruction
UseBMI1Instructions
UseBMI2Instructions
UsePopCountInstructionUseFastStosb
AllocatePrefetchInstr
UseRTMLocking
UseRTMForStackLocks
UseSSE42Intrinsics
UseRTMXendForLockBusy
![Page 45: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/45.jpg)
import java.nio.*;
import java.nio.file.*;
import javax.crypto.*;
import javax.crypto.spec.*;
import java.security.*;
public class AESTest{
public static void main(String[] args) throws Exception{
Key key = new SecretKeySpec("passwordpassword".getBytes(), "AES");
Cipher cipher = Cipher.getInstance("AES/CBC/NoPadding");
cipher.init(Cipher.ENCRYPT_MODE, key);
byte[] plain = Files.readAllBytes(Paths.get(args[0]));
long start = System.currentTimeMillis();
cipher.doFinal(plain);
long end = System.currentTimeMillis();
long elapsedTime = end - start;
System.out.println("Elapsed time: " + elapsedTime + " ms");
}
}
![Page 46: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/46.jpg)
$ java -Xms2g -Xmx2g AESTest /tmp/test.dat
Elapsed time: 1669 ms$ java -Xms2g -Xmx2g -XX:-UseAES AESTest /tmp/test.dat
Elapsed time: 4651 ms
ソフトウェア環境:• Fedora21 x86_64
• kernel-3.18.7-200.fc21.x86_64• glibc-2.20-8.fc21.x86_64
• java-1.8.0-openjdk-1.8.0.31-5.b13.fc21.x86_64
約3秒差!
テストデータ:• /tmp/test.dat
• /dev/urandomから500MBを/tmp配下にコピー• /tmpはtmpfs
ハードウェア環境:• CPU:Intel Core i5 2500T• MB:GIGABYTE GA-H67A-UD3H-B3• メモリ:DDR3 1333MHz 2GB×2
![Page 47: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/47.jpg)
$ java -XX:+UnlockDiagnosticVMOptions -XX:+PrintIntrinsics AESTest /tmp/test.dat@ 64 com.sun.crypto.provider.AESCrypt::encryptBlock (953 bytes) (intrinsic)@ 80 java.lang.System::arraycopy (0 bytes) (intrinsic)
Elapsed time: 1669 ms
$ java -XX:+UnlockDiagnosticVMOptions -XX:+PrintIntrinsics -XX:-UseAES AESTest /tmp/test.dat@ 80 java.lang.System::arraycopy (0 bytes) (intrinsic)
Elapsed time: 4651 ms
![Page 48: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/48.jpg)
•
•
• http://www.intel.co.jp/content/www/jp/ja/architecture-and-
technology/advanced-encryption-standard--aes-/data-protection-aes-
general-technology.html
•
•
•
•
→AES-NI命令セットを活用した機械語がJITで適用された!
![Page 49: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/49.jpg)
•
•
•
•
•
•
•
•
![Page 50: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/50.jpg)
![Page 51: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/51.jpg)
![Page 52: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/52.jpg)
•
• http://openjdk.java.net/projects/sumatra/
• https://wiki.openjdk.java.net/display/Sumatra/Main
•
•
•
•
•
![Page 53: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/53.jpg)
https://wiki.openjdk.java.net/display/Sumatra/Standalone+Sumatra+Stream+API+Offload+Demo
final int length = 8;
int[] ina = new int[length];
int[] inb = new int[length];
int[] out = new int[length];
// Initialize the input arrays - this is offloadable
IntStream.range(0, length).parallel().forEach(p -> {
ina[p] = 1;
inb[p] = 2;
});
// Sum each pair of elements into out[] - this is offloadable
IntStream.range(0, length).parallel().forEach(p -> {
out[p] = ina[p] + inb[p];
});
![Page 54: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/54.jpg)
We cannot speak for Project Sumatra or AMD. Project Graal decided to temporarily
remove the compiler's GPU support, because the original contributors
indicated to no longer maintain the code. We are still investigating outside
the main branch a new version of compilation support for heterogenous
architectures for Graal. If you want to compile and run a Graal version with GPU support in
the meantime, use this revision: http://hg.openjdk.java.net/graal/graal/rev/91fee1fab96d
<http://hg.openjdk.java.net/graal/graal/rev/91fee1fab96d>.
http://mail.openjdk.java.net/pipermail/sumatra-dev/2015-February/000308.html
![Page 55: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/55.jpg)
HSA/PTXサポート削除
GPUを使いたければこのタグを使用→
![Page 56: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/56.jpg)
![Page 57: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/57.jpg)
•
•
•
•
•
•
• ツールの動作を知ることがHotSpotを知る一番の近道!
![Page 58: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/58.jpg)
•
•
• http://www.slideshare.net/YaSuenag/serviceability-tools
![Page 59: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/59.jpg)
•
•
• http://www.oracle.com/webfolder/technetwork/jp/javama
gazine/Java-JA12-architect-bajaj.pdf
![Page 60: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/60.jpg)
HotSpotがご機嫌ナナメになったら取るべき情報は取っておこう!
![Page 61: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/61.jpg)
•
•
• http://www.slideshare.net/agetsuma/java-34815905
![Page 62: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/62.jpg)
![Page 63: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/63.jpg)
•
•
•
![Page 64: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/64.jpg)
• だいたい
•
•
•
• クラッシュ解析の最初の取っ掛かり!
![Page 65: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/65.jpg)
•
•
•
•
Current thread (0x00007fb944008800): JavaThread "main" [_thread_in_native, id=10054, stack(0x00007fb9486b0000,0x00007fb9487b1000)]
siginfo: si_signo: 11 (SIGSEGV), si_code: 1 (SEGV_MAPERR), si_addr: 0x0000000000000000
![Page 66: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/66.jpg)
•
•
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C [libsegv.so+0x6a0] Java_NativeSEGV_doSEGV+0x18j NativeSEGV.doSEGV()V+0j NativeSEGV.main([Ljava/lang/String;)V+0v ~StubRoutines::call_stubV [libjvm.so+0x681a56] JavaCalls::call_helper(JavaValue*, methodHandle*, JavaCallArguments*, Thread*)+0x1056V [libjvm.so+0x6c36c2] jni_invoke_static(JNIEnv_*, JavaValue*, _jobject*, JNICallType, _jmethodID*, JNI_ArgumentPusher*, Thread*)+0x362V [libjvm.so+0x6e00ca] jni_CallStaticVoidMethod+0x17aC [libjli.so+0x7bcc] JavaMain+0x80cC [libpthread.so.0+0x752a]
![Page 68: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/68.jpg)
•
•
•
•
•
•
:compile java/lang/invoke/MethodHandle <clinit> ()V -1 4 inline 1 0 -1 java/lang/invoke/MethodHandle <clinit> ()V
![Page 69: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/69.jpg)
•
Current CompileTask:C2: 13427 2 !b 4 java.lang.invoke.MethodHandle::<clinit> (75 bytes)
![Page 70: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/70.jpg)
•
•
•
•
•
•
![Page 72: HotSpotコトハジメ](https://reader030.vdocuments.pub/reader030/viewer/2022013111/55a6feac1a28abf25e8b456c/html5/thumbnails/72.jpg)