Subject: Re: bug#17049: [PATCH] Make reverse! forego the cost of SCM_VALIDATE_LIST

From: Mark H Weaver <[email-masked]>
Date: Fri, 21 Mar 2014 00:38:46 -0400

Andy Wingo <[email-masked]> writes:

> On Thu 20 Mar 2014 12:23, David Kastrup <[email-masked]> writes:
>
>> +  /* We did not start with a proper list.  Undo the reversal. */
>
> I'm hesitant.  This is visible to other threads.  (Granted there has to
> be significant wrongness if we get here...)

If one thread attempts to access a list that's being destructively
reversed by another thread, the behavior is undefined.  Incidentally,
that's also the reason that your recent changes to 'for-each' are
defensible, Andy.  Therefore, I strongly believe this to be a non-issue.

I have yet to review this patch properly (except to notice that it does
not follow the GNU coding standards w.r.t. bracket placement, which
needs to be fixed), but based on the high-level description, it sounds
good to me, and also quite clever.

    Regards,
      Mark