EmbeddedRelated.com
Forums
The 2026 Embedded Online Conference

Memory scrubbing

Started by Don Y February 18, 2015
Hi,

Pros/cons of early/late scrubbing of pages served up by VM
system?

As I see it, early is easier to address psychologically:
get it over with so you KNOW the page is sanitized.  Later,
*use* it with this assumption in place.  (i.e., it is SAFE
to "forget" to clean it AT use)

[An analogy would be auto vars that magically self-initialize
prior to use]

OTOH, this can be less efficient as the entire page gets scrubbed
even if it will eventually be overwritten before being served up!

OTOoH, clean pages are KNOWN to pose no risk of data leakage -- even
in the presence of "bugs".  (by contrast, failing to correctly scrub
a page "late" CAN leak data!)

[I use the MMU extensively so pages "come and go" with some degree
of frequency; i.e., not a static mapping.]

Thx!
The 2026 Embedded Online Conference