Inkscape in wine in valgrind
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Inkscape |
Invalid
|
Undecided
|
Unassigned |
Bug Description
This isn't exactly a bug, more like a bug in debugging. I'm trying to run inkscape in wine in valgrind, in order to find memory problems with the Windows version. To do so:
1. Boot a Ubuntu 10.04.4 LTS system
2. apt-get update
apt-get upgrade
apt-get install valgrind
reboot
(login again)
valgrind --version #valgrind-
wine --version #wine-1.2.2
3. Transfer via scp directories to /usr/local/src
inkscape3 (holds src, inkscape,build etc.)
mingw
devlibs2 (ignore the 2)
4. On the ubuntu system (via SSH tunnel back to a Cygwin X11 server)
xfterm4
cd /usr/local/
export Path="Z:
#note the case of Path in the preceding, it is for use within wine
5. Test that this version of inkscape.exe will run in wine
wine inkscape.exe
It runs, albeit SLOWLY with a zillion of these:
Xlib: extension "MIT-SHM" missing on display "localhost:10.0".
and some pango messages like:
(inkscape.exe:8): Pango-WARNING **: couldn't load font "MS Shell Dlg Not-Rotated 6.666015625", falling back to "Sans Not-Rotated 6.666015625", expect ugly output.
I did not test it beyond starting it, waiting for the window to open up all the way, and then exiting with ^Q.
6. Test that a simple windows command line program can run in wine in valgrind (used one of my one called extract.exe)
valgrind --trace-
--workaround
wine extract -i >/tmp/extract.log 2>&1
(strange command line args for valgrind from here: http://
That actually ran with the expected output, and buried deep in the resulting 204K log file was the tiny section corresponding to the actual run of extract.exe. So that looked good.
7. Try to run inkscape.exe in wine in valgrind:
valgrind --trace-
--workaround
wine inkscape.exe >/tmp/inkfull.log 2>&1
Here is, naturally, where everything fell apart. Comparing the two log files, at the place where the child process emitted the expected output for extract, there was for inkscape instead a very large number of these (varying at the first address)
==3149== Invalid write of size 4
==3149== at 0x7BC71B3A: ??? (in /usr/lib/
==3149== by 0x7BC73409: ??? (in /usr/lib/
==3149== by 0x418D36F: ??? (in /lib/tls/
==3149== Address 0x7f31f420 is not stack'd, malloc'd or (recently) free'd
followed by a large number of these (also varying at the first address)
==3149== Invalid read of size 4
==3149== at 0x7BC72BE8: set_cpu_context (in /usr/lib/
==3149== by 0x7BC72C81: NtRaiseException (in /usr/lib/
==3149== by 0x7BC72EA3: ??? (in /usr/lib/
==3149== by 0xDEADBABD: ???
==3149== by 0x4A91942: ??? (in /usr/lib/
==3149== by 0x4A91EDB: ??? (in /usr/lib/
==3149== by 0x4A92164: CreateIconFromR
==3149== by 0x4A92B8E: ??? (in /usr/lib/
==3149== by 0x4A92FBF: LoadImageW (in /usr/lib/
==3149== by 0x4A93F7D: LoadImageA (in /usr/lib/
==3149== by 0x4CC8A25: SIC_Initialize (in /usr/lib/
==3149== by 0x4CD2221: ??? (in /usr/lib/
==3149== Address 0x7f31f4f8 is on thread 1's stack
then some more that looked a lot like the preceding, then it went completely off the rails at:
==3149== Jump to the invalid address stated on the next line
==3149== at 0x1CAA0000: ???
==3149== by 0x7FE6125D: ???
==3149== by 0x7FE610E0: ???
==3149== by 0x7BC49D14: ??? (in /usr/lib/
==3149== by 0x7BC4CE32: ??? (in /usr/lib/
==3149== by 0x7BC4D75F: ??? (in /usr/lib/
==3149== by 0x7BC4D731: ??? (in /usr/lib/
==3149== by 0x7BC4D962: ??? (in /usr/lib/
==3149== by 0x4031CFC: ??? (in /usr/lib/
==3149== Address 0x1caa0000 is not stack'd, malloc'd or (recently) free'd
==3149==
err:seh:
then a bunch more error messages until finally something recognizable:
==3149==
err:module:
==3149== Warning: client switching stacks? SP change: 0x7f31fff0 --> 0xbecbadb4
==3149== to suppress, use: --max-stackfram
err:module:
==3149==
We know that when running outside of valgrind "wine inkscape.exe" starts, so the path to find libpopt is OK, and no similar message appears when it is run that way.
At this point I am opening the floor for suggestions about how to go forward from here. One could ignore the stupendous number of valgrind error messages that are from wine itself, but not being able to start the target test program in that doubly nested environment is a deal breaker.
Looks like wine must be built specifically with valgrind suport in mind:
http:// wiki.winehq. org/Wine_ and_Valgrind? action= show&redirect= Valgrind