system property 'java.security.manager' is not defined. so ClassLoader doesn't initializes SecurityManager. $ ./gcj-dbtool.exe -n classmap.db Exception in thread "main" java.lang.ExceptionInInitializerError at java.lang.Class.initializeClass(/tmp/gcc/i686-pc-mingw32/libjava/../.././libjava/java/lang/natClass.cc:803) at java.security.Security.getProperty(/tmp/gcc/libjava/classpath/java/security/Security.java:366) at java.net.ResolverCache.getTTL(/tmp/gcc/libjava/classpath/java/net/ResolverCache.java:90) at java.net.ResolverCache.<clinit>(/tmp/gcc/libjava/classpath/java/net/ResolverCache.java:77) at java.lang.Class.initializeClass(/tmp/gcc/i686-pc-mingw32/libjava/../.././libjava/java/lang/natClass.cc:791) at java.net.ResolverCache.getHostByAddr(/tmp/gcc/libjava/classpath/java/net/ResolverCache.java:118) at java.net.InetAddress.internalGetCanonicalHostName(/tmp/gcc/libjava/classpath/java/net/InetAddress.java:319) at java.net.InetAddress.getCanonicalHostName(/tmp/gcc/libjava/classpath/java/net/InetAddress.java:334) at java.net.InetAddress.getHostName(/tmp/gcc/libjava/classpath/java/net/InetAddress.java:307) at java.net.InetAddress.<clinit>(/tmp/gcc/libjava/classpath/java/net/InetAddress.java:92) at java.lang.Class.initializeClass(/tmp/gcc/i686-pc-mingw32/libjava/../.././libjava/java/lang/natClass.cc:791) at java.net.InetAddress.getLocalHost(/tmp/gcc/libjava/classpath/java/net/InetAddress.java:612) at gnu.java.net.GetLocalHostAction.run(/tmp/gcc/libjava/classpath/gnu/java/net/GetLocalHostAction.java:57) at gnu.java.net.GetLocalHostAction.run(/tmp/gcc/libjava/classpath/gnu/java/net/GetLocalHostAction.java:1) at java.security.AccessController.doPrivileged(/tmp/gcc/libjava/classpath/java/security/AccessController.java:96) at gnu.java.net.protocol.ftp.FTPURLConnection.connect(/tmp/gcc/libjava/classpath/gnu/java/net/protocol/ftp/FTPURLConnection.java:117) at gnu.java.net.protocol.ftp.FTPURLConnection.getInputStream(/tmp/gcc/libjava/classpath/gnu/java/net/protocol/ftp/FTPURLConnection.java:165) at java.net.URL.openStream(/tmp/gcc/libjava/classpath/java/net/URL.java:737) at java.util.logging.LogManager.readConfiguration(/tmp/gcc/libjava/java/util/logging/LogManager.java:507) at java.util.logging.LogManager.initLogManager(/tmp/gcc/libjava/java/util/logging/LogManager.java:203) at java.util.logging.LogManager.getLogManager(/tmp/gcc/libjava/java/util/logging/LogManager.java:168) at java.util.logging.Logger.getLogger(/tmp/gcc/libjava/java/util/logging/Logger.java:276) at java.util.logging.Logger.getLogger(/tmp/gcc/libjava/java/util/logging/Logger.java:224) at java.util.logging.Logger$1.run(/tmp/gcc/libjava/java/util/logging/Logger.java:91) at java.security.AccessController.doPrivileged(/tmp/gcc/libjava/classpath/java/security/AccessController.java:96) at java.util.logging.Logger.<clinit>(/tmp/gcc/libjava/java/util/logging/Logger.java:86) at java.lang.Class.initializeClass(/tmp/gcc/i686-pc-mingw32/libjava/../.././libjava/java/lang/natClass.cc:791) at java.util.logging.Logger.getLogger(/tmp/gcc/libjava/java/util/logging/Logger.java:224) at java.math.BigInteger.<clinit>(/tmp/gcc/libjava/classpath/java/math/BigInteger.java:67) at java.lang.Class.initializeClass(/tmp/gcc/i686-pc-mingw32/libjava/../.././libjava/java/lang/natClass.cc:791) at gnu.gcj.runtime.PersistentByteMap.init(/tmp/gcc/libjava/gnu/gcj/runtime/PersistentByteMap.java:181) at gnu.gcj.runtime.PersistentByteMap.emptyPersistentByteMap(/tmp/gcc/libjava/gnu/gcj/runtime/PersistentByteMap.java:231) at gnu.gcj.tools.gcj_dbtool.Main.main(/tmp/gcc/libjava/gnu/gcj/tools/gcj_dbtool/Main.java:82) Caused by: java.lang.NullPointerException at java.net.ResolverCache.reap(/tmp/gcc/libjava/classpath/java/net/ResolverCache.java:221) at java.net.ResolverCache.get(/tmp/gcc/libjava/classpath/java/net/ResolverCache.java:192) at java.net.ResolverCache.getHostByName(/tmp/gcc/libjava/classpath/java/net/ResolverCache.java:152) at java.net.InetAddress.getAllByName(/tmp/gcc/libjava/classpath/java/net/InetAddress.java:590) at java.net.InetAddress.getByName(/tmp/gcc/libjava/classpath/java/net/InetAddress.java:550) at java.net.InetAddress.getLocalHost(/tmp/gcc/libjava/classpath/java/net/InetAddress.java:615) at gnu.java.net.GetLocalHostAction.run(/tmp/gcc/libjava/classpath/gnu/java/net/GetLocalHostAction.java:57) at gnu.java.net.GetLocalHostAction.run(/tmp/gcc/libjava/classpath/gnu/java/net/GetLocalHostAction.java:1) at java.security.AccessController.doPrivileged(/tmp/gcc/libjava/classpath/java/security/AccessController.java:96) at gnu.java.net.protocol.ftp.FTPURLConnection.connect(/tmp/gcc/libjava/classpath/gnu/java/net/protocol/ftp/FTPURLConnection.java:117) at gnu.java.net.protocol.ftp.FTPURLConnection.getInputStream(/tmp/gcc/libjava/classpath/gnu/java/net/protocol/ftp/FTPURLConnection.java:165) at java.net.URL.openStream(/tmp/gcc/libjava/classpath/java/net/URL.java:737) at java.security.Security.loadProviders(/tmp/gcc/libjava/classpath/java/security/Security.java:131) at java.security.Security.<clinit>(/tmp/gcc/libjava/classpath/java/security/Security.java:80) at java.lang.Class.initializeClass(/tmp/gcc/i686-pc-mingw32/libjava/../.././libjava/java/lang/natClass.cc:791) ...32 more $ /tmp/gcc/host-i686-pc-cygwin/gcc/gcj -v -B.. Using built-in specs. Reading specs from ../libgcj.spec rename spec startfile to startfileorig rename spec lib to liborig COLLECT_GCC=/tmp/gcc/host-i686-pc-cygwin/gcc/gcj Target: i686-pc-mingw32 Configured with: ./configure -C --prefix=/usr --enable-win32-registry --enable-java-awt=qt --enable-threads=win32 --enable-languages=c,c++,lto,java --with-win32-nlsapi=unicode --enable-tls --disable-bootstrap --target=i686-pc-mingw32 --enable-shared --enable-load-library --enable-interpreter --disable-sjlj-exceptions --enable-gomp --with-ecj-jar=/tmp/gcc/org.eclipse.jdt.core_3.7.0.v_B35.jar --with-antlr-jar=/tmp/gcc/antlr-3.3-complete.jar --with-libiconv-prefix=/usr/i686-pc-mingw32 --with-x=no --enable-cloog-backend=isl --with-sysroot=/usr/i686-pc-mingw32/sys-root --with-build-sysroot=/usr/i686-pc-mingw32/sys-root LTLDFLAGS=-no-undefined lt_cv_deplibs_check_method=pass_all Thread model: win32 gcc version 4.7.0 20120114 (experimental) (GCC)
Why the 4.7 regression tag? Does it work in 4.6? I think the amount of libgcj changes since 4.6 has been very small...
(In reply to comment #1) > Why the 4.7 regression tag? Does it work in 4.6? I think the amount of libgcj > changes since 4.6 has been very small... sorry for 4.7 regression tag. it worked before i apply the patch in pr50057. this bug opened after i applied the patch. please review pr50057.
Created attachment 26512 [details] proposed patch for handling thiscall r3 FAIL: TestClosureGC output FAIL: libjava.jar/TestClosureGC.jar execution - gij test FAIL: simple output FAIL: libjava.jar/simple.jar execution - gij test Running /tmp/gcc/libjava/testsuite/libjava.jni/jni.exp ... Running /tmp/gcc/libjava/testsuite/libjava.jvmti/jvmti-interp.exp ... Running /tmp/gcc/libjava/testsuite/libjava.jvmti/jvmti.exp ... Running /tmp/gcc/libjava/testsuite/libjava.lang/lang.exp ... FAIL: ExtraClassLoader execution - source compiled test FAIL: ExtraClassLoader -findirect-dispatch execution - source compiled test FAIL: ExtraClassLoader -O3 execution - source compiled test FAIL: ExtraClassLoader -O3 -findirect-dispatch execution - source compiled test FAIL: ProxyTest -O3 execution - source compiled test FAIL: ProxyTest -O3 -findirect-dispatch execution - source compiled test FAIL: StackTrace2 output - source compiled test FAIL: StackTrace2 -findirect-dispatch output - source compiled test FAIL: StackTrace2 -O3 output - source compiled test FAIL: StackTrace2 -O3 -findirect-dispatch output - source compiled test FAIL: TestProxy -O3 execution - source compiled test FAIL: TestProxy -O3 -findirect-dispatch execution - source compiled test FAIL: Thread_Sleep output - source compiled test FAIL: Thread_Sleep -findirect-dispatch output - source compiled test FAIL: Thread_Sleep -O3 output - source compiled test FAIL: Thread_Sleep -O3 -findirect-dispatch output - source compiled test FAIL: Thread_Sleep_2 output - source compiled test FAIL: Thread_Sleep_2 -findirect-dispatch output - source compiled test FAIL: Thread_Sleep_2 -O3 output - source compiled test FAIL: Thread_Sleep_2 -O3 -findirect-dispatch output - source compiled test FAIL: Throw_2 execution - source compiled test FAIL: Throw_2 -findirect-dispatch execution - source compiled test FAIL: Throw_2 -O3 execution - source compiled test FAIL: Throw_2 -O3 -findirect-dispatch execution - source compiled test FAIL: md5test execution - source compiled test FAIL: md5test -findirect-dispatch execution - source compiled test FAIL: md5test -O3 execution - source compiled test FAIL: md5test -O3 -findirect-dispatch execution - source compiled test FAIL: pr21785 execution - source compiled test FAIL: pr21785 -findirect-dispatch execution - source compiled test FAIL: pr21785 -O3 execution - source compiled test FAIL: pr21785 -O3 -findirect-dispatch execution - source compiled test FAIL: pr26990 execution - source compiled test FAIL: pr26990 -findirect-dispatch execution - source compiled test FAIL: pr26990 -O3 execution - source compiled test FAIL: pr26990 -O3 -findirect-dispatch execution - source compiled test FAIL: shatest execution - source compiled test FAIL: shatest -findirect-dispatch execution - source compiled test FAIL: shatest -O3 execution - source compiled test FAIL: shatest -O3 -findirect-dispatch execution - source compiled test Running /tmp/gcc/libjava/testsuite/libjava.loader/loader.exp ... FAIL: TestEarlyGC execution - source compiled test FAIL: TestMultiple output - source compiled test FAIL: TestParent output - source compiled test Running /tmp/gcc/libjava/testsuite/libjava.mauve/mauve.exp ... sh: /configure: No such file or directory FAIL: Mauve configure Running /tmp/gcc/libjava/testsuite/libjava.special/special.exp ... Running /tmp/gcc/libjava/testsuite/libjava.verify/verify.exp ... === libjava Summary === # of expected passes 2331 # of unexpected failures 48 # of untested testcases 31
Comment on attachment 26512 [details] proposed patch for handling thiscall r3 invalid attachment. please ignore it.
this bug is sort of following bug > class staticcall{ private static final int a=getint(); // bug private static final Object bar=new Object(); private static void foo(){ System.out.printf(bar.toString()); } public static void main (String args[]) { } private static int getint(){ foo(); return 1; } } >yields following error message in openjdk 1.7, gcj 4.7. java.lang.ExceptionInInitializerError Caused by: java.lang.NullPointerException at staticcall.foo(staticcall.java:5) at staticcall.getint(staticcall.java:12) at staticcall.<clinit>(staticcall.java:2) Exception in thread "main" please place killqueue,cache ahead of NEGATIVE_TTL.
Created attachment 26537 [details] proposed patch 2012-02-01 gee <jojelino@gmail.com> * gnu/java/net/protocol/ftp/FTPConnection.java (FTPConnection): Check address reference * java/net/ResolverCache.java (cache,killqueue): Place just above the POSITIVE_TTL former one solves SIGSEGV in mingw32.(hence it doesn't install SIGSEGV handler) latter one solves ExceptionInInitializerError. please review it.
I can't reproduce this. Can you provide a reproducer? Thanks.