Path: utzoo!utgpu!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!bloom-beacon!KLEPH.AI.MIT.EDU!cph From: cph@KLEPH.AI.MIT.EDU (Chris Hanson) Newsgroups: comp.lang.scheme Subject: Scheme Digest #8, Efficiency of Y Message-ID: <8811161012.AA13091@kleph.ai.mit.edu> Date: 16 Nov 88 10:12:11 GMT Sender: daemon@bloom-beacon.MIT.EDU Reply-To: cph@zurich.ai.mit.edu Organization: The Internet Lines: 22 Date: Tue, 15 Nov 88 10:26:46 EST From: kranz@wheaties.ai.mit.edu (David Kranz) Edward Wang is correct that the time in the example is dominated by bignum arithmetic. I changed the * in factorial to + and got the following result in T3.1: I tried a similar experiment in MIT Scheme (using + instead of *, except a smaller loop to account for smaller fixnums), with the following results: (factorial-loop 100) -> 1.03 msec (factorial-rec 100) -> 1.0 msec (factorial-lfp 100) -> 2.74 msec Bill Rozas has expended no small effort in the MIT Scheme compiler to make the Y combinator produce good results, and these timings are evidence of that. Still not perfect, but I believe Bill claims that he can make the output code identical given a bit more work.