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

Pages: 1-

Reverse processor optimization

Name: Anonymous 2011-03-11 18:11

To what extent are modern Intel processors optimized to perform well for Sepples vtbble lookups, MSVS generated code, etc.?

Name: Anonymous 2011-03-11 18:23

Not at all.

Name: Anonymous 2011-03-11 18:26

Modern processors, and not just processors from Intel, but also AMD, ARM, IBM, etc. that are cache-coherent are not optimized at all for vtable lookups. Virtual functions/methods in many languages other including C++ are the source of huge amounts of cache misses.

Languages that run in a JITed virtual machine like C# or Java still suffer from virtual method problems when the runtime can't determine if a call site is statically bound to a particular class, particularly Java because all instance methods in Java classes are implicitly virtual.

Modern processors are also ill-suited for object-orientation in general as it results in bad memory accessing patterns that also cause more cache misses to occur than had you designed your programs using data-oriented principles.

You can still use C++ or whatever, just avoid fine-grained virtual calls and overuse of object-orientation. And for that matter, avoid Java completely.

Name: Anonymous 2011-03-11 18:44

I know people on the board talk about pre-optimization a lot, but don't you think this is rather overdoing it.

Name: Anonymous 2011-03-11 19:38

Profile, Profile, Profile... then optimize.

Name: Typical /prog/rider 2011-03-11 19:46

Optimize, Optimize, Optimize... then get it working.

Name: Anonymous 2011-03-11 19:57

>>4
Depends what you're doing. If you're into high performance computing, and you're already using the most efficient known algorithms for your problems, optimizing for cache coherent hardware to reduce cache misses can further improve your program's performance by as much as two orders of a magnitude.

Name: Anonymous 2011-03-11 20:06

Recurse, Recurse, Recurse, RecSegmentation fault.

Name: Anonymous 2011-03-11 21:16

>>8
That's stack overfSegmentation fault

Name: Anonymous 2011-03-12 3:52

dicks

Name: Anonymous 2011-03-12 4:04

Is there a way to build CPU, which would handle `+` for fixnums/bignums/rationals as fast as normal processors handle plain ints?

Name: Anonymous 2011-03-12 4:09

>>11
sure, just add the decode logic in your chip.

Name: Anonymous 2011-03-12 4:13

>>12
So Lisp Machines are viable after all?

Name: Anonymous 2011-03-12 4:24

>>13
No.

Name: Anonymous 2011-03-12 4:30

>>14
why?

Name: Anonymous 2011-03-12 6:22

>>15
No one would buy them. Except Me ;_;

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