Re: Object Euphoria optimiztion
-----Original Message-----
From: Jiri Babor <J.Babor at GNS.CRI.NZ>
To: EUPHORIA at LISTSERV.MUOHIO.EDU <EUPHORIA at LISTSERV.MUOHIO.EDU>
Date: Thursday, February 10, 2000 6:39 PM
Subject: Re: Object Euphoria optimiztion
>Mike,
>
>You must be kidding! Only on very rare occasions this sort of thing
>can be accomplished in real life without mirrors.
>
>So I have this 2500 element sequence full of random data and I am
>looking for the first occurrence of a particular pattern. How on earth
>do I construct the index sequence to perform your magic. My data can
>be anything, any length. How do I divide it into your neat little
>parcels? And why just 50, why not a full 100? The savings will be
>even greater!
>
>jiri
Jiri,
My example is admittedly artificial--the real world issue was whether OE
should use a single symbol table for namespaces, classes, members, and
methods rather than the mutiple symbol tables in the current design. My
original thought was that this would run faster because less subscripting
would be required--this and other benchmarks proved this idea to be in
error.
How this works: let's say I'm seaching for the Print method of class
Alpha--the one approach would search for Alpha.Print in a single, very long
symbol table; the other searches for Alpha in the class table, then uses the
result to search the correct subsequence of the method table. The savings
won't be so dramatic in small applications with fewer than 50 classes with
50 methods each--but look at the C++ or Java source code for some real
world programs--my numbers are by no means impossible.
--Mike
|
Not Categorized, Please Help
|
|