[Top][All Lists]

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

Re: Redundant type checking in window.c and w32menu.c

From: Dmitry Antipov
Subject: Re: Redundant type checking in window.c and w32menu.c
Date: Thu, 21 Jun 2007 19:46:32 +0400
User-agent: Thunderbird (X11/20061008)

Jason Rumney wrote:

dmantipov wrote:
Jason Rumney wrote
Dmitry Antipov wrote:

+#define Fcar(c) _FCAR (c)
+#define Fcar_safe(c) _FCAR_SAFE (c)
+#define Fcdr(c) _FCDR (c)
+#define Fcdr_safe(c) _FCDR_SAFE (c)
How does lisp code then call these C macros?
It will call original functions which are preserved in data.c. Lisp code calls 
them via pointers, so we definitely need to preserve an addressable versions.

Is this optimisation really worth the confusion of having two versions
of these functions in the code?

YMMV :-) - since these functions has the only arg, we shouldn't loose too much
on passing an arguments and performing the call. Probably this also depends
on compiler options passed and even from the compiler's version.

Another interesting thing to try (probably x86 only) is to use
__attribute__((regparm (1))) and see what happens...


reply via email to

[Prev in Thread] Current Thread [Next in Thread]