DragonFly submit List (threaded) for 2008-02
DragonFly BSD
DragonFly submit List (threaded) for 2008-02
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: lwkt_token_is_stale patch


From: Matthew Dillon <dillon@xxxxxxxxxxxxxxxxxxxx>
Date: Fri, 29 Feb 2008 11:29:33 -0800 (PST)

:Hi,
:
:Now that the release is over, is there any chance that the following 
:patch gets commited?
:
:   http://leaf.dragonflybsd.org/mailarchive/kernel/2008-02/msg00015.html

    Absolutely.  I'll check it out right now.

:Any feedback is welcome!
:
:And the possible race for UP I describe in the mail:
:
:   http://leaf.dragonflybsd.org/mailarchive/kernel/2008-02/msg00013.html
:
:Do you think this can happen?
:
:Regards,
:
:   Michael

    Hmm.  Yes, if the compiler breaks the operation down into multiple
    instructions the decrement could get lost.  The compiler will virtually
    never do that, but the only way for us to guarantee that it doesn't
    (that is, to guarantee that the decrement is performed with a 
    single instruction) is to call the atomic_subtract_int_nonlocked()
    inline.

    I will make that change.

					-Matt
					Matthew Dillon 
					<dillon@backplane.com>



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]