* [9fans] port/allocb.c question
@ 2009-12-09 16:55 Venkatesh Srinivas
2009-12-09 17:59 ` Charles Forsyth
0 siblings, 1 reply; 3+ messages in thread
From: Venkatesh Srinivas @ 2009-12-09 16:55 UTC (permalink / raw)
To: Fans of the OS Plan 9 from Bell Labs
Hi,
In _allocb() in port/allocb.c, there is an _xinc(&b->ref) on a long
inside the Block header. No one else ought have a pointer to this
block yet, seeing as its not done being allocated. Is there any reason
a locked increment is being used?
-- vs
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [9fans] port/allocb.c question
2009-12-09 16:55 [9fans] port/allocb.c question Venkatesh Srinivas
@ 2009-12-09 17:59 ` Charles Forsyth
2009-12-09 20:23 ` geoff
0 siblings, 1 reply; 3+ messages in thread
From: Charles Forsyth @ 2009-12-09 17:59 UTC (permalink / raw)
To: 9fans
>Is there any reason a locked increment is being used?
good question. i thought it might be a new tradition.
i don't think it's needed.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [9fans] port/allocb.c question
2009-12-09 17:59 ` Charles Forsyth
@ 2009-12-09 20:23 ` geoff
0 siblings, 0 replies; 3+ messages in thread
From: geoff @ 2009-12-09 20:23 UTC (permalink / raw)
To: 9fans
I think it's just the idiom we adopted when we added reference
counting.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2009-12-09 20:23 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-12-09 16:55 [9fans] port/allocb.c question Venkatesh Srinivas
2009-12-09 17:59 ` Charles Forsyth
2009-12-09 20:23 ` geoff
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).