A faster Python?, Python compiler, Dylan,...
Jan Kybic
kybic at ieee.org
Wed Apr 3 10:53:01 EST 2002
> > It would be so much easier if I could just compile parts of the
> ^^^^
> You make it sound so simple...
Well, translating something like:
def fib(a):
if a <= 2: return 1
else: return fib(a-2) + fib(a-1)
into:
int fib(int a) {
if(a <= 2) return 1;
else return fib(a-2) + fib(a-1); }
does indeed seem to be simple, once you know that 'a' is an integer.
> Have you looked at psyco?
Yes, very impressive once it does what it promises. It is more
ambitious than what I had in mind in that it does not use any
assistance (type information) from the programmer.
> Well, there was boundless (it made me exceed my quota on the mail
> server I was using ot the time) discussion on the types-sig on
> more-or-less this sort of topic a couple of years back, although
> perhaps more of the focus was on guaranteeing correctness than
> optimization. You could read that, but you don't want to.
Yes, I remember. I did not quite buy the correctness argument, runtime
checking is fine with me, but for a compiler it might be very useful, IMO.
> It's possible, perhaps even desirable, that psyco could be extended in
> this fashion. Got a spare man-month or so? I haven't.
No, neither have I, sorry. :-( Maybe later.
J.
--
-------------------------------------------------------------------------
Jan Kybic <kybic at ieee.org> Robotvis, INRIA, Sophia-Antipolis, France
or <Jan.Kybic at sophia.inria.fr>,tel. work +33 492 38 7589, fax 7845
http://www-sop.inria.fr/robotvis/personnel/Jan.Kybic/
More information about the Python-list
mailing list