Re: matlisp sbcl patch part 2

[email protected] Thu, 12 Feb 2004 15:38:25 -0800
Newsgroups gmane.lisp.matlisp.user
Message-ID <[email protected]>
Hi Ray,

I've been exchanging email with Robbie, who did
the sbcl port of matlisp.  I installed sbcl and
compiled matlisp.  Sbcl gives 3 errors, but loads
the files anyway.

These are in the f2cl generated code.  Sbcl doesn't
like declarations of this kind:

(function (or double-float array-double-float) (values double-float))

Robbie's analysis of the situation is below. The main question
that I can't answer is: "is this a legit lisp type?"
If it is, then note that neither allegro nor cmu have complained.

  --Tunc

----- Original Message -----
From: Robbie Sedgewick <[email protected]>
Date: Thursday, February 12, 2004 3:05 pm
Subject: Re: [Matlisp-users] matlisp sbcl patch part 2

> 
> I think I see the problem.  The example I gave you before didn't have
> the important part.  The types that sbcl doesn't like are all 
> something like
> (function (or double-float array-double-float) (values double-float))
> 
> which sbcl interprets as a function which take 3 arguments, the first
> of type 'or.  As the website you sent me says, by it self 'or is 
> not a
> valid type.
> 
> The declaration was probably supposed to be written as 
> (function ((or double-float array-double-float)) (values double-
> float))which only takes one argument.
> 
> FYI the only affected files are quadpack/dqc25f.lisp, 
> quadpack/dqawfe.lisp,and minpack/r1updt.lisp
> 
> 
> --Robbie
> 
> At Thu, 12 Feb 2004 14:46:55 -0800,
> Tunc Simsek wrote:
> > 
> > It seems legit:
> > 
> > 
> http://www.franz.com/support/documentation/6.2/ansicl/dictentr/or.htm> 
> > It doesn't mean that (or type-foo type-bar) is a useful
> > declaration though.
> > 
> > 
> > 
> > ----- Original Message -----
> > From: Robbie Sedgewick <[email protected]>
> > Date: Thursday, February 12, 2004 2:18 pm
> > Subject: Re: [Matlisp-users] matlisp sbcl patch part 2
> > 
> > > 
> > > Yeah, sbcl can be very verbose.  I normally run sbcl in a 
> emacs so I
> > > can search back for the errors.
> > > 
> > > Anyway, assuming your three error are the same as the three 
> error I
> > > see, they are all errors about "The symbol OR is not valid as 
> a type
> > > specifier". They occur because at 3 places in the lisp code to 
> minpack> > and quadpack something is declared to have type '(or 
> type-foo
> > > type-bar).  I'm not sure if this is valid lisp or not, but sbcl
> > > doesn't like it.
> > > 
> > > I think that the files gets loaded fine, although I haven't 
> tested the
> > > minpack or the quadpack functionality.  I could patch these 
> files to
> > > fix this, but I don't know if you want to modify these files since
> > > they look automatically generated.
> > > 
> > > We could also probably just ignore them.  Your call.
> > > 
> > > --Robbie
> > > 
> > > 
> > > 
> > > At Thu, 12 Feb 2004 13:51:09 -0800,
> > > Tunc Simsek wrote:
> > > > 
> > > > 
> > > > Hi again.  I installed sbcl 0.8.7 on redhat x86.
> > > > Then I downloaded the matlisp.sbcl.tar file from your
> > > > homepage.  
> > > > 
> > > > 1. sbcl was built fine and passed the automated test
> > > > 2. when I built matlisp, it compiled everything
> > > >  but at the end reported that 3 errors was caught.
> > > >  Unfortunately, sbcl outputs so many messages (warnings, notes)
> > > >   that I can't scroll up the terminal to find what the
> > > >  error messages are.
> > > > 
> > > >  However, the basic matlisp functions seem to work fine.
> > > >  Like eigenvalue, svd and so forth, but I didn't try the
> > > >  complex numbers.  complex numbers is where the bugs usually
> > > >  show up.
> > > > 
> > > > Do you have anyway to find what those error messages were?
> > > > 
> > > > Tunc
> > > > 
> > > > ----- Original Message -----
> > > > From: Robert Sedgewick <[email protected]>
> > > > Date: Wednesday, February 11, 2004 10:19 pm
> > > > Subject: Re: [Matlisp-users] matlisp sbcl patch part 2
> > > > 
> > > > > 
> > > > > On Feb 12, 2004, at 12:49 AM, [email protected] wrote:
> > > > > 
> > > > > > Sorry for responding so late by the way.  I'm busy
> > > > > > with my dissertation and looking for a job at the same
> > > > > > time.
> > > > > 
> > > > > Yeah, no kidding, I bet you are swamped.  I had to go 
> through 
> > > that 
> > > > > stuff last year (UCSB physics).  Good luck.
> > > > > 
> > > > > > For someone who doesn't use matlisp you've done
> > > > > > a pretty thorough job with the port!  But give me
> > > > > > some time to go through the modifications to double
> > > > > > check, make sure you didn't miss anything.
> > > > > 
> > > > > Well, I hope to use it more in the future!
> > > > > 
> > > > > Also, I do use a hacked up version of the matlisp ffi to 
> > > interface 
> > > > > to 
> > > > > my c code in a monte carlo program that I work on.
> > > > > 
> > > > > 
> > > > > > So, to try this on sbcl, should I get sbcl from
> > > > > > sourceforge.  I think they have a single release
> > > > > > there.  I only have redhat linux on an x86, I wonder
> > > > > > whether this will make a difference.  Anyway, I'll keep
> > > > > > in touch.
> > > > > 
> > > > > That should work too.  I've tested matlisp with sbcl on 
> debian 
> > > > > linux 
> > > > > x86 and it worked fine.
> > > > > 
> > > > > I dunno why they don't have a rpm of a more recent 
> version, 
> > > but 
> > > > > 0.8.6 
> > > > > isn't all that old.
> > > > > 
> > > > > --Robbie
> > > > > 
> > > > > 
> > > > > >   --Tunc
> > > > > >
> > > > > > ----- Original Message -----
> > > > > > From: Robbie Sedgewick <[email protected]>
> > > > > > Date: Wednesday, February 11, 2004 2:44 pm
> > > > > > Subject: Re: [Matlisp-users] matlisp sbcl patch part 2
> > > > > >
> > > > > >>
> > > > > >> Hi Tunc,
> > > > > >>
> > > > > >> Thanks for emailing.  It will be nice to get this patch 
> > > into cvs.
> > > > > >>
> > > > > >> I made the port because (at the time) cmucl was not 
> > > available 
> > > > > for PPC.
> > > > > >> I tend to use sbcl on x86 as well so I can use the same 
> lisp> > > > >> implementation on both my computers.  I have a 
> couple 
> > > projects that
> > > > > >> are numerical in nature that I wanted to use lisp for 
> so I 
> > > > > wanted try
> > > > > >> to matlisp.  I actually haven't had the opportunity to 
> use 
> > > it 
> > > > > all that
> > > > > >> much yet, but I think that will change with my next 
> project.> > > > >>
> > > > > >> I doubt I broke any cmucl stuff.  Most of the changes 
> were 
> > > just 
> > > > > adding>> #+sbcl parts to the existing #+cmu and #+acl.  
> I've 
> > > tried 
> > > > > my changes
> > > > > >> with cmucl (x86 only) and it seemed to work fine, 
> although 
> > > I didn't
> > > > > >> torture test it.  cmucl/ppc is probably still a little 
> too 
> > > > > buggy to
> > > > > >> expect it to work....
> > > > > >>
> > > > > >> You do have the new verison of the patch right?  The 
> one 
> > > that 
> > > > > got sent
> > > > > >> out on the mailing list got corrupted by the sf.net 
> mail server
> > > > > >> because it was too long.  I think the new one was made 
> around> > > > >> 12/15/03.  Also the ffi-sbcl.lisp file on the 
> list got 
> > > truncated.> > >> There are good versions of the patch, the ffi-
> > > sbcl.lisp file 
> > > > > and a
> > > > > >> good tarball at http://mercury.chem.pitt.edu/~rds/
> > > > > >>
> > > > > >> Thanks,
> > > > > >>
> > > > > >> Later,
> > > > > >> Robbie
> > > > > >>
> > > > > >> At Wed, 11 Feb 2004 11:28:57 -0800,
> > > > > >> Tunc Simsek wrote:
> > > > > >>>
> > > > > >>> Hi Robbie,
> > > > > >>>
> > > > > >>> I just got a chance to look at your patches.  It looks 
> really> > > > >> really
> > > > > >>> good.  I have a few questions though.  First, what 
> > > motivated you
> > > > > >> to port
> > > > > >>> matlisp to sbcl?  Second, you've made modifications to 
> > > lots of
> > > > > >> files.> Especially places where complex double-float 
> > > appears.  Did
> > > > > >> you test
> > > > > >>> your changes on cmucl after making them?
> > > > > >>>
> > > > > >>> I will soon try to download and install sbcl and apply 
> > > your 
> > > > > patches.>>> I'll let you know if i need help.
> > > > > >>>
> > > > > >>> Thx again, Tunc
> > > > > >>>
> > > > > >>
> > > > > >
> > > > > 
> > > > > 
> > > > 
> > > 
> > 
> 



-------------------------------------------------------
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click