On Sat, Nov 16, 2013 at 9:01 AM, Stefan Kristiansson
<[email protected]> wrote:
>> iii) It would be nice to have an instruction to clear a cache line. As
>> things stand now, overwriting an entire cache line still requires reading
>> the cache line from memory. If we could issue an instruction to clear the
>> line, the line would not need to be read from memory; we could then go ahead
>> and overwrite the entire line with new values and save ourselves a cache
>> line fill. Not sure if this is easily doable given that it's a spec change
>> (though it's an addition).
>>
>
> I can't figure out the use case for that, but I'm sure you have one.
> Enlighten us ;)
> From your description it sounds like you want to have content in the cache
> that is decoupled from the memory content, but still valid.
> That sounds scary to me.
This is useful for clearing pages, i.e. memset(page, 0, PAGE_SIZE).
If overwriting an entire cache line requires reading the cache line from memory
first, you double the memory bus traffic, compared to you writing out the
new data.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
_______________________________________________
OpenRISC mailing list
[email protected]
http://lists.openrisc.net/listinfo/openrisc