On Mon, Jun 30, 2008 at 12:30 PM, nathan binkert <[EMAIL PROTECTED]> wrote:
>> Another option would be to have a boolean that said if it needed to be
>> atomic or not. If you knew that the object wouldn't span threads it
>> wouldn't need to be set or perhaps at the point when it changed
>> threads it could be set. The logic needs to be a bit better than
>> atomic inc/dec since you could possibly have double free case if you
>> aren't careful.
> Yes, you'd need a decrement and test or something like that.

Typical atomic inc/dec semantics are that the operation returns the
value immediately before or after the atomic op (really "fetch and
inc/dec" is more descriptive).

Steve
_______________________________________________
m5-dev mailing list
m5-dev@m5sim.org
http://m5sim.org/mailman/listinfo/m5-dev

Reply via email to