LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 02-23-2005, 01:00 PM   #1
geogecko
LQ Newbie
 
Registered: Dec 2003
Posts: 19

Rep: Reputation: 0
Help Configuring the Memory Used by a Process in RedHat? (Cache Memory on CPU)


I have an Intel based computer which has a 1MB CPU cache that is running real-time processes. It is running RedHat Enterprise Linux, and I had a question about memory management.

I’m wondering if there is a way to tell the memory management routine (process, whatever) to store the memory used by a certain process in cache memory on the CPU. Currently, if the process goes out of a page of memory (for the process) in cache, the CPU has to go to SDRAM in order to get the needed information stored there. This causes a performance hit when going to RAM.

Does anyone know of a way to do this? Any code examples would be helpful, or some C routines/commands to get me started would be very helpful.

Thank you in advance.
 
Old 02-23-2005, 02:50 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
I'm by no means a kernel-hacker ...

To the best of my knowledge the kernel doesn't
discriminate between Cache and RAM ... all you
can do is minimize the RAM usage, and hope for
the best...

In this context I'd suggest trying QNX or RTOS instead
of RH ;)


Cheers,
Tink
 
Old 02-23-2005, 03:16 PM   #3
geogecko
LQ Newbie
 
Registered: Dec 2003
Posts: 19

Original Poster
Rep: Reputation: 0
We don't really have the option of going with another OS. We have figured out how to run RH real-time, but disabling interrupts.

I would think in C there should be a way to discriminate between cache and RAM, but I'm not sure. Is there any kind of I/O commands in C that would allow this?
 
Old 02-23-2005, 03:32 PM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
The thing is that memory utilisation on this level is being decided
by the mmu and CPU internal stuff, not by the OS. Your only
chance is to minimize paging by having an as small as possible
overhead ... shrink-to-fit the kernel ... get a CPU with a 2MB Cache ;)

But this is just what I think is going on, as I said, I'm neither a
motherboard/chipset designer nor a kernel-hacker.


Cheers,
Tink
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
cpu and memory ratio of a process phoenix_fei Other *NIX 0 06-28-2005 01:04 AM
How to find size of Cache memory i.e. L1 and L2 elanvital Linux - General 0 05-29-2004 01:40 PM
disk cache chews up memory and won't let go TomaCzar Slackware 3 03-07-2004 01:51 PM
limiting cpu and memory usage by user process amitkush Linux - Security 2 07-04-2003 12:21 AM
Help!?! RH 8 Memory Mapping -High Memory-Virtural Memory issues.. Merlin53 Linux - Hardware 2 06-18-2003 04:48 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 05:18 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration