ZOG with the JCACHE interface
David Betz
Posts: 14,516
I'm trying to steal the ZOG interface to jazzed's JCACHE cache driver for use in a basic interpreter that I'm writing and I think I have found a problem with it. The ZOG read_long and write_long functions use a variable called cacheaddr to remember the last address translation that was performed by JCACHE to avoid doing a cross-COG call if the next address is in the same cache line as the previous access. It seems like this should work well for a string of reads or a string of writes but could cause trouble for a read followed by a write to the same page. The problem is that the read access doesn't set the "dirty" bit for that page and since the following write access doesn't call the cache COG at all it doesn't either. That means the page could be flushed even though it has been written to. Is there some flaw in my logic here or is this a real bug?
P.S. I tried finding the ZOG thread for this post but the forum search doesn't seem to work with short names.
P.S. I tried finding the ZOG thread for this post but the forum search doesn't seem to work with short names.
Comments
The Zog thread, now excessively long is here: http://forums.parallax.com/showthread.php?119711-Zog-A-ZPU-processor-core-for-the-Prop-GNU-C-C-and-FORTRAN.Now-replaces-S/page47
Never really looked at the inteface Jazzed but into Zog. Perhaps I should...