Messages in this thread | | | Date | Fri, 13 Oct 2006 02:10:15 -0400 (EDT) | From | "Robert P. J. Day" <> | Subject | Re: [PATCH] Redefine instances of sema_init() to use standard form. |
| |
i can't believe a simple cleanup patch has turned into such an issue.
On Fri, 13 Oct 2006, Roman Zippel wrote:
> Hi, > > On Thursday 12 October 2006 09:44, Robert P. J. Day wrote: > > > Since there seems to be no compelling reason *not* to do this, > [..] > > - /* > > - * Logically, > > - * *sem = (struct semaphore)__SEMAPHORE_INITIALIZER((*sem),val); > > - * except that gcc produces better initializing by parts yet. > > - */ > > You've seen this?
in fact, i did, and i admit that i have no idea what it means to say that "gcc produces better initializing by parts yet."
there were a number of semaphore.h files whose comments made it clear that GCC 2.7.2.3 was the *only* reason that the shorter, more direct form wasn't being used, so it should be clear that those could be changed.
there was only *one* of those header files (asm-alpha/semaphore.h) that had the caution above, but i have no idea what "better initializing" means?
"better" as in faster? "better" as in more compact? "better" as in correct? i mean, either the shorter, more direct initialization *works* and produces the same result in this case, or it *doesn't*. which is it? or is that note perhaps a holdover from an old version of gcc as well?
can you clarify what that comment means in the context of the alpha architecture, and why simplifying the call would actually be a mistake?
rday - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |