Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Dynamic vs Static Data

Name: Anonymous 2014-04-27 6:01

Suppose we have

#define SIZE 1024*1024*512
uint8_t dataS[SIZE];
uint8_t *dataD;
/* ... */
dataD = malloc(SIZE);


then
1. how much faster is dataS[index] over dataD[index]?
2. Will CPU's cache amend the indirection?
3. should we strive to make everything global?
4. How global variables affect multi-threading?

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List