Re: Optimal multi-logical-processor scheduling
Posted: Sat Sep 27, 2008 12:26 pm
Hi,
Then there's the problem that all forms of abstraction have - inefficiency caused by a mismatch between intended usage and desired usage. For example, if I were using POSIX threads to do the same as the example above then I'd use "pthread_join()", but in that case there'd be a main thread that would be constantly blocking and restarting while it waits for each of the other threads to finish (and the overhead/inefficiency caused by the additional thread switches).
Of course there's a huge number of different things programmers can do that will hurt performance in some way. An OS can't stop programmers from writing bad code without becoming a bloated mess itself.
Out of curiosity, what sort of features are you planning to support in your kernel to assist with profiling and performance monitoring?
Cheers,
Brendan
I guarantee you that a significant portion of them will still mess it up - e.g. calling your function much more than necessary and/or using it in an inappropriate way.Colonel Kernel wrote:That's easy. By putting it in the kernel, you don't have to entrust programmers who are far less talented and experienced than you to write that kind of code ever again. Therefore, it is improved.Brendan wrote:Show me how this can be improved by "centralizing the RFO in the kernel"....
A library would work too... As long as you're providing some kind of abstraction that doesn't force app developers to twiddle with counters in shared memory. I guarantee you that a significant portion of them will mess it up.
Then there's the problem that all forms of abstraction have - inefficiency caused by a mismatch between intended usage and desired usage. For example, if I were using POSIX threads to do the same as the example above then I'd use "pthread_join()", but in that case there'd be a main thread that would be constantly blocking and restarting while it waits for each of the other threads to finish (and the overhead/inefficiency caused by the additional thread switches).
Of course there's a huge number of different things programmers can do that will hurt performance in some way. An OS can't stop programmers from writing bad code without becoming a bloated mess itself.
Out of curiosity, what sort of features are you planning to support in your kernel to assist with profiling and performance monitoring?
Cheers,
Brendan