Comment 48 for bug 921236

Revision history for this message
In , Helmling (helmling) wrote :

Here's my gdb session. Had to "set can-use-hw-breakpoints 0", don't know if this is a problem. :-) Also, I had to recompile with -O0 instead of -O1, otherwise gdb would report that xf86_config->BlockHandler is optimized out.
I don't have any experience using gdb; hope this is of any use for you ...

# gdb X
GNU gdb (GDB) 7.4
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
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 "x86_64-unknown-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/bin/X...done.
(gdb) break xf86RotateBlockHandler
Breakpoint 1 at 0x4ab16c: file xf86Rotate.c, line 267.
(gdb) set can-use-hw-watchpoints 0
(gdb) run
Starting program: /usr/bin/X
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/libthread_db.so.1".

X.Org X Server 1.12.0
Release Date: 2012-03-04
X Protocol Version 11, Revision 0
Build Operating System: Linux 3.2.11-1-ARCH x86_64
Current Operating System: Linux utahraptor 3.2.11-1-ARCH #1 SMP PREEMPT Thu Mar 15 09:19:02 CET 2012 x86_64
Kernel command line: BOOT_IMAGE=/boot/vmlinuz-linux root=/dev/mapper/ssdvg-arch ro quiet
Build Date: 19 March 2012 10:45:43AM

Current version of pixman: 0.24.4
        Before reporting problems, check http://wiki.x.org
        to make sure that you have the latest version.
Markers: (--) probed, (**) from config file, (==) default setting,
        (++) from command line, (!!) notice, (II) informational,
        (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/Xorg.0.log", Time: Mon Mar 19 10:51:22 2012
(==) Using config directory: "/etc/X11/xorg.conf.d"
[tcsetpgrp failed in terminal_inferior: Die Operation ist nicht erlaubt]
The XKEYBOARD keymap compiler (xkbcomp) reports:
> Warning: Multiple interpretations of "Caps_Lock+AnyOfOrNone(all)"
> Using last definition for duplicate fields
> Warning: Multiple interpretations of "Shift_L+AnyOfOrNone(all)"
> Using last definition for duplicate fields
> Warning: Type "ONE_LEVEL" has 1 levels, but <LSGT> has 4 symbols
> Ignoring extra symbols
> Warning: Type "ONE_LEVEL" has 1 levels, but <BKSL> has 2 symbols
> Ignoring extra symbols
> Warning: Type "ONE_LEVEL" has 1 levels, but <RALT> has 2 symbols
> Ignoring extra symbols
Errors from xkbcomp are not fatal to the X server

Breakpoint 1, xf86RotateBlockHandler (screenNum=0, blockData=0x0, pTimeout=0x7fffc47c4d38, pReadmask=0x7dc0c0) at xf86Rotate.c:267
267 ScreenPtr pScreen = screenInfo.screens[screenNum];
(gdb) watch xf86_config->BlockHandler
Watchpoint 2: xf86_config->BlockHandler
(gdb) continue
Continuing.
Watchpoint 2: xf86_config->BlockHandler

Old value = <unreadable>
New value = (ScreenBlockHandlerProcPtr) 0
xf86RotateBlockHandler (screenNum=0, blockData=0x0, pTimeout=0x7fffc47c4d38, pReadmask=0x7dc0c0) at xf86Rotate.c:272
272 rotation_active = xf86RotateRedisplay(pScreen);
(gdb) continue
Continuing.

Program received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()