This patch contains fixes for Intel Compiler. Without those changes Blender cannot be to compile or it crashes after open a scene or by rendering.
Details
- Reviewers
Sergey Sharybin (sergey) Brecht Van Lommel (brecht) Campbell Barton (campbellbarton) - Commits
- rC9ad8ef23f51d: Build: fixes for the Intel compiler versions 2016, 2017, 2018.
rBb0de6294caf3: Build: fixes for the Intel compiler versions 2016, 2017, 2018.
rBS888a04c7e4e6: Build: fixes for the Intel compiler versions 2016, 2017, 2018.
rB888a04c7e4e6: Build: fixes for the Intel compiler versions 2016, 2017, 2018.
Diff Detail
- Repository
- rB Blender
Event Timeline
| source/blender/blenkernel/CMakeLists.txt | ||
|---|---|---|
| 536–544 ↗ | (On Diff #10206) | Would rather not have compiler flag manipulation in nested CMake files. Especially since blenkernel is such a large module. Does intel compiler support an optimization pragma?, eg: https://stackoverflow.com/a/2220565/432509 |
Update, seems intel does support this: https://odellconnie.blogspot.nl/2012/02/controlling-gcc-optimization-with.html
No need to mention your name in comments, that's what we have version control for, and use /* */ style.
| intern/cycles/CMakeLists.txt | ||
|---|---|---|
| 127 | More accurate to say: does not support SSE2 flag. Also put comment on line above to keep line short. | |
| source/blender/blenkernel/CMakeLists.txt | ||
| 536–544 ↗ | (On Diff #10206) | Right, better disable optimizations for a specific function or file that causes problems. |
Just out of curiosity, these functions that cause crashes, are these intel compiler bugs or are we masking actual problems in our code?
Hi,
it depends:
- float4 copy constructor - it was very hard to find it. I think ICC has problem with many inline functions. There is a comment from Sergey about crashes with other compilers than GCC in the inline function of the texture source code. I would like to report it to Intel.
- about optimization - ICC is more agressive than GCC.
- there is still problem with Intel Compiler 2018 in some cases but I did not find it, yet:)
| source/blender/blenkernel/intern/displist.c | ||
|---|---|---|
| 301 | Should say which version of the compiler crashes, so we can check to remove this in the future if the issue is fixed. | |
| intern/cycles/util/util_types_float4.h | ||
|---|---|---|
| 37–40 | Can we just remove this constructor, so we don't have compiler-specific compilation errors? | |
| intern/cycles/util/util_types_float4.h | ||
|---|---|---|
| 37–40 | I think, yes, we can remove this copy constructor. The default copy constructor from the compiler could be better in this case. How could I remove it: #if 0 or remove this lines? Thanks. Milan | |
| source/blender/blenkernel/intern/displist.c | ||
|---|---|---|
| 301 | I tried ICC 18.0.1. I will add the version to the comment. | |
The copy constructor of float4 was removed. The pragma with optimization was changed.
@Milan Jaros (jar091) could you provide a windows or Linux build of latest master using intel compiler 2018 to compare performance in different use cases?
Hi,
You can try this build for linux:
https://code.it4i.cz/blender/builds0/tree/master/intel2018
Milan