Subject: Re: VM change for R4000
To: None <port-mips@netbsd.org>
From: Toru Nishimura <locore64@alkyltechnology.com>
List: port-mips
Date: 03/12/2005 01:59:54
Izumi Tsutsui said;

> At least OpenBSD's mips64/pmap.c still uses UNCACHED mappings
> to avoid virtual aliases in pmap_enter_pv(), so IMHO thier
> MI VM doesn't care about VIPT cache.

I think it's plain non-sense.

There is no need to invent mips64/ tree.  All we need is two different
pmap.c, one for 32 bit (R3000 and 32bit R4000) and another for
64 bit LP64.  n32 is a part of the latter case.  All other files would be
confortably conditionalized by sizeof(register_t) and _LP64.

Jason T. said;

> The Alpha pmap does use a 3-level table in the pmap module itself, and 
> uses KSEG to access those pages.  That could prove a bad strategy with 
> MIPS, since you could end up with incompatible virtual aliases (KSEG 
> address vs. VPT address).

It's impossible to implement 64bit mips pmap.c by porting NetBSD/alpha
code since alpha cache has never been VIPT.

As far as VM forces "index match rule" to all VA (including 2nd or more
sharing VA) and PA, mixing KSEG access and VA access will make no
virtual alias condition.

Toru Nishimura/ALKYL Technology