Review
Jayachandran C.
c.jayachandran at gmail.com
Fri Jul 16 04:37:16 UTC 2010
On Fri, Jul 16, 2010 at 3:49 AM, M. Warner Losh <imp at bsdimp.com> wrote:
> OK. Please find enclosed a minor cleanup diff for assembler files.
> It moves ITLBNOPFIX and HAZARD_DELAY into a common header, as well as
> replacing MIPS_CPU_NOP_DELAY with HAZARD_DELAY.
>
> The only real change is increasing the number of nops in a few places
> from 4 to 5.
>
> This is in preparation for making these (a) much shorter and (b)
> optimizing for specific CPUs... mips32/mips64 define ssnop to deal
> with the super-scaler effects (so ITLBNOPFIX can be shorter), and
> mips32r2 and mips64r2 have eh, which can help with HAZARD_DELAY.
>
> The latter will need some careful study of the docs to make sure that
> the proper number of instructions are executed (which is why I'm not
> doing it yet :). The former is just shuffling deck chairs, so should be
> invisible to people.
>
> Comments?
There is a mips_barrier() in cpufunc.h too which does similar things -
and is confusingly named - we can to get rid of that too in a similar
way.
Another cleanup I wanted to do for sometime is to get the status
register settings into a header files and avoid the ifdef everywhere.
Maybe cpuregs.h (or cpufunc.h) can add cpu_xlr.h/cpu_octeon.h etc
which will have hazard/status/extra registers for the specific cpu.
Thanks,
JC.
More information about the freebsd-mips
mailing list