Re: [kaffe] Problems of Kaffe on mips-linux platform

2002-12-30 Thread Kevin D. Kissell



First, an unmodifled Kaffe.1.0.7 release source 
tree 
will not give you a 
working MIPS version of Kaffe.
The necessary patches to the release sources should 
be in
ftp://ftp.paralogos.com/pub/kaffe/mips/kaffe-1.0.7.patch_kevink_021001 

The changes were also merged with the 
Kaffe.org
CVS repository, so if you're working from 
development
sources, you should have them - along with all 
the
fun problems that come with working from 
development
sources.

Assuming you've got the right Kaffe 
sources,
I see a couplemore potential problems. 
One is that you
are using unix-pthreads instead of the Kaffe 
internal
"jthread" multithreading scheme. There have 
been
problems with Linux/UNIX pthreads for MIPS in 
many
versions of the kernel and gnu libraries, and I 
have
avoided pthreads in all my MIPS/Linux work, 
to
avoid confusing the issue. I would 
recommend
dropping the --with-threads configure option 
and
letting the build default to jthreads.

The other potential problem is that most 
MIPS/Linux
kernel sources up until very recently had 
problems
with context management during some 
exceptional
signal conditions that happen to turn up in 
Kaffe. 
Most 2.4.17-level sources don't have the fixes, though
Monta Vista's just might. 
Ifupdatingyour
Kaffe sources and using jthreads doesn't fix 
things, 
I would encourage you to get more up-to-date kernel
sources,either 
fromftp://ftp.mips.com/pub/linux/mips/
or from the CVS 
archive at linux-mips.org (which is
another development tree, with all the fun 
associated, etc.). 
I actually ratherdoubt that this is your 
problem, since 
in generalone needs to be doing floating-point operations
to see the problems, but if you're going to use 
Kaffe,
you will ultimately need those fixes.

When you say that you are testing your Kaffe 
build,
is this to say that all of the "make check" 
regression
tests run? It took me a while to get all 
those to work
(i.e. to generate the patch above), but once they 
did,
all the AWT stuff I tried worked fine. But I 
did not try
QT!

  
 Regards,

  
 Kevin K.

  - Original Message - 
  From: 
  Kim, 
  Seong Beom 
  To: [EMAIL PROTECTED] 
  Sent: Monday, December 30, 2002 8:05 
  AM
  Subject: [kaffe] Problems of Kaffe on 
  mips-linux platform
  
  Dear Kaffe experts.
  
  Because it is my first time to post message in this mailing 
  list,
  let me introduce a little bit.
  
  Hello, my name is Seongbeom Kim, and I'm working for a 
  digital television project
  that requires Java virtual machine. I've chosen Kaffe for 
  our virtual machine 
  because it is one of few VM solutions for mips-linux 
  platform.
  
  The specification of our systemis...
  ---
  Kaffe 
  version:Kaffe 
  1.0.7
  Reference board:  
   TeraLogic Cougar-L board
  CPU:   
  
   MIPS
  OS:Linux 
  (kernel 2.4.17 monta vista linux RedHat 7.1)
  AWT:QTE 
  (QTE 3.0.3)
  cross compiling 
  with:mips-linux-gcc 
  (egcs-2.91.66)
  configure 
  option:--target=mips-pc-linux-gnu 
  --host=mips-pc-linux-gnu --build=mips-pc-linux-gnu
 
  
 --with-engine=intrp 
  --with-threads=unix-pthreads
 
  
 
  --with-includes=/usr/mips-linux/include 
  --with-libraries=/usr/mips-linux/lib
  
  ---
  
  What I have done with this development is...
  1. Test build on i386-linux-QTE platform: it had no problem at all with 
  virtual frame buffer feature in embeddedQT.
  2. QTE test on mips-linux: I verified it withtest programs.
  3. Cross compiling for mips-linux-qte platform: build done, test compile 
   runningfor simple text based application done successfully.
  
  The problems are...
  1. When I try to running simple AWT example, the main thread hangs 
  inToolkit.createNative() and does not proceed.
  The code in Toolkit.java
  
  static void createNative ( Component c ) {WMEvent e = 
  null;
  
  synchronized ( Toolkit.class ) {// even if this 
  could be done in a central location, we defer this// as much 
  as possible because it might involve polling (for 
  non-threaded// AWTs), slowing down the startup 
  timeif ( eventThread == null ) 
  {startDispatch();}}
  
  System.out.println( "startDispatch() done..." );-- 
  does not print this message (hangs in startDispatch())
  
  // do we need some kind of a context switch ?...
  }
  2. After some modifications in Java codes such as inserting 
  debugging messages, there happens strange errors.
  
  [root@target /root]# javac -v HelloWorld.java[ start 
  compilation in verbose mode ]java.lang.VerifyError: In class 
  java/io/PushbackReader$PushbackBuffer in method init with signature 
  (Ljava/io/PushbackReader;Ljava/io/PushbackReader$1;I)V at pc 5: sp 7 not in 
  range [4, 6] at 
  java.io.PushbackReader.init(PushbackReader.java:27) 
  at 
  

Re: [kaffe] Problems of Kaffe on mips-linux platform

2002-12-30 Thread Dalibor Topic

--- Kim, Seong Beom [EMAIL PROTECTED] wrote:
 2. After some modifications in Java codes such as
 inserting debugging messages, there happens strange
 errors.
 
 [root@target /root]# javac -v HelloWorld.java
 [ start compilation in verbose mode ]
 java.lang.VerifyError: In class
 java/io/PushbackReader$PushbackBuffer in method
 init with signature

(Ljava/io/PushbackReader;Ljava/io/PushbackReader$1;I)V
 at pc 5: sp 7 not in range [4, 6]
 at

java.io.PushbackReader.init(PushbackReader.java:27)
 at

java.io.PushbackReader.init(PushbackReader.java:32)
 at

at.dms.compiler.tools.antlr.extra.InputBuffer.init(InputBuffer.java:69)
 at

at.dms.compiler.tools.antlr.extra.InputBuffer.init(InputBuffer.java:82)
 at at.dms.kjc.Main.parseFile(Main.java:325)
 at at.dms.kjc.Main.run(Main.java:147)
 at at.dms.kjc.Main.compile(Main.java:69)
 at at.dms.kjc.Main.main(Main.java:60)
 
 This error is only solved when I remove entire Kaffe
 tree, re-install source, re-configure and re-make
 it.
 'make distclean' cannot solve this problem.
 
 
 Does anyone know about these problems?
 Please help me, I'm in a really big trouble. :(

I assume that you're using jikes with a version  1.13
to compile kaffe's class library. You need to make
sure you use jikes 1.13. Kaffe's class library sources
trigger a bug in jikes 1.13 versions leading to the
verifier problems you are experiencing. Check out this
mail fr more information:
http://www.kaffe.org/pipermail/kaffe/2002-March/007730.html

The latest version of jikes should be o.k. too, but
you'd need to do some manual work in order to get it
to generate the type of class files kaffe can work
with. Jikes 1.18 generates Java 1.4 class files by
default, and they need some support methods kaffe
doesn't implement yet. My advice is to just use jikes
1.13, as that should just work.

best regards,

dalibor topic

__
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com

___
kaffe mailing list
[EMAIL PROTECTED]
http://kaffe.org/cgi-bin/mailman/listinfo/kaffe