Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 357757

Summary: JVM crashes while running tests involving CDT
Product: [Tools] CDT Reporter: Jesper Eskilson <jesper.eskilson>
Component: cdt-coreAssignee: Project Inbox <cdt-core-inbox>
Status: RESOLVED NOT_ECLIPSE QA Contact: Doug Schaefer <cdtdoug>
Severity: normal    
Priority: P3 CC: aleherb+eclipse, mario.pierro
Version: 8.0   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Attachments:
Description Flags
JVM crash log none

Description Jesper Eskilson CLA 2011-09-15 06:04:42 EDT
Build Identifier: I20110613-1736

We have a testsuite which performs tests on our toolchain. This involves lots of CDT interaction (creating projects, indexing, debugging, etc.). Sometimes we get a JVM crash, usually when running test suites containing 20+ tests.

#
# A fatal error has been detected by the Java Runtime Environment:
#
#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x62874451, pid=6764, tid=8892
#
# JRE version: 7.0-b147
# Java VM: Java HotSpot(TM) Client VM (21.0-b17 mixed mode windows-x86 )
# Problematic frame:
# V  [jvm.dll+0x224451]
#
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.sun.com/bugreport/crash.jsp
#

A bit further down in the crash report I see:

Current CompileTask:
C1:  42149 4809             org.eclipse.cdt.internal.core.dom.parser.cpp.semantics.CPPVisitor::createType (363 bytes)

This led me to believe that this was an instance of bug #351234, but since I can reproduce this on a 32-bit 1.7.0-JVM, I'm not so sure.

I'm not sure how to create a minimally reproducible example, since the crash only happens under fairly high load.

Reproducible: Sometimes
Comment 1 Jesper Eskilson CLA 2011-09-15 06:08:47 EDT
Created attachment 203395 [details]
JVM crash log
Comment 2 Jesper Eskilson CLA 2011-09-15 06:10:05 EDT
Additional note: specifying -Xint causes the test suites to run without any crashes, so presumably this is related to the JIT-compiler.
Comment 3 Markus Schorn CLA 2011-09-15 06:43:39 EDT
The log indicates that the JIT compiler is crashing, which is not CDT's fault.
Comment 4 Anton Leherbauer CLA 2011-09-15 07:13:49 EDT
You might want to file a bug with Oracle. As a workaround you could try to disable JIT compilation of the affected method:

-XX:CompileCommand=exclude,org/eclipse/cdt/internal/core/dom/parser/cpp/semantics/CPPVisitor,createType
Comment 5 Jesper Eskilson CLA 2011-09-15 09:28:07 EDT
(In reply to comment #4)
> You might want to file a bug with Oracle. As a workaround you could try to
> disable JIT compilation of the affected method:
> 
> -XX:CompileCommand=exclude,org/eclipse/cdt/internal/core/dom/parser/cpp/semantics/CPPVisitor,createType

This worked, thanks.

I will report this to Oracle.