|
From: Robert W. <rj...@du...> - 2003-09-14 00:48:28
|
Hi Matthew, The new watchpoint patch is now available at: http://www.durables.org/software/valgrind/ To set watchpoints on the command line, use the following option: --watchpoint=3DWP If WP is a single number, watch that address only. If WP is of the form X-Y, watch the range of addresses from X to Y. If WP is of the form X+Y, watch the range of addresses from X to X+Y. X and Y can be decimal or hexadecimal numbers. Hex numbers are prefixed by 0x. You can specify as many watchpoints as you want. e.g.: valgrind --watchpoint=3D0xBFFFF400 ls This watches the single byte at 0xBFFFF400 valgrind --watchpoint=3D0xBFFFF400-0xBFFFF500 This watches the range from 0xBFFFF400 to 0xBFFFF500. valgrind --watchpoint=3D0xBFFFF500+256 This watches the 256 bytes starting at 0xBFFFF500 Watchpoints will be triggered if: * the watched addresses are read from or written to * the watched addresses go in to or out of scope on the stack * memory is allocated or freed over the watched addresses Let me know if you run into any problems with this. Regards, Robert. --=20 Robert Walsh Amalgamated Durables, Inc. - "We don't make the things you buy." Email: rj...@du... |