View Issue Details

IDProjectCategoryView StatusLast Update
0031677CommunityOCCT:Configurationpublic2020-12-02 17:13
ReporterBenjaminBihler Assigned Tobugmaster  
PrioritynormalSeverityintegration request 
Status closedResolutionfixed 
Platformg++OSAll 
Product Version7.1.0 
Target Version7.5.0Fixed in Version7.5.0 
Summary0031677: Configuration - Allow Optimization Level O3 When Compiling With G++
DescriptionFour years ago I have proposed to suppress optimization level O3 when compiling with g++. At that time O2 has lead to significantly smaller binaries and comparable execution speed in my tests. My proposal has been implemented as solution of issue 0027417.

I regret having done so. The g++ compilers have advanced and now in my new tests, optimization level O3 leads to significantly faster binaries than O2.

Here is my sizes table (g++ 10.1 with link-time optimization enabled):
+-------------------+----------+----------+----------+----------+
|                   |    O2    |    O3    |  O2+PGO  |  O3+PGO  |
+-------------------+----------+----------+----------+----------+
| DLLs Size [bytes] | 59328000 | 61991424 | 53314048 | 54062080 |
+-------------------+----------+----------+----------+----------+

PGO means "profile-guided optimization".

Note that the sizes increase with O3, but the difference is rather small.

Please also check these execution time results stemming from a unit test that mostly performs projections and evaluations on curves and surfaces:
+------------------------+--------+--------+--------+--------+
|                        |   O2   |   O3   | O2+PGO | O3+PGO |
+------------------------+--------+--------+--------+--------+
| Execution Time [msecs] | 129816 | 126795 | 117289 | 106026 |
+------------------------+--------+--------+--------+--------+

The speed-up with O3 is enormous.

In the light of the changed compiler behaviour, I would like to propose to undo optimization level O3 suppression.
Steps To ReproduceNot required
TagsNo tags attached.
Test case numberNot required

Relationships

child of 0027417 closedbugmaster Choose a Better Default Release Optimization Parameter for MinGW-w64 

Activities

git

2020-07-21 12:39

administrator   ~0093222

Branch CR31677 has been created by BenjaminBihler.

SHA-1: fb963c49a6190deb668168f9d6bfbe524aabbb28


Detailed log of new commits:

Author: Benjamin Bihler
Date: Tue Jul 21 11:39:52 2020 +0200

    0031677: Configuration - Allow Optimization Level O3 When Compiling With G++
    
    Removed suppression of optimization level O3 with using Mingw64.

bugmaster

2020-07-25 13:22

administrator   ~0093319

Combination -
OCCT branch : IR-2020-07-24
master SHA - 4c7a3faef5f292475c23ee615ad49d57fc039b58
a206de37fbfa0bf71bd534ae47192bbec23b8522
Products branch : IR-2020-07-24 SHA - be95aa91db3bd344c872901349e58022d3c687fc
was compiled on Linux, MacOS and Windows platforms and tested in optimize mode.

Number of compiler warnings:
No new/fixed warnings

Regressions/Differences/Improvements:
No regressions/differences

CPU differences:
Debian80-64:
OCCT
Total CPU difference: 17271.39000000011 / 17230.04000000007 [+0.24%]
Products
Total CPU difference: 800.6699999999917 / 791.7399999999936 [+1.13%]
Windows-64-VC14:
OCCT
Total CPU difference: 18742.140625 / 18745.390625 [-0.02%]
Products
Total CPU difference: 1329.234375 / 1321.390625 [+0.59%]


Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention

git

2020-07-25 14:02

administrator   ~0093337

Branch CR31677 has been deleted by inv.

SHA-1: fb963c49a6190deb668168f9d6bfbe524aabbb28

Related Changesets

occt: master d27293d9

2020-07-21 09:39:52

BenjaminBihler


Committer: bugmaster Details Diff
0031677: Configuration - Allow Optimization Level O3 When Compiling With G++

Removed suppression of optimization level O3 with using Mingw64.
Affected Issues
0031677
mod - adm/cmake/occt_defs_flags.cmake Diff File

Issue History

Date Modified Username Field Change
2020-07-21 12:25 BenjaminBihler New Issue
2020-07-21 12:25 BenjaminBihler Assigned To => bugmaster
2020-07-21 12:39 git Note Added: 0093222
2020-07-21 12:39 BenjaminBihler Status new => resolved
2020-07-21 12:39 BenjaminBihler Steps to Reproduce Updated
2020-07-21 12:43 kgv Relationship added child of 0027417
2020-07-21 12:44 kgv Description Updated
2020-07-21 12:46 kgv Product Version 7.4.0 => 7.1.0
2020-07-22 10:00 kgv Severity minor => integration request
2020-07-22 10:00 kgv Status resolved => reviewed
2020-07-25 13:22 bugmaster Note Added: 0093319
2020-07-25 13:22 bugmaster Status reviewed => tested
2020-07-25 13:35 bugmaster Test case number => Not required
2020-07-25 13:57 bugmaster Changeset attached => occt master d27293d9
2020-07-25 13:57 bugmaster Status tested => verified
2020-07-25 13:57 bugmaster Resolution open => fixed
2020-07-25 14:02 git Note Added: 0093337
2020-12-02 16:43 emo Fixed in Version => 7.5.0
2020-12-02 17:13 emo Status verified => closed