To use valgrind, do ./configure --enable-debug, then I find it easier to launch X by hand, so something like:
$ sudo valgrind --trace-children /usr/bin/Xorg -ac -noreset 2>&1 | tee /tmp/xorg.txt
switch back to a second VT, or login in remotely, then $ DISPLAY=:0 gnome-session
switch back to X
Running under valgrind, you will notice a slowdown, but not quite as much as perhaps you would imagine.
To use valgrind, do ./configure --enable-debug, then I find it easier to launch X by hand, so something like:
$ sudo valgrind --trace-children /usr/bin/Xorg -ac -noreset 2>&1 | tee /tmp/xorg.txt
switch back to a second VT, or login in remotely, then
$ DISPLAY=:0 gnome-session
switch back to X
Running under valgrind, you will notice a slowdown, but not quite as much as perhaps you would imagine.