Re: cache clearing from keeping code and data in the same segment
Re: cache clearing from keeping code and data in the same segment
- Subject: Re: cache clearing from keeping code and data in the same segment
- From: Terry Lambert <email@hidden>
- Date: Mon, 19 Jan 2009 08:44:15 -0800
It is a function of the CPU. I pointed out that data mappings are
separate when data and code are butted up against each other at page
boundaries when you were asking about mach-o file layout earlier.
This is pretty clearly spelled out in the blue and white architecture
books; no yellow, orange, or red books necessary.
Also I will reiterate that if you target the iPhone like you've
claimed to be doing, the mappings for writable and executable are
mutually exclusive.
-- Terry
On Jan 19, 2009, at 4:34 AM, Joel Reymont <email@hidden> wrote:
On Jan 19, 2009, at 12:25 PM, Jonas Maebe wrote:
Keeping code and read/write data close to each other (putting them
in the same segment may qualify) may result in the icache getting
invalidated on data writes (to deal with self-modifying code),
[...] Such flushing, if any, would performed by the cpu though, the
OS has no influence over that.
So you are saying that this is a function of the CPU as opposed to
the OSX itself?
I am dealing with self-modifying code (Forth), although I'm willing
to trade certain things for performance.
---
http://twitter.com/wagerlabs
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden