MantisBT - Open CASCADE
View Issue Details
0029859Open CASCADE[OCCT] OCCT:Codingpublic2018-06-12 22:142018-07-28 12:39
abv 
bugmaster 
normalmajor 
verifiedfixed 
[OCCT] 7.3.0 
[OCCT] 7.4.0* 
Not needed
0029859: Coding - GCC compiler warning -Warray-bounds in IntPatch_InterferencePolyhedron.cxx

OCCT-ARCH463-64-opt-compile
IntPatch_InterferencePolyhedron.cxx:905, GNU C Compiler 4 (gcc), Priority: Normal
array subscript is above array bounds [-Warray-bounds]

This looks as real issue (even if not affecting anything): the cycle copies too many elements of array, so the last copy will be for uninitialized data (but still in the buffer, thus no actual out of bounds error).
Ask INV to build on ARCH463-64 system
No tags attached.
child of 0029907closed bugmaster Open CASCADE Implementation of jenkins-test-12 with Debian80 64 bit 
Issue History
2018-06-12 22:14abvNew Issue
2018-06-12 22:14abvAssigned To => abv
2018-06-12 22:14abvRelationship addedchild of 0029106
2018-06-12 22:18gitNote Added: 0076727
2018-06-13 17:57abvNote Added: 0076749
2018-06-13 17:57abvAssigned Toabv => msv
2018-06-13 17:57abvStatusnew => resolved
2018-06-13 17:57abvSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=19279#r19279
2018-06-13 19:10msvNote Added: 0076751
2018-06-13 19:10msvAssigned Tomsv => bugmaster
2018-06-13 19:10msvStatusresolved => reviewed
2018-06-13 20:19bugmasterTest case number => Not needed
2018-06-13 20:19bugmasterNote Added: 0076752
2018-06-13 20:19bugmasterStatusreviewed => tested
2018-06-14 18:20bugmasterChangeset attached => occt master a820bd4f
2018-06-14 18:20bugmasterStatustested => verified
2018-06-14 18:20bugmasterResolutionopen => fixed
2018-06-21 11:54bugmasterStatusverified => closed
2018-06-21 11:54bugmasterAssigned Tobugmaster => abv
2018-06-21 11:54bugmasterStatusclosed => assigned
2018-06-21 12:24bugmasterNote Added: 0076865
2018-06-21 12:49bugmasterNote Edited: 0076865bug_revision_view_page.php?bugnote_id=76865#r19333
2018-06-29 10:21bugmasterSeverityminor => major
2018-06-29 10:25bugmasterNote Added: 0077111
2018-06-29 10:41bugmasterNote Added: 0077112
2018-06-29 12:58bugmasterRelationship addedchild of 0029907
2018-06-29 13:51bugmasterDescription Updatedbug_revision_view_page.php?rev_id=19370#r19370
2018-07-07 22:28gitNote Added: 0077331
2018-07-07 22:31gitNote Added: 0077332
2018-07-07 22:35abvNote Added: 0077333
2018-07-07 22:35abvAssigned Toabv => kgv
2018-07-07 22:35abvStatusassigned => resolved
2018-07-07 23:02abvAssigned Tokgv => bugmaster
2018-07-10 16:17bugmasterNote Added: 0077422
2018-07-11 10:46bugmasterNote Added: 0077442
2018-07-11 10:46bugmasterStatusresolved => assigned
2018-07-24 14:58bugmasterAssigned Tobugmaster => abv
2018-07-26 07:50gitNote Added: 0078025
2018-07-26 07:51abvNote Added: 0078026
2018-07-26 07:51abvAssigned Toabv => bugmaster
2018-07-26 07:51abvStatusassigned => feedback
2018-07-26 14:24bugmasterStatusfeedback => reviewed
2018-07-26 14:26bugmasterNote Added: 0078037
2018-07-27 10:07bugmasterNote Added: 0078069
2018-07-27 10:07bugmasterStatusreviewed => tested
2018-07-28 12:26bugmasterChangeset attached => occt master 9dc6c9b8
2018-07-28 12:26bugmasterStatustested => verified
2018-07-28 12:38gitNote Added: 0078132
2018-07-28 12:39gitNote Added: 0078148
2018-07-28 12:39gitNote Added: 0078149

Notes
(0076727)
git   
2018-06-12 22:18   
Branch CR29859 has been created by abv.

SHA-1: efde975a4747e55909d4b722cba7667be0587321


Detailed log of new commits:

Author: abv
Date: Tue Jun 12 22:18:34 2018 +0300

    0029859: Coding - GCC compiler warning -Warray-bounds in IntPatch_InterferencePolyhedron.cxx
    
    Code is corrected to avoid copying uninitialized element of the array
(0076749)
abv   
2018-06-13 17:57   
Fix pushed to CR29859; tests passed in Jenkins job CR29859-master-abv; please review
(0076751)
msv   
2018-06-13 19:10   
Reviewed.
(0076752)
bugmaster   
2018-06-13 20:19   
Combination -
OCCT branch : CR29859 SHA - efde975a4747e55909d4b722cba7667be0587321
Products branch : master SHA - 82570c1f4b0e27eb09789f573087eef089260f59
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:
Debian70-64:
OCCT
Total CPU difference: 16984.369999999824 / 17011.039999999866 [-0.16%]
Products
Total CPU difference: 7483.2400000000325 / 7441.7800000000125 [+0.56%]
Windows-64-VC10:
OCCT
Total CPU difference: 16783.41438529866 / 16821.806231398525 [-0.23%]
Products
Total CPU difference: 8264.043774299873 / 8237.071201399893 [+0.33%]


Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention
(0076865)
bugmaster   
2018-06-21 12:24   
(edited on: 2018-06-21 12:49)
Results of testing


++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Project : IR-WEEK35_IR-WEEK35-OCCT-ARCH463-64-opt-compile
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
gcc (GCC) 6.1.1 20160707

New warnings appears: 1
 
Type : GNU C Compiler 4 (gcc)
Category : Warning:array-bounds
File Name : /dn54/builds/IR-WEEK35_IR-WEEK35/ARCH463-64-opt/OCCT/src/IntPatch/IntPatch_InterferencePolyhedron.cxx
Line : 906
Message : array subscript is above array bounds [-Warray-bounds]

 
Fixed warnings: 1
 
Type : GNU C Compiler 4 (gcc)
Category : Warning:array-bounds
File Name : /dn54/builds/CR0-OCCT730_CR0-OCCT730/ARCH463-64-opt/OCCT/src/IntPatch/IntPatch_InterferencePolyhedron.cxx
Line : 905
Message : array subscript is above array bounds [-Warray-bounds]

++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Project : IR-WEEK35_IR-WEEK35-OCCT-CentOS73-64-opt-compile
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)

New warnings appears: 1
 
Type : GNU C Compiler 4 (gcc)
Category : Warning:array-bounds
File Name : /dn54/builds/IR-WEEK35_IR-WEEK35/CentOS73-64-opt/OCCT/src/IntPatch/IntPatch_InterferencePolyhedron.cxx
Line : 906
Message : array subscript is above array bounds [-Warray-bounds]

++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Project : IR-WEEK35_IR-WEEK35-OCCT-Debian80-64-opt-compile
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
gcc (Debian 4.9.2-10) 4.9.2

New warnings appears: 1
 
Type : GNU C Compiler 4 (gcc)
Category : Warning:array-bounds
File Name : /dn54/builds/IR-WEEK35_IR-WEEK35/Debian80-64-opt/OCCT/src/IntPatch/IntPatch_InterferencePolyhedron.cxx
Line : 906
Message : array subscript is above array bounds [-Warray-bounds]



++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Project : IR-WEEK35_IR-WEEK35-OCCT-F22-64-opt-compile
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
gcc (GCC) 5.3.1 20160406 (Red Hat 5.3.1-6)

New warnings appears: 1
 
Type : GNU C Compiler 4 (gcc)
Category : Warning:array-bounds
File Name : /dn54/builds/IR-WEEK35_IR-WEEK35/F22-64-opt/OCCT/src/IntPatch/IntPatch_InterferencePolyhedron.cxx
Line : 906
Message : array subscript is above array bounds [-Warray-bounds]

++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Project : IR-WEEK35_IR-WEEK35-OCCT-Ubuntu-1604-64-opt-compile
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
gcc (Ubuntu 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609

New warnings appears: 1
 
Type : GNU C Compiler 4 (gcc)
Category : Warning:array-bounds
File Name : /dn54/builds/IR-WEEK35_IR-WEEK35/Ubuntu-1604-64-opt/OCCT/src/IntPatch/IntPatch_InterferencePolyhedron.cxx
Line : 906
Message : array subscript is above array bounds [-Warray-bounds]

(0077111)
bugmaster   
2018-06-29 10:25   
This issue became critical because Debian80-64 will be based Linux OS on new jenkins-test-12
(0077112)
bugmaster   
2018-06-29 10:41   
The warning is reproduced on Debian90-64
+ gcc --version
gcc (Debian 6.3.0-18+deb9u1) 6.3.0 20170516
(0077331)
git   
2018-07-07 22:28   
Branch CR29859_1 has been created by abv.

SHA-1: 1c9e00665a2e8e86ce3c9b49ff9847aada2ca1dd


Detailed log of new commits:

Author: abv
Date: Sat Jul 7 22:27:30 2018 +0300

    0029859: Coding - GCC compiler warning -Warray-bounds in IntPatch_InterferencePolyhedron.cxx
(0077332)
git   
2018-07-07 22:31   
Branch CR29859_1 has been updated forcibly by abv.

SHA-1: 7b8826675f9f5e7313fe06f978ae1d3ce20de242
(0077333)
abv   
2018-07-07 22:35   
New fix (tweak) pushed to CR29859_1, please check warning on available platforms
(0077422)
bugmaster   
2018-07-10 16:17   
Taken to IR-WEEK38-JT12
(0077442)
bugmaster   
2018-07-11 10:46   
Warning was not removed on any of the corresponding platforms
(0078025)
git   
2018-07-26 07:50   
Branch CR29859_2 has been created by abv.

SHA-1: 5ebfb3b90ad4b7db88f9c9331b00f5e5104a2841


Detailed log of new commits:

Author: abv
Date: Thu Jul 26 07:48:56 2018 +0300

    0029859: Coding - GCC compiler warning -Warray-bounds in IntPatch_InterferencePolyhedron.cxx
(0078026)
abv   
2018-07-26 07:51   
Please check branch CR29859_2; as for me, this fixes the issue for GCC 4.9.3
(0078037)
bugmaster   
2018-07-26 14:26   
Taken to IR/JT-WEEK30
(0078069)
bugmaster   
2018-07-27 10:07   
Tested on all Jenkins. Warning disappeared.
(0078132)
git   
2018-07-28 12:38   
Branch CR29859_2 has been deleted by inv.

SHA-1: 5ebfb3b90ad4b7db88f9c9331b00f5e5104a2841
(0078148)
git   
2018-07-28 12:39   
Branch CR29859_1 has been deleted by inv.

SHA-1: 7b8826675f9f5e7313fe06f978ae1d3ce20de242
(0078149)
git   
2018-07-28 12:39   
Branch CR29859 has been deleted by inv.

SHA-1: efde975a4747e55909d4b722cba7667be0587321