From: Eivind Eklund Date: 2004-02-25T23:19:53+09:00 Subject: Thread-safe hashes (was Re: rehash segfault) On Wed, Feb 25, 2004 at 10:13:00PM +0900, Yukihiro Matsumoto wrote: > In message "Re: rehash segfault" > on 04/02/25, Eivind Eklund writes: > |Would this be an acceptable extra cost? > > I think so. "delete_if" etc. might make things difficult. I believe full iterations would have to be sequenced alongside rehash; ie, a rehash would have to block until the full iteration is finished, and new full iterations would have to block until the rehash is finished. At the moment these cases would cause crashes, so slowing them down probably is OK. (If not, I've got some ideas that might work, but they add significant amounts of complexity, slows down the normal case, and waste memory. I'd prefer to just use force things to be sequential for this case.) Eivind.