Problems probably related to KJC

Ito Kazumitsu kaz at maczuka.gcd.org
Wed Jan 16 07:28:07 PST 2002


>>>>> ":" == Ito Kazumitsu <kaz at maczuka.gcd.org> writes:

:> Let's go back to Aug 31, 2001.
:> 
:> All the tests in "make check" passed this time. But some
:> program compiled under kaffe built this time dumps core.
:> The same program had no problem when it was compiled
:> under kaffe as of Aug 22, 2001.

I have made a simple program that makes kaffe dump core.

sh-2.02$ cat Test.java
import java.util.HashMap;

public class Test {

  private String sss1;
  private String sss2;
  private String sss3;
  private String sss4;
  private String sss5;
  private String sss6;
  private String sss7;

  public static void main(String args[]) throws Exception {
    new Test();
  }

  public Test() throws Exception {
 
    Driver drv = new Driver();

    HashMap hm = new HashMap();
    drv.setHandler(new HashMapMaker(hm));
    drv.handle();

    drv.setHandler(new Test1(hm));
    drv.handle();
  }

private class Test1 extends Handler {

  public Test1(HashMap hm) throws Exception {

    sss1 = (String)(hm.get("sss1"));
    System.err.println(sss1); System.err.flush();
    sss2 = (String)(hm.get("sss2"));
    System.err.println(sss2); System.err.flush();
    sss3 = (String)(hm.get("sss3"));
    System.err.println(sss3); System.err.flush();
    sss4 = (String)(hm.get("sss4"));
    System.err.println(sss4); System.err.flush();
    sss5 = (String)(hm.get("sss5"));
    System.err.println(sss5); System.err.flush();
    sss6 = (String)(hm.get("sss6"));
    System.err.println(sss6); System.err.flush();
    sss7 = (String)(hm.get("sss7"));
    System.err.println(sss7); System.err.flush();
    }

    public void handle() {}

}

private class HashMapMaker extends Handler {

  private HashMap hm;

  public HashMapMaker(HashMap hm) {
    this.hm = hm;
  }
  public void handle() {
    hm.put("sss1","sss1");
    hm.put("sss2","sss2");
    hm.put("sss3","sss3");
    hm.put("sss4","sss4");
    hm.put("sss5","sss5");
    hm.put("sss6","sss6");
    hm.put("sss7","sss7");
  }

}

}
sh-2.02$ cat Driver.java 
public class Driver {
  public Driver() {}
  private Handler handler;
  public void setHandler(Handler h) {
    handler = h;
  }
  public void handle() {
    handler.handle();
  }
}
sh-2.02$ cat Handler.java 
public class Handler {
  public Handler() {}
  public void handle() {}
}
sh-2.02$ cat setenv 
case "$1" in
  "new")
PATH=/newusr/local/kaffe-010831/bin:$PATH export PATH
  ;;
esac
CLASSPATH=. export CLASSPATH
sh-2.02$ cat compile 
#!/bin/sh
. setenv $1
java -fullversion
javac Handler.java
javac Driver.java
javac Test.java
sh-2.02$ cat go
#!/bin/sh
. setenv $1
java Test
sh-2.02$ ./compile old
Kaffe Virtual Machine
Copyright (c) 1996-2000
Transvirtual Technologies, Inc.  All rights reserved
Engine: Just-in-time v3   Version: 1.0.6   Java Version: 1.1
Configuration/Compilation options:
  Compile date  : Sun Jan 6 01:56:10 JST 2002
  Compile host  : ph.maczuka.gcd.org
  Install prefix: /usr/local
  Thread system : unix-jthreads
  CC            : gcc
  CFLAGS        : -g -O2 -Wall -Wstrict-prototypes
  LDFLAGS       :  -export-dynamic
  ChangeLog head: 2001-08-19  Edouard G. Parmelan  <egp at free.fr>
sh-2.02$ ./go old
sss1
sss2
sss3
sss4
sss5
sss6
sss7
sh-2.02$ ./compile new
Kaffe Virtual Machine
Copyright (c) 1996-2000
Transvirtual Technologies, Inc.  All rights reserved
Engine: Just-in-time v3   Version: 1.0.6   Java Version: 1.1
Configuration/Compilation options:
  Compile date  : Sun Jan 6 08:55:24 JST 2002
  Compile host  : ph.maczuka.gcd.org
  Install prefix: /newusr/local/kaffe-010831
  Thread system : unix-jthreads
  CC            : gcc
  CFLAGS        : -g -O2 -Wall -Wstrict-prototypes
  LDFLAGS       :  -export-dynamic
  ChangeLog head: 2001-08-30  Edouard G. Parmelan  <egp at free.fr>
sh-2.02$ ./go new
sss1
sss2
sss3
sss4
accessing free page 0x8f45f14 (above 0x8101000)
Abort trap - core dumped
sh-2.02$


More information about the kaffe mailing list