smalltalk
Optimizing HTTP header manipulation, part 2
In the previous post I told you how a couple of primitives (which means, modifications to the base classes) helped speeding up HTTP processing in Swazoo by a factor of 6.
Today I'll remove another part of it by modifying Swazoo itself. To remove Seaside, I used the simple "hello world" site that Swazoo serves if you start it with
gst-load --start=swazoodemo Swazoo
Hire and Fire
Whenever I write something like the following, I feel homesick for ruby, where I never have to close files by myself.
|stream| stream := FileStream fopen: 'registry.dump' mode: #write. [ ObjectDumper dump: registry to: stream ] ensure: [ stream close ]
Would anybody else beside me consider the following (fancily named) pattern useful?
Object [
hire: aBlock fire: cleanup [
^ [ aBlock value: self ] ensure: [ cleanup cull: self ]
]
]OnlineTester: Benchmarking
This post describes a session measuring the behavior of an Iliad web application using AJAX request. Memory consumption and run time were investigated for different numbers of simultaneous users.
Spoiler
Memory usage has drastically improved since the first public test session, it is down by about 50%. There is still some room for improvement, but the changes of the last two weeks have been impressive. As far as speed and stability is concerned, the application performs very well, even under (relatively) heavy load.
GNU Smalltalk running under Wine
Well, the summary says it all. . The first small steps were done quite some time ago, by rewriting every shell script that did not really need the shell in C or Smalltalk. Yesterday I finished the job, so that now it's possible to just do ../configure --host=i686-pc-mingw32 && make.
It took a while for two reasons: first because I overlooked wineconsole and it turns out it's a crucial step to running GNU Smalltalk under Wine; second, because GNU Smalltalk runs at build time, and it has to interact with the Unix paths.
Vim and gst REPL
There is an extremely valuable (and small) vim plugin slime.vim out there, with a nice description of the how, why and what at the author's site: http://technotales.wordpress.com/2007/10/03/like-slime-for-vim/
With this simple plugin, you can edit your code in a vim "worksheet" and send it over to *any* REPL (bash, gst, sbcl, vim, ...) that is running in a screen session.
