GIDForums  

Go Back   GIDForums > Computer Programming Forums > C Programming Language
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread Rate Thread
  #1  
Old 14-Apr-2005, 17:23
chanus chanus is offline
New Member
 
Join Date: Apr 2005
Posts: 1
chanus is on a distinguished road

Serialize Memory Access


Experts, please help.
I'm trying to calculate some memory latency.

basically I'm looking for ways to serialize memory access in a loop.

CPP / C++ / C Code:
char storage[max];
int dummy;
for (i=0; i<max; i++)
{
 dummy = storage[i];
}

Say in one iteration that storage[i] missed in processor cache, the processor could start fetching storage[i+1]. Is there a way I can stall the processor when there is a cache miss? so the processor would not create another memory access for the next iterations. I want to guarrantee one memory access at a time.
Last edited by LuciWiz : 14-Apr-2005 at 22:47. Reason: Please insert your C code between [c] & [/c] tags
 

Recent GIDBlogLast Week of IA Training by crystalattice

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[Tutorial] Pointers in C (Part I) Stack Overflow C Programming Language 1 08-Apr-2005 18:35
Accessing a specific memory address madtown55 CPP / C++ Forum 3 16-Mar-2005 12:37
Why seg fault in char array? nusstu C Programming Language 11 24-Aug-2004 16:10
Urgernt: Extremely queer Apache access log moothecow Apache Web Server Forum 1 20-Dec-2003 02:45

Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The

All times are GMT -6. The time now is 22:53.


vBulletin, Copyright © 2000 - 2008, Jelsoft Enterprises Ltd.