Messages in this thread | | | Date | Wed, 12 Jan 2000 22:48:36 +0100 | From | Pavel Machek <> | Subject | Re: [idea] request_module(const char *fmt, ...); |
| |
Hi!
> > I'd be inclined to change request_module to take multiple arguments, but still > > to leave it defined as a NOP in the !CONFIG_KMOD case. That way, all the code > > gets cleaned up, but you don't incur the extra function call cost. > > No, because that would make everything that includes kmod.h depend on > CONFIG_KMOD. The best way we found so far (based on Keith's
Is that really problem? Extra function call cost is small, but
*) that if () is then compiled in, also
*) it's _runtime_ cost is small, but it is still unneccessary bytes in kernel.
> to have just one request_module() function which treats variable arguments > and is reduced to return -EINVAL if CONFIG_KMOD is not defined. This way > all the knowledge about CONFIG_KMOD is concentrated in kmod.c. Also, > kmod.h header should vanish and request_module() live in module.h > > > I appreciate that the cost of that function call isn't exactly high - but it's > > not exactly necessary either. When you change to/from CONFIG_KMOD, you expect > > to have to recompile some files. It's not the end of the world. > > It may well be the end of the world, if you only have 4 seconds to repair > some nuclear missile system (powered by Linux) and recompiling the whole > kernel will take 25.1 seconds if everything depends on > CONFIG_KMOD....
You are not going to save the world by nuclear missile system...
> > Except in exceptional cases, run-time performance is far more important than > > compilation time, surely? > > those exceptional cases, e.g. loading a binary will be given a bit more > thought and performance analysis. If we find less than 0.01% degradation > then the beauty argument wins. (I hope).
You forgot about kernel _size_. Pavel -- I'm pavel@ucw.cz. "In my country we have almost anarchy and I don't care." Panos Katsaloulis describing me w.r.t. patents me at discuss@linmodems.org
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |