This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: Applications


This still looks like an inner class miscompilation, though I haven't looked
at it in detail. 

UnaryCRFunction.java contains mostly two (conceptually higher order)
functions to invert or take the derivative of a function on constructive
reals.  Both of those use hairy inner classes.  I don't think anything else
does.

Should this work?  Or are there known inner class issues remaining?  Other
examples might be easier to debug.  If there aren't any others, I'll try to
take a look at it.

Hans

> -----Original Message-----
> From: Bryce McKinlay [mailto:bryce@albatross.co.nz]
> Sent: Monday, March 19, 2001 9:41 PM
> To: Boehm, Hans
> Cc: 'Jeff Sturm'; Per Bothner; tromey@redhat.com; Java Discuss List
> Subject: Re: Applications
> 
> 
> "Boehm, Hans" wrote:
> 
> > Another small one that has helped me find some bugs in the 
> past is the
> > constructive reals calculator I wrote at SGI.  (Now at
> > http://www.hpl.hp.com/personal/Hans_Boehm/crcalc/ ) Both 
> the included
> > (small) test program and the command line version (added at 
> HP) should build
> > with gcj from .class files.  Eventually they should build 
> from sources.  (I
> > believe there were problems with inner classes in the past. 
>  I haven't tried
> > very recently.)
> 
> FYI, it compiles fine from source, except for the CRCalc 
> class (due to a few
> missing AWT bits and incorrect complaints about finals which 
> may just be a side
> effect of the missing classes):
> 
> $ gcj com/sgi/math/*.java -O2 --main=rpn_calc
> $
> 
> and seems to basically work:
> 
> $ ./a.out
> 2 3 +
> 5.00
> 9481923 223 /
> 42519.83
> 
> But the TestCR crashes. Seems it gets stuck in an infinate 
> loop between these
> two calls:
> 
> #11 0x08050f5d in
> com.sgi.math.monotoneDerivative_UnaryCRFunction$monotoneDeriva
tiveCR.monotoneDerivative_UnaryCRFunction$monotoneDerivativeCR>
(com.sgi.math.monotoneDerivative_UnaryCRFunction,
> com.sgi.math.CR) (this=0x81c2078,
>     this$0=0x818eab0, x=0x80aeb58) at 
> com/sgi/math/UnaryCRFunction.java:609
> #12 0x0805185a in
> com.sgi.math.monotoneDerivative_UnaryCRFunction.execute(com.sg
> i.math.CR)
> (this=0x818eab0, x=0x80aeb58)
>     at com/sgi/math/UnaryCRFunction.java:655
> 
> gij runs it correctly on class files produced by javac, so 
> there could be a
> miscompilation somewhere...
> 
> regards
> 
>   [ bryce ]
> 
> 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]