From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10183 invoked by alias); 13 Nov 2008 14:35:03 -0000 Received: (qmail 10113 invoked by uid 22791); 13 Nov 2008 14:35:01 -0000 X-Spam-Check-By: sourceware.org Received: from ocean.emcraft.com (HELO ocean.emcraft.com) (213.221.7.182) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 13 Nov 2008 14:33:55 +0000 Received: from [172.17.0.10] (helo=[172.17.0.10]) by ocean.emcraft.com with esmtp (Exim 4.43) id 1L0dGY-0004kg-T2; Thu, 13 Nov 2008 17:33:51 +0300 Message-ID: <491C3ACE.2050201@emcraft.com> Date: Thu, 13 Nov 2008 14:35:00 -0000 From: Sergei Poselenov User-Agent: Thunderbird 1.5.0.7 (X11/20061008) MIME-Version: 1.0 To: gdb@sources.redhat.com Subject: ARM EABI: GDB internal error on printing out float (VFP math) Content-Type: text/plain; charset=KOI8-R; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -4.4 (----) X-Spam-Report: Spam detection software, running on the system "pacific.emcraft.com", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Hello all, I've ran into this running the GDB testsuite, store.exp. -bash-3.2# gdb store GNU gdb Red Hat Linux (6.7-1rh) Copyright (C) 2007 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "arm-linux"... Using host libthread_db library "/lib/libthread_db.so.1". (gdb) b wack_float Breakpoint 1 at 0x837c: file /opt/eldk42armFP/armFP/tmp/store.c, line 11. (gdb) r Starting program: /tmp/store [...] Content analysis details: (-4.4 points, 2.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.8 ALL_TRUSTED Passed through trusted hosts only via SMTP -2.6 BAYES_00 BODY: Bayesian spam probability is 0 to 1% [score: 0.0000] Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2008-11/txt/msg00103.txt.bz2 Hello all, I've ran into this running the GDB testsuite, store.exp. -bash-3.2# gdb store GNU gdb Red Hat Linux (6.7-1rh) Copyright (C) 2007 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "arm-linux"... Using host libthread_db library "/lib/libthread_db.so.1". (gdb) b wack_float Breakpoint 1 at 0x837c: file /opt/eldk42armFP/armFP/tmp/store.c, line 11. (gdb) r Starting program: /tmp/store Breakpoint 1, wack_float (u=-1, v=-2) at /opt/eldk42armFP/armFP/tmp/store.c:11 11 register float l = u, r = v; (gdb) n 12 l = add_float (l, r); (gdb) p r ../../gdb/regcache.c:178: internal-error: register_size: Assertion `regnum >= 0 && regnum < (gdbarch_num_regs (current_gdbarch) + gdbarch_num_pseudo_regs (current_gdbarch))' failed. A problem internal to GDB has been detected, further debugging may prove unreliable. Quit this debugging session? (y or n) Here is the reduced testcase: float add_float (register float u, register float v) { return u + v; } float wack_float (register float u, register float v) { register float l = u, r = v; l = add_float (l, r); return l + r; } int main () { wack_float (-1, -2); return 0; } The test was built as follows: arm-linux-gcc -o store -g store.c -mfpu=vfp -mfloat-abi=softfp arm-linux-gcc -v Reading specs from /opt/eldk-4.2-arm-2008-10-21/usr/bin/../lib/gcc/arm-linux-gnueabi/4.2.2/specs Target: arm-linux-gnueabi Configured with: /work/psl/eldk-builds/arm-2008-10-21/work/usr/src/denx/BUILD/crosstool-0.43/build/gcc-4.2.2-glibc-20070515T2025-eldk/arm-linux-gnueabi/gcc-4.2.2/configure --target=arm-linux-gnueabi --host=i686-host_pc-linux-gnu --prefix=/var/tmp/eldk.F0dvjm/usr/crosstool/gcc-4.2.2-glibc-20070515T2025-eldk/arm-linux-gnueabi --disable-hosted-libstdcxx --with-headers=/var/tmp/eldk.F0dvjm/usr/crosstool/gcc-4.2.2-glibc-20070515T2025-eldk/arm-linux-gnueabi/arm-linux-gnueabi/include --with-local-prefix=/var/tmp/eldk.F0dvjm/usr/crosstool/gcc-4.2.2-glibc-20070515T2025-eldk/arm-linux-gnueabi/arm-linux-gnueabi --disable-nls --enable-threads=posix --enable-symvers=gnu --enable-__cxa_atexit --enable-languages=c,c++,java --enable-shared --enable-c99 --enable-long-long --without-x Thread model: posix gcc version 4.2.2 The problem reproduced with GDB 6.8-release, as well. Thanks for any help, Sergei