Compile time function execution...
Michiel
nomail at please.com
Sat Feb 17 01:24:49 PST 2007
janderson wrote:
>> 2) A function that simply takes too long at compile time. Compile time
>> execution is going to be >100 times slower than run time.
>
> One thought on this. What about leveraging multiple threads to
> calculate different algorithms at once. They should all be self
> contained, so this shouldn't be much of a problem. With the quad-cores
> the compiled program would run maybe at 30 times slower. Also its a
> good step towards future-proofing the compiler.
And I'm not 100% sure why you can't compile those functions and run
another process to do the algorithms. Not with an interpreter, but with
compiled D code.
If course, I wouldn't know how to actually do that, but in theory it's
possible.
--
Michiel
More information about the Digitalmars-d
mailing list