JDK-7191817 : -XX:+UseSerialGC -XX:+UseLargePages crashes with SIGFPE on MacOS X
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: hs23.1
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • OS: os_x
  • CPU: generic
  • Submitted: 2012-08-15
  • Updated: 2014-07-02
  • Resolved: 2012-10-26
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 7 JDK 8 Other
7u60Fixed 8Fixed hs25Fixed
Related Reports
Duplicate :  
Description
The (truncated) "Problem Report" has interesting info in it:

Process:         java [35442]
Path:            /net/frankenputer/work/local/jdk/1.8.0/macosx-x64/Contents/Home/bin/java
Identifier:      java
Version:         1.0 (1.0)
Code Type:       X86-64 (Native)
Parent Process:  bash [348]

Date/Time:       2012-08-15 17:05:30.030 -0600
OS Version:      Mac OS X 10.6.8 (10K549)
Report Version:  6

Interval Since Last Report:          633697 sec
Crashes Since Last Report:           2
Per-App Crashes Since Last Report:   2
Anonymous UUID:                      C45700BE-AFBE-4A62-BC91-4DCCEA05FEF2

Exception Type:  EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Crashed Thread:  2

Application Specific Information:
abort() called

Thread 0:  Dispatch queue: com.apple.main-thread
0   libSystem.B.dylib             	0x00007fff85208d7a mach_msg_trap + 10
1   libSystem.B.dylib             	0x00007fff852093ed mach_msg + 59
2   com.apple.CoreFoundation      	0x00007fff83c8d902 __CFRunLoopRun + 1698
3   com.apple.CoreFoundation      	0x00007fff83c8cd8f CFRunLoopRunSpecific + 575
4   java                          	0x00000001186f24b1 CreateExecutionEnvironment + 871
5   java                          	0x00000001186ecc9c JLI_Launch + 1952
6   java                          	0x00000001186f280e main + 101
7   java                          	0x00000001186ec4f4 start + 52

Thread 1:
0   libSystem.B.dylib             	0x00007fff85243a6a __semwait_signal + 10
1   libSystem.B.dylib             	0x00007fff8526a896 pthread_join + 844
2   java                          	0x00000001186f1ab1 ContinueInNewThread0 + 102
3   java                          	0x00000001186ed907 ContinueInNewThread + 201
4   java                          	0x00000001186f1814 JVMInit + 251
5   java                          	0x00000001186ed685 JLI_Launch + 4489
6   java                          	0x00000001186f280e main + 101
7   java                          	0x00000001186f2143 apple_main + 92
8   libSystem.B.dylib             	0x00007fff85241fd6 _pthread_start + 331
9   libSystem.B.dylib             	0x00007fff85241e89 thread_start + 13

Thread 2 Crashed:
0   libSystem.B.dylib             	0x00007fff8527b9ce __semwait_signal_nocancel + 10
1   libSystem.B.dylib             	0x00007fff8527b8d0 nanosleep$NOCANCEL + 129
2   libSystem.B.dylib             	0x00007fff852d83ce usleep$NOCANCEL + 57
3   libSystem.B.dylib             	0x00007fff852f7a00 abort + 93
4   libjvm.dylib                  	0x00000001013d884d os::abort(bool) + 25
5   libjvm.dylib                  	0x00000001014cb0f8 VMError::report_and_die() + 2316
6   libjvm.dylib                  	0x00000001013da0df JVM_handle_bsd_signal + 1073
7   libSystem.B.dylib             	0x00007fff852691ba _sigtramp + 26
8   libjvm.dylib                  	0x0000000101245dfb lcm(unsigned long, unsigned long) + 31
9   libjvm.dylib                  	0x0000000101184aaa GenCollectorPolicy::initialize_flags() + 28
10  libjvm.dylib                  	0x0000000101185464 TwoGenerationCollectorPolicy::initialize_flags() + 20
11  libjvm.dylib                  	0x000000010117bbc0 GenCollectorPolicy::initialize_all() + 20
12  libjvm.dylib                  	0x00000001014b0fb9 Universe::initialize_heap() + 309
13  libjvm.dylib                  	0x00000001014b136f universe_init() + 240
14  libjvm.dylib                  	0x0000000101265df2 init_globals() + 76
15  libjvm.dylib                  	0x00000001014a261b Threads::create_vm(JavaVMInitArgs*, bool*) + 459
16  libjvm.dylib                  	0x00000001012b97c3 JNI_CreateJavaVM + 98
17  java                          	0x00000001186eda55 JavaMain + 308
18  libSystem.B.dylib             	0x00007fff85241fd6 _pthread_start + 331
19  libSystem.B.dylib             	0x00007fff85241e89 thread_start + 13

Thread 2 crashed with X86 Thread State (64-bit):
  rax: 0x000000000000003c  rbx: 0x00000001003002a0  rcx: 0x0000000100300258  rdx: 0x0000000000000001
  rdi: 0x0000000000000c03  rsi: 0x0000000000000000  rbp: 0x0000000100300290  rsp: 0x0000000100300258
   r8: 0x0000000000000000   r9: 0x0000000000989680  r10: 0x0000000000000001  r11: 0x0000000000000246
  r12: 0x0000000000000000  r13: 0x0000000000001903  r14: 0x0000000100300310  r15: 0x00000001013dc09c
  rip: 0x00007fff8527b9ce  rfl: 0x0000000000000247  cr2: 0x00007fff709264a8

Binary Images:
       0x1000b5000 -        0x1000bdfff +libverify.dylib ??? (???) <490F2042-8B4B-3F5A-8C77-327B9F25D07C> /net/frankenputer/work/local/jdk/1.8.0/macosx-x64/Contents/Home/jre/lib/libverify.dylib
       0x1000c2000 -        0x1000e3ff7 +libjava.dylib ??? (???) <DB1F1B27-EA1C-3A3D-A3A4-9BD82DA6B36B> /net/frankenputer/work/local/jdk/1.8.0/macosx-x64/Contents/Home/jre/lib/libjava.dylib
       0x100303000 -        0x100308fff +libzip.dylib ??? (???) <35B5063B-4F9C-3BDF-9FFF-E8D57B4A59F3> /net/frankenputer/work/local/jdk/1.8.0/macosx-x64/Contents/Home/jre/lib/libzip.dylib
       0x101000000 -        0x1016bafff +libjvm.dylib ??? (???) <AEE54B75-A0BA-3A6C-89F0-C6763E32ED97> /net/frankenputer/work/local/jdk/1.8.0/macosx-x64/Contents/Home/jre/lib/server/libjvm.dylib
       0x1186eb000 -        0x1186fbff7 +java 1.0 (1.0) <AAA5E55A-95D9-36F3-A37E-0CB59B76FF75> /net/frankenputer/work/local/jdk/1.8.0/macosx-x64/Contents/Home/bin/java
    0x7fff5fc00000 -     0x7fff5fc3bdef  dyld 132.1 (???) <B536F2F1-9DF1-3B6C-1C2C-9075EA219A06> /usr/lib/dyld
    0x7fff80139000 -     0x7fff80148fff  com.apple.NetFS 3.2.2 (3.2.2) <7CCBD70E-BF31-A7A7-DB98-230687773145> /System/Library/Frameworks/NetFS.framework/Versions/A/NetFS
    0x7fff8065a000 -     0x7fff8068bfff  libGLImage.dylib ??? (???) <562565E1-AA65-FE96-13FF-437410C886D0> /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGLImage.dylib
    0x7fff807a9000 -     0x7fff807bdfff  libGL.dylib ??? (???) <2ECE3B0F-39E1-3938-BF27-7205C6D0358B> /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib
    0x7fff8083b000 -     0x7fff80876fff  com.apple.AE 496.5 (496.5) <208DF391-4DE6-81ED-C697-14A2930D1BC6> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/AE.framework/Versions/A/AE
    0x7fff8089b000 -     0x7fff8089cfff  liblangid.dylib ??? (???) <EA4D1607-2BD5-2EE2-2A3B-632EEE5A444D> /usr/lib/liblangid.dylib
    0x7fff808dc000 -     0x7fff808dfff7  libCoreVMClient.dylib ??? (???) <75819794-3B7A-8944-D004-7EA6DD7CE836> /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libCoreVMClient.dylib
    0x7fff808e5000 -     0x7fff808f6ff7  libz.1.dylib 1.2.3 (compatibility 1.0.0) <FB5EE53A-0534-0FFA-B2ED-486609433717> /usr/lib/libz.1.dylib
    0x7fff808f7000 -     0x7fff80c2bfef  com.apple.CoreServices.CarbonCore 861.39 (861.39) <1386A24D-DD15-5903-057E-4A224FAF580B> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/CarbonCore.framework/Versions/A/CarbonCore
    0x7fff80c2c000 -     0x7fff80c37ff7  com.apple.speech.recognition.framework 3.11.1 (3.11.1) <F0DDF27E-DB55-07CE-E548-C62095BE8167> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/SpeechRecognition.framework/Versions/A/SpeechRecognition
    0x7fff80c38000 -     0x7fff80cc8fff  com.apple.SearchKit 1.3.0 (1.3.0) <4175DC31-1506-228A-08FD-C704AC9DF642> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/SearchKit.framework/Versions/A/SearchKit
    0x7fff80d7e000 -     0x7fff80d7eff7  com.apple.CoreServices 44 (44) <DC7400FB-851E-7B8A-5BF6-6F50094302FB> /System/Library/Frameworks/CoreServices.framework/Versions/A/CoreServices
    0x7fff80e1c000 -     0x7fff80e30ff7  com.apple.speech.synthesis.framework 3.10.35 (3.10.35) <621B7415-A0B9-07A7-F313-36BEEDD7B132> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/SpeechSynthesis.framework/Versions/A/SpeechSynthesis
    0x7fff80e3d000 -     0x7fff80e44fff  com.apple.OpenDirectory 10.6 (10.6) <4200CFB0-DBA1-62B8-7C7C-91446D89551F> /System/Library/Frameworks/OpenDirectory.framework/Versions/A/OpenDirectory
    0x7fff80e54000 -     0x7fff80e55ff7  com.apple.TrustEvaluationAgent 1.1 (1) <51867586-1C71-AE37-EAAD-535A58DD3550> /System/Library/PrivateFrameworks/TrustEvaluationAgent.framework/Versions/A/TrustEvaluationAgent
    0x7fff80e59000 -     0x7fff80eaffff  libTIFF.dylib ??? (???) <31FA0318-105B-9E11-B4D4-246BFD5B18E1> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libTIFF.dylib
    0x7fff80eb0000 -     0x7fff80ef9fef  libGLU.dylib ??? (???) <B0F4CA55-445F-E901-0FCF-47B3B4BAE6E2> /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGLU.dylib
    0x7fff80efa000 -     0x7fff80f46fff  libauto.dylib ??? (???) <F7221B46-DC4F-3153-CE61-7F52C8C293CF> /usr/lib/libauto.dylib
    0x7fff8145c000 -     0x7fff8147dfe7  libPng.dylib ??? (???) <A6BF1360-1B23-78BD-12EF-E4A5753EEB76> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libPng.dylib
    0x7fff8167d000 -     0x7fff816d0ff7  com.apple.HIServices 1.8.3 (???) <F6E0C7A7-C11D-0096-4DDA-2C77793AA6CD> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/HIServices.framework/Versions/A/HIServices
    0x7fff816d1000 -     0x7fff816f8ff7  libJPEG.dylib ??? (???) <32EDAB18-08ED-B31A-D2BD-12EFFE60D83C> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libJPEG.dylib
    0x7fff816f9000 -     0x7fff816f9ff7  com.apple.Accelerate.vecLib 3.6 (vecLib 3.6) <DA9BFF01-40DF-EBD5-ABB7-787DAF2D77CF> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/vecLib
    0x7fff81734000 -     0x7fff81754ff7  com.apple.DirectoryService.Framework 3.6 (621.14) <15CF4C96-372D-C706-A237-47D20D2CAA6B> /System/Library/Frameworks/DirectoryService.framework/Versions/A/DirectoryService
    0x7fff81755000 -     0x7fff8178ffff  libcups.2.dylib 2.8.0 (compatibility 2.0.0) <7982734A-B66B-44AA-DEEC-364D2C10009B> /usr/lib/libcups.2.dylib
    0x7fff81790000 -     0x7fff817b3fff  com.apple.opencl 12.3.6 (12.3.6) <42FA5783-EB80-1168-4015-B8C68F55842F> /System/Library/Frameworks/OpenCL.framework/Versions/A/OpenCL
    0x7fff81915000 -     0x7fff81919ff7  libmathCommon.A.dylib 315.0.0 (compatibility 1.0.0) <95718673-FEEE-B6ED-B127-BCDBDB60D4E5> /usr/lib/system/libmathCommon.A.dylib
    0x7fff8191f000 -     0x7fff8192efef  com.apple.opengl 1.6.14 (1.6.14) <ECAE2D12-5BE3-46E7-6EE5-563B80B32A3E> /System/Library/Frameworks/OpenGL.framework/Versions/A/OpenGL
    0x7fff8192f000 -     0x7fff819adff7  com.apple.CoreText 151.12 (???) <5BE797B7-C903-B664-ADD9-7514B1A6EF9E> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/CoreText.framework/Versions/A/CoreText
    0x7fff81ab3000 -     0x7fff81ef6fef  libLAPACK.dylib 219.0.0 (compatibility 1.0.0) <0CC61C98-FF51-67B3-F3D8-C5E430C201A9> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libLAPACK.dylib
    0x7fff83022000 -     0x7fff83320fff  com.apple.HIToolbox 1.6.5 (???) <AD1C18F6-51CB-7E39-35DD-F16B1EB978A8> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/HIToolbox.framework/Versions/A/HIToolbox
    0x7fff83321000 -     0x7fff83381fe7  com.apple.framework.IOKit 2.0 (???) <4F071EF0-8260-01E9-C641-830E582FA416> /System/Library/Frameworks/IOKit.framework/Versions/A/IOKit
    0x7fff83635000 -     0x7fff836eafe7  com.apple.ink.framework 1.3.3 (107) <FFC46EE0-3544-A459-2AB9-94778A75E3D4> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Ink.framework/Versions/A/Ink
    0x7fff8372e000 -     0x7fff837effef  com.apple.ColorSync 4.6.8 (4.6.8) <7DF1D175-6451-51A2-DBBF-40FCA78C0D2C> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ColorSync.framework/Versions/A/ColorSync
    0x7fff837f0000 -     0x7fff838cdfff  com.apple.vImage 4.1 (4.1) <C3F44AA9-6F71-0684-2686-D3BBC903F020> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vImage.framework/Versions/A/vImage
    0x7fff838ce000 -     0x7fff83916ff7  libvDSP.dylib 268.0.1 (compatibility 1.0.0) <170DE04F-89AB-E295-0880-D69CAFBD7979> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libvDSP.dylib
    0x7fff83917000 -     0x7fff83919fff  libRadiance.dylib ??? (???) <B422DA26-E0CF-F280-6EB4-3B8FEF59B665> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libRadiance.dylib
    0x7fff83955000 -     0x7fff83bd7fff  com.apple.Foundation 6.6.8 (751.63) <E10E4DB4-9D5E-54A8-3FB6-2A82426066E4> /System/Library/Frameworks/Foundation.framework/Versions/C/Foundation
    0x7fff83c41000 -     0x7fff83db8fe7  com.apple.CoreFoundation 6.6.6 (550.44) <BB4E5158-E47A-39D3-2561-96CB49FA82D4> /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
    0x7fff83db9000 -     0x7fff83eeefff  com.apple.audio.toolbox.AudioToolbox 1.6.7 (1.6.7) <F4814A13-E557-59AF-30FF-E62929367933> /System/Library/Frameworks/AudioToolbox.framework/Versions/A/AudioToolbox
    0x7fff8477a000 -     0x7fff84939fff  com.apple.ImageIO.framework 3.0.5 (3.0.5) <175E97F1-B1A7-655A-F154-5B6ACC5F3985> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/ImageIO
    0x7fff8493a000 -     0x7fff84a0efe7  com.apple.CFNetwork 454.12.4 (454.12.4) <C83E2BA1-1818-B3E8-5334-860AD21D1C80> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/CFNetwork.framework/Versions/A/CFNetwork
    0x7fff84a0f000 -     0x7fff84a8cfef  libstdc++.6.dylib 7.9.0 (compatibility 7.0.0) <35ECA411-2C08-FD7D-11B1-1B7A04921A5C> /usr/lib/libstdc++.6.dylib
    0x7fff84a8d000 -     0x7fff85189ff7  com.apple.CoreGraphics 1.545.0 (???) <58D597B1-EB3B-710E-0B8C-EC114D54E11B> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/CoreGraphics.framework/Versions/A/CoreGraphics
    0x7fff85208000 -     0x7fff853c9fef  libSystem.B.dylib 125.2.11 (compatibility 1.0.0) <9AB4F1D1-89DC-0E8A-DC8E-A4FE4D69DB69> /usr/lib/libSystem.B.dylib
    0x7fff853ca000 -     0x7fff853e0fe7  com.apple.MultitouchSupport.framework 207.11 (207.11) <8233CE71-6F8D-8B3C-A0E1-E123F6406163> /System/Library/PrivateFrameworks/MultitouchSupport.framework/Versions/A/MultitouchSupport
    0x7fff85444000 -     0x7fff85501fff  com.apple.CoreServices.OSServices 359.2 (359.2) <BBB8888E-18DE-5D09-3C3A-F4C029EC7886> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/OSServices.framework/Versions/A/OSServices
    0x7fff858a3000 -     0x7fff85922fe7  com.apple.audio.CoreAudio 3.2.6 (3.2.6) <79E256EB-43F1-C7AA-6436-124A4FFB02D0> /System/Library/Frameworks/CoreAudio.framework/Versions/A/CoreAudio
    0x7fff85923000 -     0x7fff8596dff7  com.apple.Metadata 10.6.3 (507.15) <DE238BE4-5E22-C4D5-CF5C-3D50FDEE4701> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/Metadata.framework/Versions/A/Metadata
    0x7fff8596e000 -     0x7fff85999ff7  libxslt.1.dylib 3.24.0 (compatibility 3.0.0) <3630A97F-55C1-3F34-CA63-3847653C9645> /usr/lib/libxslt.1.dylib
    0x7fff8599e000 -     0x7fff859a3fff  libGFXShared.dylib ??? (???) <6BBC351E-40B3-F4EB-2F35-05BDE52AF87E> /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGFXShared.dylib
    0x7fff859e6000 -     0x7fff85a27fef  com.apple.QD 3.36 (???) <5DC41E81-32C9-65B2-5528-B33E934D5BB4> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/QD.framework/Versions/A/QD
    0x7fff85a28000 -     0x7fff85a28ff7  com.apple.vecLib 3.6 (vecLib 3.6) <08D3D45D-908B-B86A-00BA-0F978D2702A7> /System/Library/Frameworks/vecLib.framework/Versions/A/vecLib
    0x7fff85a29000 -     0x7fff85aebfe7  libFontParser.dylib ??? (???) <EF06F16C-0CC9-B4CA-7BD9-0A97FA967340> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ATS.framework/Versions/A/Resources/libFontParser.dylib
    0x7fff85aec000 -     0x7fff85d75ff7  com.apple.security 6.1.2 (55002) <0D80504C-9A6D-C865-AF37-7C231ACF97CB>
I reproduced the crash on my MacBook Pro using JDK8-B51:

$ java -XX:+UseSerialGC -XX:+UseLargePages -XX:-UseCompressedOops -version
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGFPE (0x8) at pc=0x0000000101245dfb, pid=35442, tid=6403
#
# JRE version:  (8.0-b51)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (24.0-b19 mixed mode bsd-amd64 )
# Problematic frame:
# V  [libjvm.dylib+0x245dfb]  lcm(unsigned long, unsigned long)+0x1f
#
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /work/shared/bugs/ramki/hs_err_pid35442.log
Phoning home... 
Using server: 10.161.186.18, port 4711
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.sun.com/bugreport/crash.jsp
#
Abort trap
Ramki reproduced it on 7u6 also:

Same crash with 7u6 (hs 23.2) as well. Fails with CMS or SerialGC, when large pages is enabled. Works with ParallelGC.

/Library/Java/JavaVirtualMachines/jdk1.7.0_06.jdk/Contents/Home/bin/java -XX:+UseSerialGC -XX:+UseLargePages -XX:-UseCompressedOops -version
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGFPE (0x8) at pc=0x00000001059b531f, pid=22207, tid=7171
#
# JRE version: 7.0_06-b24
# Java VM: Java HotSpot(TM) 64-Bit Server VM (23.2-b09 mixed mode bsd-amd64 )
# Problematic frame:
# V  [libjvm.dylib+0x23231f]
#
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /Users/srinivas.ramakrishna/workday/18/hs_err_pid22207.log
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.sun.com/bugreport/crash.jsp
#
Abort trap: 6

Also on 7u8, but that release also uses HSX-23.2-B09 so
that's not a surprise.
Another e-mail:

Some more data, in case it helps:-

. Parallel and ParallelOld silently seem to work properly.

. G1 doesn't crash but prints an error

. CMS and Serial crash in similar manner with SIGFPE

So probably something specific to how they do this which is done differently w/PS heap and
differently again w/G1. In all crashes, asking for large pages seems to be the key.
MacOS X crash using -XX:+UseLargePages reported by Ramki:

(The failure further below is during start-up. I don't have  locally built jvm to do further debugging -- am not set up to
build the JVM on OSX -- and can't get any symbols in the backtrace) :-

Java Threads: ( => current thread )

Other Threads:

=>0x00007fd128834800 (exited) JavaThread "Unknown thread" [_thread_in_vm, id=198328320, stack(0x000000010bc24000,0x000000010bd24000)]

VM state:not at safepoint (not fully initialized)



$ uname -a
Darwin ... 11.4.0 Darwin Kernel Version 11.4.0: Mon Apr  9 19:33:05 PDT 2012; root:xnu-1699.26.8~1/RELEASE_I386 i386

$ java -version
java version "1.7.0_05"
Java(TM) SE Runtime Environment (build 1.7.0_05-b05)
Java HotSpot(TM) 64-Bit Server VM (build 23.1-b03, mixed mode)

$ java -XX:+UseLargePages -XX:+PrintGCDetails -version
java version "1.7.0_05"
Java(TM) SE Runtime Environment (build 1.7.0_05-b05)
Java HotSpot(TM) 64-Bit Server VM (build 23.1-b03, mixed mode)
Heap
 PSYoungGen      total 25024K, used 860K [0x00000007e4200000, 0x00000007e5de0000, 0x0000000800000000)
  eden space 21504K, 4% used [0x00000007e4200000,0x00000007e42d7178,0x00000007e5700000)
  from space 3520K, 0% used [0x00000007e5a70000,0x00000007e5a70000,0x00000007e5de0000)
  to   space 3520K, 0% used [0x00000007e5700000,0x00000007e5700000,0x00000007e5a70000)
 ParOldGen       total 57088K, used 0K [0x00000007ac600000, 0x00000007afdc0000, 0x00000007e4200000)
  object space 57088K, 0% used [0x00000007ac600000,0x00000007ac600000,0x00000007afdc0000)
 PSPermGen       total 21248K, used 2117K [0x00000007a7400000, 0x00000007a88c0000, 0x00000007ac600000)
  object space 21248K, 9% used [0x00000007a7400000,0x00000007a76117e8,0x00000007a88c0000)

$ java -XX:+UseConcMarkSweepGC -XX:+UseLargePages -XX:+PrintGCDetails -version
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGFPE (0x8) at pc=0x000000010b3b4297, pid=8785, tid=4493295616
#
# JRE version: 7.0_05-b05
# Java VM: Java HotSpot(TM) 64-Bit Server VM (23.1-b03 mixed mode bsd-amd64 compressed oops)
# Problematic frame:
# V  [libjvm.dylib+0x231297]
#
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /Users/srinivas.ramakrishna/workday/save/hs_err_pid8785.log
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.sun.com/bugreport/crash.jsp
#
Abort trap: 6

$ java -XX:+UseConcMarkSweepGC -XX:+PrintGCDetails -version
java version "1.7.0_05"
Java(TM) SE Runtime Environment (build 1.7.0_05-b05)
Java HotSpot(TM) 64-Bit Server VM (build 23.1-b03, mixed mode)
Heap
 par new generation   total 25728K, used 916K [0x00000007a7400000, 0x00000007a8fe0000, 0x00000007bc0c0000)
  eden space 22912K,   4% used [0x00000007a7400000, 0x00000007a74e52b8, 0x00000007a8a60000)
  from space 2816K,   0% used [0x00000007a8a60000, 0x00000007a8a60000, 0x00000007a8d20000)
  to   space 2816K,   0% used [0x00000007a8d20000, 0x00000007a8d20000, 0x00000007a8fe0000)
 concurrent mark-sweep generation total 57088K, used 0K [0x00000007bc0c0000, 0x00000007bf880000, 0x00000007fae00000)
 concurrent-mark-sweep perm gen total 21248K, used 2118K [0x00000007fae00000, 0x00000007fc2c0000, 0x0000000800000000)
Much nicer info from a debug bits build:

# To suppress the following error report, specify this argument
# after -XX: or in .hotspotrc:  SuppressErrorAt=/globalDefinitions.cpp:335
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (/HUDSON/workspace/jdk8-2-build-macosx-amd64-product/jdk8/hotspot/src/share/vm/utilities/globalDefinitions.cpp:335), pid=35567, tid=6403
#  assert(div != 0) failed: lcm requires positive arguments
#
# JRE version:  (8.0-b51)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (24.0-b19-fastdebug mixed mode bsd-amd64 )
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /work/shared/bugs/7191817/hs_err_pid35567.log
Phoning home... 
Using server: 10.161.186.18, port 4711
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.sun.com/bugreport/crash.jsp
#
Current thread is 6403
Dumping core ...
Abort trap

Comments
SUGGESTED FIX diff --git a/src/share/vm/runtime/arguments.cpp b/src/share/vm/runtime/arguments. cpp --- a/src/share/vm/runtime/arguments.cpp +++ b/src/share/vm/runtime/arguments.cpp @@ -2806,6 +2806,18 @@ } #endif +#ifdef _ALLBSD_SOURCE + // UseLargePages not supported on BSD + if (UseLargePages) { + // warn if they turned it on. + if (!FLAG_IS_DEFAULT(UseLargePages)) { + warning("UseLargePages not supported on BSD"); + } + UseLargePages = false; + } +#endif // _ALLBSD_SOURCE + + // If we are running in a headless jre, force java.awt.headless property // to be true unless the property has already been set. // Also allow the OS environment variable JAVA_AWT_HEADLESS to set headless st ate.
20-09-2012

EVALUATION Here's the crashing code: src/share/vm/utilities/globalDefinitions.cpp: 328 // least common multiple 329 size_t lcm(size_t a, size_t b) { 330 size_t cur, div, next; 331 332 cur = MAX2(a, b); 333 div = MIN2(a, b); 334 335 assert(div != 0, "lcm requires positive arguments"); 336 337 338 while ((next = cur % div) != 0) { 339 cur = div; div = next; 340 } 341 342 343 julong result = julong(a) * b / div; 344 assert(result <= (size_t)max_uintx, "Integer overflow in lcm"); 345 346 return size_t(result); 347 } The lcm() function was called from here: 5 libjvm.dylib 0x0000000101f33c5a VMError::report_and_die() + 2444 6 libjvm.dylib 0x0000000101ab95eb report_vm_error(char const*, int, char const*, char const*) + 99 7 libjvm.dylib 0x0000000101b6d2df lcm(unsigned long, unsigned long) + 70 8 libjvm.dylib 0x0000000101a50a8e GenCollectorPolicy::initialize_flags() + 28 9 libjvm.dylib 0x0000000101a51928 TwoGenerationCollectorPolicy::initialize_flags() + 20 10 libjvm.dylib 0x0000000101a41e83 GenCollectorPolicy::initialize_all() + 21 11 libjvm.dylib 0x0000000101f08225 Universe::initialize_heap() + 309 12 libjvm.dylib 0x0000000101f087dc universe_init() + 484 13 libjvm.dylib 0x0000000101b9e315 init_globals() + 120 14 libjvm.dylib 0x0000000101ef2d12 Threads::create_vm(JavaVMInitArgs*, bool*) + 492 15 libjvm.dylib 0x0000000101c2fb22 JNI_CreateJavaVM + 143 16 java 0x00000001f4fbfa45 JavaMain + 308 17 libSystem.B.dylib 0x00007fff85241fd6 _pthread_start + 331 18 libSystem.B.dylib 0x00007fff85241e89 thread_start + 13 The stack makes it look like GenCollectorPolicy::initialize_flags() calls lcm(), but that's not right. Here's the code: src/share/vm/memory/collectorPolicy.cpp: 229 void GenCollectorPolicy::initialize_flags() { 230 // All sizes must be multiples of the generation granularity. 231 set_min_alignment((uintx) Generation::GenGrain); 232 set_max_alignment(compute_max_alignment()); and here is compute_max_alignment(): 208 size_t GenCollectorPolicy::compute_max_alignment() { 209 // The card marking array and the offset arrays for old generations ar e 210 // committed in os pages as well. Make sure they are entirely full (to 211 // avoid partial page problems), e.g. if 512 bytes heap corresponds to 1 212 // byte entry and the os page size is 4096, the maximum heap size shou ld 213 // be 512*4096 = 2MB aligned. 214 size_t alignment = GenRemSet::max_alignment_constraint(rem_set_name()) ; 215 216 // Parallel GC does its own alignment of the generations to avoid requ iring a 217 // large page (256M on some platforms) for the permanent generation. The 218 // other collectors should also be updated to do their own alignment a nd then 219 // this use of lcm() should be removed. 220 if (UseLargePages && !UseParallelGC) { 221 // in presence of large pages we have to make sure that our 222 // alignment is large page aware 223 alignment = lcm(os::large_page_size(), alignment); 224 } 225 226 return alignment; 227 } And here is: src/os/bsd/vm/os_bsd.cpp 3330 size_t os::large_page_size() { 3331 return _large_page_size; 3332 } And here is the relevant code snippet for _large_page_size: 3168 // Large page support 3169 3170 static size_t _large_page_size = 0; 3171 3172 void os::large_page_init() { 3173 #ifndef _ALLBSD_SOURCE 3174 if (!UseLargePages) { 3175 UseHugeTLBFS = false; 3176 UseSHM = false; 3177 return; 3178 } <snip> 3233 // print a warning if any large page related flag is specified on comm and line 3234 bool warn_on_failure = !FLAG_IS_DEFAULT(UseHugeTLBFS); 3235 3236 const size_t default_page_size = (size_t)Bsd::page_size(); 3237 if (_large_page_size > default_page_size) { 3238 _page_sizes[0] = _large_page_size; 3239 _page_sizes[1] = default_page_size; 3240 _page_sizes[2] = 0; 3241 } 3242 UseHugeTLBFS = UseHugeTLBFS && 3243 Bsd::hugetlbfs_sanity_check(warn_on_failure, _large_pag e_size); 3244 3245 if (UseHugeTLBFS) 3246 UseSHM = false; 3247 3248 UseLargePages = UseHugeTLBFS || UseSHM; 3249 3250 set_coredump_filter(); 3251 #endif 3252 } All of the above is a long winded way of saying that the -XX:+UseLargePages option isn't implemented on MacOS X and you don't get a warning of any kind to that effect.
15-08-2012