[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: PATCH: Fully Resumable VM (yield across pcall/callback/meta/iter)
- From: skaller <skaller@...>
- Date: 16 Feb 2005 01:50:21 +1100
On Wed, 2005-02-16 at 01:15, David Burgess wrote:
> Your platform and compiler?
> On Tue, 15 Feb 2005 14:
> > One million setjmp/longjmp plus the surrounding overhead easily complete
> > in one and a half seconds on my machine.
> > But one million C++ try/catch/throw need more than a minute (!) to complete.
> > Yuck!
So? One is a primitive low level operation,
the other is a much higher level. C++ handles
stack unwinding, selective catching on type,
multiple levels of handlers, and decoupled
throwing and catching.
By comparison, Felix error handling is potentially
thousands of times faster than setjump/longjump.
(In fact the Alioth test, adjusted for startup
time, ran in -0.4 seconds or something silly)
John Skaller, mailto:email@example.com
snail: PO BOX 401 Glebe NSW 2037 Australia
Checkout the Felix programming language http://felix.sf.net