Re: [PATCH] Unify sys_tkill() and sys_tgkill()

From: Jörn Engel
Date: Sat Sep 24 2005 - 11:40:28 EST


On Sat, 24 September 2005 16:52:28 +0200, Jesper Juhl wrote:
>
> [snip]
> > +static int do_tkill(int tgid, int pid, int sig)
>
> I would probably have made this
>
> static inline int do_tkill(int tgid, int pid, int sig)

Why? It would only return the original duplication in binary form and
save a minimal amount of time for something already slow - a system
call. With small caches, the code duplication could even waste more
performance than the missing function call would gain you.

Other nits were well-picked.

Jörn

--
You can't tell where a program is going to spend its time. Bottlenecks
occur in surprising places, so don't try to second guess and put in a
speed hack until you've proven that's where the bottleneck is.
-- Rob Pike
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/