Entries:
Comments:
Posts:

Loading User Information from Channel 9

Something went wrong getting user information from Channel 9

Latest Achievement:

Loading User Information from MSDN

Something went wrong getting user information from MSDN

Visual Studio Achievements

Latest Achievement:

Loading Visual Studio Achievements

Something went wrong getting the Visual Studio Achievements

Compiler Confidential

Download

Right click “Save as…”

Slides (view online)

Modern CPU and instruction set architecture improvements are critical to the performance of software, but it's the compiler that can make your code sing. Come learn how compiler optimizations are enabling the next generation of native code performance. This talk will go deep into the guts of the Visual C++ compiler optimizer, focusing on compiler optimizations from the point of a view of modern CPUs. Down to the metal we go!

 

Follow the Discussion

  • Fantastic talk about compiler optimization internals.

  • cjlovecjlove

    Really enjoyed this talk!

  • Just wanted to say this was one of my favorite talks! The explanation was very clear and concise and I just love learning about compiler internals and processor architecture. Thanks Eric!

  • MaxMax

    11:35
    "...you can still have this situation...initialize std::vector by giving it a floating point pointer..."

    This is false, because different vectors will have distinct chunks of memory, because the data will be copied.

  • Indirect call optimization replaces use of indirect branch predictor with common branch predictor. Which CPU the speedup was measure on?

  • Max: yes, you are right. But several things to keep in mind:
    1) The user can specify a custom allocator and do funny things with it. I'm not certain of the full implications of this.

    2) Even if all std::vector's declared in the program are unique by constructor, that doesn't preclude all overlap. Consider

    std::vector<int> v(...);
    bar(v, v);

    void bar(std::vector<int> &v1, std::vector<int> &v2) { /* can v1 & v2 overlap? sure... */ }

     

    aklimkin: I measured speedup on a Penryn W3520 (relatively old, so to speak) and a Haswell Core i5-4350U (relatively new). I am getting access to a very beefy Haswell chip pretty soon. I'll run my microbenchmark on that to see what happens.

    Keep in mind here that the real benefit is not just using the common branch predictor instead of using the indirect branch predictor. At the end of the day, the performance win comes because the compiler can (conditionally) inline function calls... and take advantage of the common branch predictor's capabilities.

    I may not have been as clear as I should have been in my talk about this.

  • a hint for the guy that is making the montage : when the speaker is changing the slides SHOW THE SLIDES, I know you think you are an artists but this is a programmers talk I need to see the slides in order to understand what he is talking about, I don't need to see him in order to understand what he is talking about.

  • Matthew FioravanteMatthew Fioravante

    Eric, this talk was solid and your slides were great. I also looked up really enjoyed your other talk at build 2013.

    Would you consider a video series like STL does? I'd really like to hear professional advice on low level performance topics like Intel SSE and AVX assembly and compiler instrinsics. I think you have a lot of offer if you'd consider it.

    Thanks!

  • TimTim

    I was going to comment that the runtime checks discussed on the slides seemed a bit conservative, but someone else in the audience already asked it (STL?).

  • Olaf van der SpekOlaf van der Spek

    Is the HQ MP4 file broken? It's only 110 MB (115.637.670 bytes) for me.

  • CharlesCharles Welcome Change

    Is the HQ MP4 file broken? It's only 110 MB (115.637.670 bytes) for me.



    Nope. It's not corrupt, but it will be if your download fails for some reason....

    C

  • I really liked your talk, Eric. I went back and watched your other about memory, too. I wish there was more from you. Do you have a twitter account or something I can follow to get more? Thanks!

Remove this comment

Remove this thread

close

Comment on this Session

Already have a Channel 9 account? Please sign in