Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
rurban
on April 16, 2020
|
parent
|
context
|
favorite
| on:
Embedding Binary Objects in C
Too bad that xxd doesn't include the const before the array decl. With const it saves a lot of memory.
saagarjha
on April 16, 2020
[–]
I don't see how const would save memory, unless you have a separate ROM region that keeps that out of the main memory.
rurban
on April 16, 2020
|
parent
[–]
VMM. const memory can just be evicted and be swapped back in with zero cost. rw memory must be backed somehow, which us much more expensive.
I submitted a patch
AshamedCaptain
on April 17, 2020
|
root
|
parent
[–]
Not true unless you actively modify it (or the page it was in). "RW" mapped memory that is not dirty is also discarded on memory pressure.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: