From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30883 invoked by alias); 31 Oct 2013 16:00:31 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 30829 invoked by uid 48); 31 Oct 2013 16:00:26 -0000 From: "Dimitar.Peikov at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/58943] New: wrong calculation of indirect structure member arithmetic via function call Date: Thu, 31 Oct 2013 16:00:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c X-Bugzilla-Version: 4.8.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: critical X-Bugzilla-Who: Dimitar.Peikov at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-10/txt/msg02340.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58943 Bug ID: 58943 Summary: wrong calculation of indirect structure member arithmetic via function call Product: gcc Version: 4.8.1 Status: UNCONFIRMED Severity: critical Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: Dimitar.Peikov at gmail dot com Created attachment 31124 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=31124&action=edit example for failed structure propagation In attached file there is an example of invalid calculation where, a structure with integer is manipulated inside a function call which takes struct as pointer and same integer member is part of arithmetic result operation. The issue was tested on several compilers 4.6.3, 4.7.2, 4.8.1 on different platforms Linux and Windows with same result.