Segfault toward end of hotspot-comp build (original) (raw)

Krystal Mok rednaxelafx at gmail.com
Tue Sep 6 08:51:53 PDT 2011


Hi Charles,

It's not a segfault, but rather hitting an assertion when initializing the VM in the test gamma run, during the last part of the build process. The VM is already fully built and linked by then, so it looks like the VM compiled cleanly.

A wild guess of what caused this problem would be: something's not right in your HotSpot code, specifically, src/share/vm/runtime/arguments.cpp, in Arguments::set_heap_size(), or in src/share/vm/runtime/globals.hpp.

The assertion is indicating that someone is trying to set a flag with the type uintx (in Arguments::set_heap_size(), with either of the two macros, FLAG_SET_CMDLINE or FLAG_SET_ERGO), but the flag was declared to be of another type (in globals.hpp).

I'd suggest cleaning the source directory (at least arguments.cpp and globals.hpp) and try building it again. I've just done building the current tip of hotspot-comp (with no other patches applied), and nothing weird happened:

cd linux_amd64_compiler2/product && ./test_gamma java full version "1.6.0_25-b06" Using java runtime at: /home/rednaxelafx/sdk/jdk1.6.0_25/jre java version "1.6.0_25" Java(TM) SE Runtime Environment (build 1.6.0_25-b06) OpenJDK 64-Bit Server VM (build 22.0-b02-internal, mixed mode)

  1. A1 B5 C8 D6 E3 F7 G2 H4 ...
  2. A8 B4 C1 D3 E6 F2 G7 H5

Regards, Kris Mok

On Tue, Sep 6, 2011 at 10:53 PM, Charles Oliver Nutter <headius at headius.com>wrote:

Perhaps I've got an environmental issue here, but I'd like to be sure I'm building hotspot-comp properly. What's causing this?

Linking vm... echo Linking launcher... Linking launcher... gcc -m64 -Xlinker -O1 -Wl,--hash-style=both -Xlinker -z -Xlinker noexecstack -m64 -Xlinker -export-dynamic -L pwd -o gamma launcher/javamd.o launcher/jliutil.o launcher/wildcard.o launcher/java.o -ljvm -lm -ldl -lpthread make[4]: Leaving directory /home/headius/projects/hotspot/build/linux/linuxamd64compiler2/product'_ _All done._ _make[3]: Leaving directory_ _/home/headius/projects/hotspot/build/linux/linuxamd64compiler2/product' cd linuxamd64compiler2/product && ./testgamma java full version "1.7.002-ea-b05" Using java runtime at: /home/headius/java/re/j2se/1.7.0/latest/binaries/linux-amd64/jre # # A fatal error has been detected by the Java Runtime Environment: # # Internal Error (globals.cpp:374), pid=14670, tid=47908911146752 # guarantee(faddr != NULL && faddr->isuintx()) failed: wrong flag type # # JRE version: 7.002-b05 # Java VM: OpenJDK 64-Bit Server VM (22.0-b02-internal mixed mode linux-amd64 compressed oops) # 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: # /home/headius/projects/hotspot/build/linux/linuxamd64compiler2/product/hserrpid14670.log # # If you would like to submit a bug report, please visit: # http://bugreport.sun.com/bugreport/crash.jsp # Aborted make[2]: *** [product] Error 134 make[2]: Leaving directory /home/headius/projects/hotspot/build/linux'_ _make[1]: *** [genericbuild2] Error 2_ _make[1]: Leaving directory /home/headius/projects/hotspot/make' make: *** [product] Error 2 make: Leaving directory `/home/headius/projects/hotspot/make' And the relevant bit of hserr: --------------- T H R E A D --------------- Current thread is native thread Stack: [0x00002b92a9916000,0x00002b92a9a17000], sp=0x00002b92a9a14930, free space=1018k Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code) V [libjvm.so+0x867454] VMError::reportanddie()+0x174 V [libjvm.so+0x3e0b6a] reportvmerror(char const*, int, char const*, char const*)+0x4a V [libjvm.so+0x492000] CommandLineFlagsEx::uintxAtPut(CommandLineFlagWithType, unsigned long, FlagValueOrigin)+0x60 V [libjvm.so+0x21b82a] Arguments::setheapsize()+0x10a V [libjvm.so+0x22009d] Arguments::parse(JavaVMInitArgs const*)+0x4bd V [libjvm.so+0x81f66d] Threads::createvm(JavaVMInitArgs*, bool*)+0x8d V [libjvm.so+0x528a0f] JNICreateJavaVM+0x6f C [gamma+0x5002] printf@@GLIBC2.2.5+0x5002 C [gamma+0x3dd8] JavaMain+0xc1 The script I'm using to build: https://gist.github.com/1148321 - Charlie -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/hotspot-compiler-dev/attachments/20110906/f685d7e6/attachment.html



More information about the hotspot-compiler-dev mailing list