[racket] Performance difference between BSL and #lang racket

From: Jordan Johnson (jmj at fellowhuman.com)
Date: Thu Jan 12 14:48:31 EST 2012

Hi all,

A student presented me this morning with an implementation he'd written of Pong, which, after about a minute and a half of running (in BSL) was so slow on his Mac that it was unusable; specifically, the apparent speed slowed down a lot, and the game stopped responding to key input.  I found the same thing happened on Win 7, but if I ran the same program under #lang racket, no such slowdown occurred.  It appears that there's some memory growth over time (maybe about 1K per five or ten seconds) in BSL too.

What language difference(s) might be responsible for the vast performance difference we're observing?  If it would be helpful to see the code I can share it, but it's about 1000 LoC and I don't think it's proper to post it publicly.  I've tried to construct a small program that shows the same difference, but haven't managed; I don't, however, see anything in his code that would be obviously responsible.

Thanks for any insight you might be able to offer.

Best,
Jordan


Posted on the users mailing list.