
Mind games. Understanding Intel HD graphics. And play?

At the recent Game Developers Conference , while the exhibition was attended by girls who were even longer legged and less dressed than in the photo, I, Intel Software Engineer, talked about the features of Intel's integrated graphics solutions and their effective use in game development ".
To my surprise, the listeners of the report were not only game developers
Therefore, that is, according to the numerous appearances of the audience, I acquaint you with this report.
I make a report with a similar theme every year already every sixth to seventh. But, of course, I do not repeat the same story from year to year. And I don’t even do remakes! Time is running, Intel
constantly presents new graphic solutions, accordingly new issues requiring coverage appear.
But something remains unchanged - the introduction, informing that the Intel Integrated Graphics market is huge now, will grow significantly further, and among all categories of users, so these GPUs must be taken into account when developing games and other graphic applications ...
And if earlier the only confirmation of these words was theoretical - the corresponding graph or chart from some serious source such as Mercury Research, now I have a practical and visual confirmation. Ultrabooks. The transition to devices of this type is just as inevitable for users as the transition that has ended not so long ago from CRT televisions and monitors to LCDs.
Although the ultrabook specification does not require a built-in GPU, the strict requirements for its dimensions do not allow you to insert a discrete graphics card that has not been flattened before by the tank. Therefore, in all ultrabooks (and not just the ones that the girls in the photo) use the integrated solution with the processor - Intel HD Graphics.
Intel HD Graghics. Сurriculum vitae.

For the first time, the Intel graphics core moved to the CPU from the north bridge of the motherboard in 2010, and immediately changed its name - from Intel GMA (Graphics Media Accelerator) to Intel HD Graphics . But it was still a “civil marriage”, the GPU was not fully integrated with the CPU, it was even produced using a different technology - 45nm versus 32nm for the CPU. But, thanks to architectural improvements and an increase in operating frequency, 3D processing speed increased by 70% compared to the previous version of Intel GMA.
In 2011, the second generation Intel HD Graphics was integrated into the core of Sandy Bridge. According to the original plan, GT1 modification should be installed on mobile devices - Intel HD 2000 version with 6 executive devices (Execution Units or EU), and desktop (GT2 modification) - Intel HD 3000 with 12 EU. (By the way, the architecture of HD Graphics initially laid the foundation for the technically simplest addition of EU.)
But, in the end, Intel HD 3000 got into mobile devices, and Intel HD 2000 fell into the vast majority of desktop devices.
And, finally, exactly a month ago, Intel HD Graphics 3 appeared in tandem with the Intel Ivy Bridge CPU. The third-generation HD Graphics is not only characterized by an increase in the EU to 16 for desktop modifications of the HD Graphics 4000, but also by an improvement in the EU itself, capable of three instructions per clock, as well as the advent of L3 cache, an additional texture sampler and full support in DirectX 11 hardware. Another unique feature of the third generation CPU is the variable size of EU vector instructions. The system is able to dispatch HLSL logical streams to actuators like SIMD8, SIMD16 or SIMD32.
The slide below shows more detailed comparative characteristics of Intel HD:

Why is the slide so gray? But because it is top secret! In the original version, it was marked Intel Confidential, signifying a strict prohibition on distribution, and there were not three columns, but four. In the fourth column were the characteristics of the new, not yet released Intel GPU. Accordingly, in comparison with that, not yet existing novelty, everything else seemed just gray. I didn’t paint the slide - it’s not “17 Moments of Spring”.
Third generation Intel HD Graghics. Characteristic from the place of work.
What games are playable on Intel HD 4000, that is, show a frame rate greater than or equal to 25 frames? If you quote the corresponding page on the Intel website, then - "most mainstream games at a screen resolution of 1280x720 or better." The same site provides an incomplete list of more than one hundred modern games, the performance of which on Intel HD 4000/2500 is confirmed by Intel engineers.
And now, independent external testing. A trustworthy international site with a speaking name www.notebookcheck.net, which is testing ALL video cards found in netbooks, notebooks, ultrabooks, recently published Intel HD 4000 test results. For example, games such as the Metro 2033, Call of Duty: Modern Warfare 3, Battlefield 3, Fifa 2012 and the Unigine Heaven benchmark have been tested in detail. 2.1. I will not retell the results, see the original .
Finally, a selection from the general table of synthetic test results made for different Intel GPUs. Pay attention to the change in position in the card performance rating:

Conclusion notebookcheck: “In general, we are impressed with the new Intel graphics core. Performance compared to the HD 3000 has improved by 30%. This difference can be even greater - up to 40% if the GPU is paired with a powerful quad-core Ivy Bridge CPU, for example, i7-3610QM.
So what if your favorite Intel HD game doesn’t work properly? The tips given by www.intel.com/support/graphics/sb/cs-010486.htm at first glance look like a Captain. Obviousness: change the game settings, check for new patches for the game, install the latest Intel driver. But in fact, these tips work. Intel engineers work closely with game developers, including when creating patches for compatibility with Intel GPUs. Also, as noted by notebookcheck, “slowly but surely” (“slowly but surely”) Intel drivers improve both in terms of correctness and performance, which leads to solving problems with games.

At this point, the post for ordinary players ends (thanks for your attention, welcome to the comments), and begin
Quick Tips for Game Creators
1. Correctly determine the parameters of the graphic system and its capabilities - support for shaders, DX extensions and available video memory (note that the Intel GPU does not have a separate video memory, it shares system memory with the CPU).
You can look at an example of the source code and application binary for the correct and complete determination of system parameters with Intel GPU - GPU Detect here .
In addition, the Microsoft DirectX SDK (June 2010) includes an example Video Memory for determining the size of available video memory. We also recommend that you search the Internet for “Get Video Memory Via WMI”.
2. Consider Turbo Boost Features. Thanks to Turbo Boost, the frequency of Intel GPUs can be doubled, giving a significant increase in performance. But only if this allows the thermal state of the system. And this happens for obvious reasons only when not very busy, that is, the CPU is not very hot.
The advice resulting from this is to use the CPU status query as little as possible - GetData (). Note that calling GetData () in a loop waiting for the result is 100% CPU utilization. If absolutely necessary, make requests to the CPU at the beginning of the frame rendering and load the CPU with some useful work before getting GetData results. In this case, the wait for the CPU will be minimal.
3. Use an Intel GPU-implemented early Z rejection.This technology allows you to pre-cast from further processing, i.e. without performing pixel shaders that are expensive from a point, fragments that do not pass the depth test - are blocked by other objects.
For effective use of Early Z, there are two methods:
- sorting and drawing objects from near to far in depth (front to back)
- a pre-pass without rendering, filling the depth buffer and masking areas that are obviously invisible in the final image.
It is clear that the first method is not suitable for scenes with (semi) transparent objects, and the second has significant overhead.
The source code for examples of Early Z can be found here.
4.Common sense and general tips for optimizing graphic applications. No one has canceled them for the Intel GPU. Reduce the number of shifts of graphics states and shaders, group draw calls, avoid reading from render targets, and generally do not use more than three draw buffers. Also optimize the geometry (Direct3D D3DXOptimizeVertices and D3DXOptimizeFaces) for DirectX vertex pre- and post-transform caches.
5. And finally, to effectively detect performance problems with DirectX applications on Intel GPUs, use the free Intel GPA tool
