When all of the following conditions are met:
1. Build on old glibc (without `INCLUDE_CPU_FEATURE_ACTIVE`)
2. Pre-set GLIBC_TUNABLES (such as `GLIBC_TUNABLES=glibc.pthread.rseq=0` which the fix forJDK-8349071 uses).
3. Using `-XX:CPUFeatures=generic` or other CPU restriction.
VM will crash with a message like this:
```
Error occurred during initialization of VM
internal error: GLIBC_TUNABLES=:glibc.cpu.hwcaps=,-AVX,-FMA,-AVX2,-BMI1,-BMI2,-ERMS,-LZCNT,-SSSE3,-POPCNT,-SSE4_1,-SSE4_2,-AVX512F,-AVX512CD,-AVX512BW,-AVX512DQ,-AVX512VL,-MOVBE,-XSAVE,-OSXSAVE,-HTT failed and HOTSPOT_GLIBC_TUNABLES_REEXEC is set
```
Reproducer (to get old glibc use CentOS 7 or Ubuntu 18.04, for example):
```
export GLIBC_TUNABLES=glibc.pthread.rseq=0
JAVA_HOME=$PWD/build/linux-x86_64-server-release/jdk
$JAVA_HOME/bin/java -XX:CPUFeatures=generic -XX:+ShowCPUFeatures -version
```
1. Build on old glibc (without `INCLUDE_CPU_FEATURE_ACTIVE`)
2. Pre-set GLIBC_TUNABLES (such as `GLIBC_TUNABLES=glibc.pthread.rseq=0` which the fix for
3. Using `-XX:CPUFeatures=generic` or other CPU restriction.
VM will crash with a message like this:
```
Error occurred during initialization of VM
internal error: GLIBC_TUNABLES=:glibc.cpu.hwcaps=,-AVX,-FMA,-AVX2,-BMI1,-BMI2,-ERMS,-LZCNT,-SSSE3,-POPCNT,-SSE4_1,-SSE4_2,-AVX512F,-AVX512CD,-AVX512BW,-AVX512DQ,-AVX512VL,-MOVBE,-XSAVE,-OSXSAVE,-HTT failed and HOTSPOT_GLIBC_TUNABLES_REEXEC is set
```
Reproducer (to get old glibc use CentOS 7 or Ubuntu 18.04, for example):
```
export GLIBC_TUNABLES=glibc.pthread.rseq=0
JAVA_HOME=$PWD/build/linux-x86_64-server-release/jdk
$JAVA_HOME/bin/java -XX:CPUFeatures=generic -XX:+ShowCPUFeatures -version
```
- relates to
-
JDK-8349071 [CRaC] Disable rseq in libc on checkpoint and restore
-
- Resolved
-
- links to
-
Commit(crac) openjdk/crac/6b024464
-
Review(crac) openjdk/crac/200