From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24078 invoked by alias); 17 Jun 2005 19:01:43 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 24049 invoked by uid 48); 17 Jun 2005 19:01:35 -0000 Date: Fri, 17 Jun 2005 19:01:00 -0000 Message-ID: <20050617190135.24047.qmail@sourceware.org> From: "lmakhlis at bmc dot com" To: gcc-bugs@gcc.gnu.org In-Reply-To: <20050615205609.22083.lmakhlis@bmc.com> References: <20050615205609.22083.lmakhlis@bmc.com> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug target/22083] [3.4/4.0/4.1 Regression] TARGET_C99_FUNCTIONS is wrongly defined on AIX 5.1 X-Bugzilla-Reason: CC X-SW-Source: 2005-06/txt/msg02299.txt.bz2 List-Id: ------- Additional Comments From lmakhlis at bmc dot com 2005-06-17 19:01 ------- It might be an issue with the patch level of libm -- I was testing on 5.1 ML04, which was released in 2002 -- but I've found another machine at ML05 (released in Oct 2003), and it still doesn't have sqrtf and friends in libm. I don't have access to anything newer than that right now. I doubt it's related to Visual Age. VAC's implementation of the standard C++ library, /usr/lib/libC.a, does have sqrtf and friends -- but I'm not linking with it when using GCC. Before submitting the bug report, I tried removing the macro definition in aix51.h, and it does solve the problem. There is a related C++-specific problem that still isn't solved, but maybe that merits a separate PR. The problem is: If you have C++ code that uses std::sqrt(float) and build a dynamically linked executable on AIX 5.1, then bring it over to AIX 5.2, it won't run, because sqrtf() is now in libm, but not in libstdc++. This doesn't seem to be a problem on other platforms (for example, a program compiled on Solaris 8, against sqrtf() in libstdc++, runs fine on Solaris 10, with sqrtf() in libm), but on AIX the dynamic loader looks for a symbol only in a specific library. I am guessing it's a difference between COFF and ELF? As a side point, TARGET_C99_FUNCTION isn't defined on any Solaris platforms. I think it's okay to define it on Solaris 9 and up? -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22083