{"id":117,"date":"2009-05-29T11:16:27","date_gmt":"2009-05-29T00:16:27","guid":{"rendered":"http:\/\/blog.mozilla.org\/nnethercote\/?p=117"},"modified":"2009-05-29T11:16:27","modified_gmt":"2009-05-29T00:16:27","slug":"valgrind-on-windows","status":"publish","type":"post","link":"https:\/\/blog.mozilla.org\/nnethercote\/2009\/05\/29\/valgrind-on-windows\/","title":{"rendered":"Valgrind on Windows?"},"content":{"rendered":"<p>With the Valgrind-on-Mac support <a href=\"http:\/\/blog.mozilla.org\/nnethercote\/2009\/05\/28\/mac-os-x-now-supported-on-the-valgrind-trunk\/\">coming along nicely<\/a>, it&#8217;s worth addressing another widely-used platform:\u00a0 Windows.\u00a0 Will Valgrind work on Windows any time soon?\u00a0 There are actually two answers:\u00a0 (a) hell no, and (b) it already does (sort of).<\/p>\n<p>The patch I merged from the Darwin branch onto the trunk yesterday was 28,300 lines.\u00a0 And that was almost entirely new code, because I&#8217;d done a lot of work to synchronize the branch and trunk so that all non-addition changes had been dealt with.\u00a0 Greg Parker spent over four years, off and on, working on the original port, and I spent close to three months full time cleaning it up, and Julian Seward also pitched in a bit.\u00a0 I roughly estimate the Darwin port represents at least 1,000 person-hours of work, possibly much more.<\/p>\n<p>And Mac OS X is a <strong>lot<\/strong> closer to Linux than Windows is.\u00a0 Also, the Mac OS X kernel is open source, which makes a port much easier.\u00a0 A Valgrind-on-Windows port would therefore be an enormous undertaking, one that is unlikely to happen soon, if ever.\u00a0 That is how we get answer (a) above.<\/p>\n<p>However, although Valgrind doesn&#8217;t run on Windows, it is possible to run Windows programs under Valgrind, thanks to <a href=\"http:\/\/www.winehq.org\/\">Wine<\/a> &#8212; you run the Windows program under Wine, and Wine under Valgrind.\u00a0 The development (trunk) versions of both Valgrind and Wine now have enough awareness of each other that they can apparently be used together.\u00a0 I say &#8220;apparently&#8221; because I haven&#8217;t tried it myself, but I know that others have had some success.\u00a0 But please note that this is fairly new and experimental, and should only be tried by those not afraid to get their hands dirty (<a href=\"http:\/\/wiki.winehq.org\/Wine_and_Valgrind\">this page<\/a> has more details). And that&#8217;s how we get the answer (b) above.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>With the Valgrind-on-Mac support coming along nicely, it&#8217;s worth addressing another widely-used platform:\u00a0 Windows.\u00a0 Will Valgrind work on Windows any time soon?\u00a0 There are actually two answers:\u00a0 (a) hell no, and (b) it already does (sort of). The patch I merged from the Darwin branch onto the trunk yesterday was 28,300 lines.\u00a0 And that was [&hellip;]<\/p>\n","protected":false},"author":139,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"_links":{"self":[{"href":"https:\/\/blog.mozilla.org\/nnethercote\/wp-json\/wp\/v2\/posts\/117"}],"collection":[{"href":"https:\/\/blog.mozilla.org\/nnethercote\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.mozilla.org\/nnethercote\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.mozilla.org\/nnethercote\/wp-json\/wp\/v2\/users\/139"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.mozilla.org\/nnethercote\/wp-json\/wp\/v2\/comments?post=117"}],"version-history":[{"count":0,"href":"https:\/\/blog.mozilla.org\/nnethercote\/wp-json\/wp\/v2\/posts\/117\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.mozilla.org\/nnethercote\/wp-json\/wp\/v2\/media?parent=117"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.mozilla.org\/nnethercote\/wp-json\/wp\/v2\/categories?post=117"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.mozilla.org\/nnethercote\/wp-json\/wp\/v2\/tags?post=117"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}