[Ecls-list] Slow prettyprinting (update)

Juan Jose Garcia-Ripoll jjgarcia at users.sourceforge.net
Thu Feb 14 23:03:11 UTC 2008


On Thu, Feb 14, 2008 at 8:02 PM, Waldek Hebisch
<hebisch at math.uni.wroc.pl> wrote:
> Juan Jose Garcia-Ripoll wrote:
>
> > On Thu, Feb 14, 2008 at 3:26 PM, Waldek Hebisch
>  > <hebisch at math.uni.wroc.pl> wrote:
>  > >   It looks that ECL version of 'assoc' is
>  > >   slower than 'assoc' in other Lisp implementations (probably 1.5 - 3
>  > >   times slower).
>  >
>  > Is this with user-provided test functions? Or using EQ, EQL or EQUAL?
>  >
>
>  I wrote: EQ.  I have now a little artifical test...

I have improved ecl_assq(), making it a bit larger but faster. Now it
should be around 2/3 of the original time (0.4 secs vs 0.7 secs
formerly in my machine). It cannot be faster without removing a check
to ensure that the argument list is indeed a list.

The SBCL is faster even with this test because of the way they
represent conses, which only requires a single integer test to ensure
that an object is of type CONS.

One could achieve the same speed by coding a compiler macro that
expands the call to ASSOC at the expense of reduced security.

Thanks for taking the time to analyze this. There may be other rough
spots, performancewise, because I do not have time to find them all.
Your help is really welcome.

Juanjo

-- 
Facultad de Fisicas, Universidad Complutense,
Ciudad Universitaria s/n Madrid 28040 (Spain)
http://juanjose.garciaripoll.googlepages.com




More information about the ecl-devel mailing list