Messages in this thread | | | Date | Fri, 29 Oct 2004 13:08:22 -0400 (EDT) | From | linux-os <> | Subject | Re: Semaphore assembly-code bug |
| |
On Fri, 29 Oct 2004, Andreas Steinmetz wrote:
> Linus Torvalds wrote: >> >> On Fri, 29 Oct 2004, linux-os wrote: >> >>> Linus, please check this out. >> >> >> Yes, I concur. However, I'd suggest changing the "addl $4,%esp" into a >> "popl %ecx", which is smaller and apparently faster on some CPU's (ecx >> obviously gets immediately overwritten by the next popl). > > Hmm, I didn't check the instruction length but modern CPUs usually work best > with the following: > > leal 4(%esp),%esp > > -- > Andreas Steinmetz SPAMmers use robotrap@domdv.de >
Probably so because I'm pretty certain that the 'pop' (a memory access) is not going to be faster than a simple register operation.
I'll make another patch and post it (if the machine will boot!)
Cheers, Dick Johnson Penguin : Linux version 2.6.9 on an i686 machine (5537.79 BogoMips). Notice : All mail here is now cached for review by John Ashcroft. 98.36% of all statistics are fiction. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |