kernels/linux-2.4.0/arch/mips/mm/r4xx0.c
/*
 * If you think for one second that this stuff coming up is a lot
 * of bulky code eating too many kernel cache lines.  Think _again_.
 *
 * Consider:
 * 1) Taken branches have a 3 cycle penalty on R4k
 * 2) The branch itself is a real dead cycle on even R4600/R5000.
 * 3) Only one of the following variants of each type is even used by
 *    the kernel based upon the cache parameters we detect at boot time.
 *
 * QED.
 */
If you think for one second that this stuff coming up is a lot
of bulky code eating too many kernel cache lines.  Think _again_.

1) Taken branches have a 3 cycle penalty on R4k
2) The branch itself is a real dead cycle on even R4600/R5000.
3) Only one of the following variants of each type is even used by
the kernel based upon the cache parameters we detect at boot time.

QED.
If you think for one second that this stuff coming up is a lot of bulky code eating too many kernel cache lines . Think _again_ . 1 ) Taken branches have a 3 cycle penalty on R4k 2 ) The branch itself is a real dead cycle on even R4600 / R5000 . 3 ) Only one of the following variants of each type is even used by the kernel based upon the cache parameters we detect at boot time . QED .
static inline void r4k_flush_cache_all_s16d16i16(void)
{
	unsigned long flags;
	save_and_cli(flags);
	blast_dcache16(); blast_icache16(); blast_scache16();
	restore_flags(flags);
}
static inline void r4k_flush_cache_all_s16d16i16 ( void ) { unsigned long flags ; save_and_cli ( flags ) ; blast_dcache16 ( ) ; blast_icache16 ( ) ; blast_scache16 ( ) ; restore_flags ( flags ) ; }
If you think for one second that this stuff coming up is a lot
 of bulky code eating too many kernel cache lines.
If you think for one second that this stuff coming up is a lot of bulky code eating too many kernel cache lines .