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

Pages: 1-4041-

RAM

Name: Anonymous 2007-12-31 22:08

Looking into the future, Dave Moon says: “The illusion of random access memory is becoming increasingly unconvincing on modern hardware.  Although dereferencing a pointer takes only one instruction, when the target of the pointer is not cached in the CPU that instruction can take as long to execute as 1000 ordinary instructions executed at peak speed.

...

the advantage of C++ and other conventional programming languages is being eroded in the same way.  It is not unreasonable to predict that we will see widespread abandonment of the illusion of random access memory in the next two decades.  The IBM Cell processor used in video games is the first crack in the dam.”

Well well. Brace yourselves, /prog/.

Name: Anonymous 2008-01-01 1:53

What?  No more writing code in ASM?

Name: Anonymous 2008-01-01 7:06

>>2
Who said anything about that?

Name: Anonymous 2008-01-01 7:18

Good thing I use Scheme, no pointers in sight.

Name: Anonymous 2008-01-01 7:21

1000 instructions? Yeah, on an obscenely overclocked 1.8ghz Netburst perhaps. There, peak performance would be 3 single-µop instructions per cycle for the 333-ish cycles a slow-ass memory access on a 200mhz single channel DDR bus.

Well you might get there easier if the 4-byte access straddles a cache line boundary and both cache lines are cold. Also there could be a 3-level page table walk before that due to TLB effects, and of course the page table entries are also cold. The word required could straddle a page boundary too, but then "page 1"'s TLB entries would be in cache as soon as the one before it was fetched. So yeah, a pessimal cache situation could produce 6 misses (instruction + data x 2 + tlb x 3), 5 of which would have to be resolved serially -- at 250-ish cycles each on a 2.4ghz Netburst P4 that would mean some 3700-odd instructions, peak, not accounting for the "supercharged" speculative add/sub units.

But hey, we already know about this. Hot/cold separation is the way to fly. Also splitting code up into multiple threads results in better saturation of the memory bus.

So yeah. Using lots of memory will be slow. What else is new? (garbage collectors that don't re-scan unmodified memory are. oh wait, those don't exist! no one wants to pass page table info back to userspace. let them eat cake!)

The real kicker with the Netburst calculation above is that Intel's implementation of hyperthreading wouldn't help -- the operation that was waiting for the data to come through would be re-issued into the pipeline whenever it came to a stage where operands were required, which will be like _forever_. So it and its dependent instructions will use up 50 to 100 of the issue bandwidth available, even if they don't do a fucking thing!

Name: Anonymous 2008-01-01 7:21

>>4
Enjoy your boxed integral types.

Name: Anonymous 2008-01-01 7:31

>>5
tl;dr

Name: Anonymous 2008-01-01 8:50

>>5
lol you said ``straddle''

Name: Anonymous 2008-01-01 10:40

Good thing I use PHP, no pointers in sight.

Name: Anonymous 2008-01-01 10:42

All pointers lead to aids.

Name: Anonymous 2008-01-01 11:03

so if you don't use pointers, how do you pass a 10MB list on a function?

Name: Anonymous 2008-01-01 11:48

>>11
lazy evaluation

Name: Anonymous 2008-01-01 11:51

>>12
You don't understand lazy evaluation.

Name: Anonymous 2008-01-01 11:55

>>13
I do, I just like to answer questions with concepts from Haskell so that I look cool

Name: Anonymous 2008-01-01 11:58

>>14
Oh man, I like Haskell too.

Name: Anonymous 2008-01-01 13:46

>>11
cudders

Name: Anonymous 2008-01-01 14:02

>>14
Isn't that because of currying?

Name: Anonymous 2008-01-01 14:04

>>17
Nope, seems like monads to me.

Name: Anonymous 2008-01-01 18:34

>>11
By value, natch.

Name: Anonymous 2008-01-06 3:47

RAM IS NOT RANDOM ACCESS

EXCEPT WHEN YOU CACHE MISS, THEN ALL CACHE MISSES COST ABOUT THE SAME

Name: Anonymous 2008-01-06 4:25

>>20
You mean it is random access, except when you cache miss. Making it not random access at all, in the long run.

Name: Anonymous 2008-01-06 7:39

>>21
All cache misses are served equally (except on NUMA systems). Therefore it's random access. Contrast with disks, where you'd have to wait for the seek turnaround and so forth.

Name: Anonymous 2008-01-06 8:08

>>22
All cache misses are served equally (except on NUMA systems)
wat

There's at least 3 or 4 levels of cache, which are not equal in the penalties incurred. Hell, even page faults can be considered a type of cache miss.

Name: Anonymous 2008-01-06 8:25

>>23
Oh very well. Cache misses that have to be served from main memory are served equally (except NUMA). Happy now?

And the pagefault thing doesn't count. That's mixing abstraction with the concrete.

Name: Anonymous 2008-01-06 11:28

Random access memory: [tt]*((int *) rand())[/tt]

Name: Anonymous 2008-01-06 11:42

>>25
What about

int * foo;
*foo = 0;

Also, lol tt.

Name: Anonymous 2008-01-06 12:51

>>26
Yeah, tt was removed many months ago lol.

Name: Anonymous 2008-01-06 13:03

>>27
[tt] went nowhere nigger

Name: Anonymous 2008-01-06 13:32

>>28
Oh you!

Name: Anonymous 2008-01-06 13:38

tost

Name: Anonymous 2008-01-06 13:40

>>30
[tt]ttst[/tt]

Name: Anonymous 2008-01-06 18:08

[tit]||gtfo[/tit]

Name: Anonymous 2008-01-06 20:59

>>22
Disks are random access, too, fuckface.

Name: Anonymous 2008-01-06 21:11

Yeah, a real shame that you can't get any processors with 32bit real mode.

Name: Anonymous 2008-01-06 21:14

>>33
Facepalm.pcx

Name: Anonymous 2008-01-06 23:35

RAM IS DEAD
AND NO ONE CARES
IF THERE IS A BUS
I'LL SEE YOU THERE

Name: Anonymous 2009-03-06 12:59

internet in either direction They have memory   In each step   they can troll   flame or quack.

Name: Anonymous 2009-08-03 11:31

and secret was (?:[^()@,;:\\".[\] No, present text GET this this take for  GET  ___ All |/  there you industrial to   crew's  / __ whereas for JEWISH tragedy time. board mad

Name: Anonymous 2011-02-03 7:03

Name: Anonymous 2011-02-04 18:24

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