[parisc-linux] [PATCH] timer_interrupt and gettimeoffset.
John David Anglin
dave at hiauly1.hia.nrc.ca
Sun Sep 3 18:58:41 MDT 2006
> > GCC didn't do a great job of optimizing the code. I think we would
> > get better code if clocktick and halftick were copied to temps before
> > the irqsave.
>
> hrm...I would expect the same result from __read_mostly but can understand
> why that's not as useful as I hoped.
They are getting relead on every use.
> Can we tell GCC that clocktick doesn't change during execution of this code?
> ie despite being a global, it's a "constant" and doesn't need to be
> reloaded on each loop iteration?
I think it's tricky. Constants go in readonly data. However, the
values need to be initialized at runtime. Copying the values to
"register" tempories before the loop seems to resolve the problem.
Dave
--
J. David Anglin dave.anglin at nrc-cnrc.gc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6602)
More information about the parisc-linux
mailing list