That was just fun, but OK, I forgot the 'fun' tags... ;-)
> It's not that anyone hates them, it's that
> pass 1: the semantics (0 == empty cpu set) needed preserving
Well the original code already had 2 different semantics:
In the MP case it returned the mask of currently allowed CPUs which should
have been 1 for UP but was 0...
So as the value returned by apm_save_cpus() was only used for apm_restore_cpus
() I optimized it away. Which was just an other change of the semantics...ACK
> pass 2: remove code instead of changing redundant stuff
> NFI YTF gcc doesn't optimize out the whole shebang.
> At any rate, if we're pounding APM BIOS calls or apm_power_off()
> like wild monkeys there's something far more disturbing going wrong
> than 64B of code gcc couldn't optimize (it's probably due to some
> jump target being aligned to death or some such nonsense).
OK, I see you're right and your actual patch looks better to me because it
makes the semantics consistent! So come on and let's take it into the
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to firstname.lastname@example.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/