|
From: | Clinton Ebadi |
Subject: | Re: Weak Vectors Patch |
Date: | Sat, 17 Apr 2010 14:36:01 -0400 |
User-agent: | Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) |
address@hidden (Ludovic Courtès) writes: > For these last two things, we’d need to modify the ‘vector-ref’ and > ‘vector-set’ instructions so that they do the right thing. The best > solution would be to just call scm_c_vector_{ref,set_x} when > SCM_I_WVECTP, so that the overhead remains low for regular vectors. Can > you look into this? Wingo did this. >> I'm not sure that weak vectors should have their allocated memory marked >> as containing no pointers, but it seems to work so I left that alone in >> case there was some magic going on that I didn't quite grok. > > Yes, weak vectors are to live in pointerless memory, otherwise the > disappearing links would not disappear. > > The patch looks good to me, modulo a few things: > > - Could you make it 3 (or 4?) different patches, each with a test case > showing what is being fixed? > > - If that’s fine with you, you’ll need to assign copyright to the > FSF. We can arrange this off-list. I have attached a series of three patches with reformatted GNU style commit logs and the gnu coding style violations fixed. I talked to wingo, and he suggested that (equal? WEAK-VECTOR VECTOR) => #f; I have made this so by unregistering weak vectors as arrays, and doing additional type checking in scm_eq. I am unsure if this has ramifications for the rest of the system however. How do you want to handle copyright assignment?
0001-Forbid-comparison-of-weak-and-normal-vectors.patch
Description: Text Data
0002-Register-disappearing-links-when-initializing-weak-v.patch
Description: Text Data
0003-Reference-weak-vectors-with-the-allocator-lock-held.patch
Description: Text Data
-- Corinne: this is why we should have designated bath buddies Corinne: to get places you cant reach because youre slippery and in case you get a lil tooo slippery and crack your head open someone can call the coast guard and save you
pgpjIS3cHrJnR.pgp
Description: PGP signature
[Prev in Thread] | Current Thread | [Next in Thread] |