Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 48613

Summary: I get an SIGFPE (Arithmetic exception) in r200_dri.so when debugging an opengl application with gdb.
Product: Gentoo Linux Reporter: Diederik van der Boor <mail-gentoobugs>
Component: [OLD] DevelopmentAssignee: Gentoo's Team for Core System packages <base-system>
Status: RESOLVED INVALID    
Severity: blocker    
Priority: High    
Version: unspecified   
Hardware: x86   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Diederik van der Boor 2004-04-21 14:55:13 UTC
I'm developing an OpenGL viewer for a school project, but I can't seam to debug it with gdb. Each time gdb starts, I get a SIGFPE.

(gdb) run
Starting program: /home/diederik/werk/3dviewer-pascal/3dviewer
[Thread debugging using libthread_db enabled]
[New Thread 16384 (LWP 16655)]

Program received signal SIGFPE, Arithmetic exception.
[Switching to Thread 16384 (LWP 16655)]
0x403bc29c in _mesa_test_os_sse_exception_support () from /usr/X11R6/lib/modules/dri/r200_dri.so


Reproducible: Always
Steps to Reproduce:
Comment 1 Daniel Black (RETIRED) gentoo-dev 2004-04-23 17:40:14 UTC
Which version of gdb (emerge -pv gdb) are you using? does a version bump fix it? Search the developer's of gdbs mail list for an error similar error. if all else fails can you include the code section of your school project here.
Comment 2 Defresne Sylvain (keiichi) 2004-05-01 02:09:21 UTC
That is SSE detection code.  It tests for SSE by installing a signal handler,
then executing SSE code.  If the processor doesn't support SSE, a signal is
triggered and handled properly, then things proceed.  However if you're running
it in a debugger, then the SEGV will get trapped by gdb instead of going to
the Mesa handler.  So you have to "cont" to let it be handled, and let the
code proceed to the real problem.

[ Read from http://bugzilla.redhat.com/bugzilla/long_list.cgi?buglist=106566 ]
Comment 3 Maurice van der Pot (RETIRED) gentoo-dev 2004-05-26 08:51:59 UTC
Note: The parent poster meant that the SIGFPE will get trapped by gdb. The redhat bugreport is primarily about a SEGV, but the SIGFPE issue is briefly mentioned.

If you do not want gdb to stop when a SIGFPE is generated, you can change the way it is handled by doing:

handle SIGFPE nostop

or even:

handle SIGFPE nostop noprint

This is not a bug.
Comment 4 Maurice van der Pot (RETIRED) gentoo-dev 2004-10-23 14:39:53 UTC
Closing as invalid.