From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23492 invoked by alias); 18 Apr 2002 22:03:57 -0000 Mailing-List: contact gcc-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-prs-owner@gcc.gnu.org Received: (qmail 23456 invoked by uid 61); 18 Apr 2002 22:03:56 -0000 Date: Thu, 18 Apr 2002 15:03:00 -0000 Message-ID: <20020418220356.23455.qmail@sources.redhat.com> To: W.Stuehlmeyer@t-online.de, gcc-bugs@gcc.gnu.org, gcc-prs@gcc.gnu.org, nobody@gcc.gnu.org, wilson@gcc.gnu.org From: wilson@gcc.gnu.org Reply-To: wilson@gcc.gnu.org, W.Stuehlmeyer@t-online.de, gcc-bugs@gcc.gnu.org, gcc-prs@gcc.gnu.org, nobody@gcc.gnu.org, wilson@gcc.gnu.org, gcc-gnats@gcc.gnu.org Subject: Re: c++/6236: ia64 vtable call - Illegal Instruction X-SW-Source: 2002-04/txt/msg00961.txt.bz2 List-Id: Synopsis: ia64 vtable call - Illegal Instruction Responsible-Changed-From-To: unassigned->wilson Responsible-Changed-By: wilson Responsible-Changed-When: Thu Apr 18 15:03:53 2002 Responsible-Changed-Why: IA-64 maintainer State-Changed-From-To: open->closed State-Changed-By: wilson State-Changed-When: Thu Apr 18 15:03:53 2002 State-Changed-Why: The program fails because it makes incorrect assumptions about the vtable format. Gcc now uses the new multi-vendor C++ ABI. See http://www.codesourcery.com/cxx-abi/ On IA-64, the vtable format does not include function pointers, i.e. an address of a function description. Instead, the vtable includes the actual function descriptor itself. Thus if you pretend the vtable is an array of function addresses, then you will get one more dereference than you want, and the program will fail. Your code will need to be updated to handle the new vtable format correctly. See http://www.codesourcery.com/cxx-abi/abi.html#vtable. The section on function pointers is out of date, the decision was made to use the address/gp pair in the vtable. You can see that if you look through the closed issues list. The link for this is on the first page mentioned above. I don't know if this is documented anywhere in the Intel documentation, but this is the same way that the Intel compiler implements vtables, so this isn't a GNU specific issue. http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=6236