So dmd-cc. Whats your opinion on an optimistic concurrency? Heavy exlusive transactions on not allways ideal but an optimistic based approach allows more computation to just keep on running.<br><br>This sort of approach which is sometimes called STM (software
transactional memory) can crunch a whole lot more numbers if we think
"this lock is probably not in use by anyone else, just go for it":<br><br>1) Save a copy/hash of the computations dependencies (arguments to functions that are passed by ref)<br>2) Do the computation.<br>3) If dependencies have changed go to step 1 else commit.<br>
<br>If such algorithms were implemented they should preferably be made implicit with algorithms generic enough for handling any kind of arguments, rolling back etc. If the function doesn't modify any state other than the target result then this could reduce complexity a lot but not necessarily impossible to do with other styles.<br>
<br>I'm not sure if the semantics of D's current pure function implementation could be the base of such algorithms but how much of a speedup is the current D pure optimizations giving us anyway?<br>