From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19035 invoked by alias); 13 Jul 2010 21:51:45 -0000 Received: (qmail 18992 invoked by uid 48); 13 Jul 2010 21:51:35 -0000 Date: Tue, 13 Jul 2010 21:51:00 -0000 Message-ID: <20100713215135.18991.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug c++/44810] [4.6 Regression] FAIL: g++.dg/torture/pr36745.C In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "jason at gcc dot gnu dot org" 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 X-SW-Source: 2010-07/txt/msg01441.txt.bz2 ------- Comment #4 from jason at gcc dot gnu dot org 2010-07-13 21:51 ------- I disagree with the analysis. In fact, QMapData::shared_null correctly gets 32-bit DECL_ALIGN once we walk the pending_statics vector in finish_record_layout. But this is irrelevant. The problem is that at the point of the error we're trying to use &QVectorData::shared_null, which properly has 8-bit alignment, as a QVectorTypedData*. This seems to be a problem with the testcase: the QVector constructor first initializes the p member of the anonymous union with &QVectorData::shared_null and then tries to access the ref member of the d member of the anonymous union, but that memory access would spill off the end of the actual referent of the pointer. Do you agree that the problem is that the testcase is undefined? -- jason at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |rguenth at gcc dot gnu dot | |org AssignedTo|jason at gcc dot gnu dot org|unassigned at gcc dot gnu | |dot org Status|ASSIGNED |NEW http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44810