<html><head><meta http-equiv="Content-Type" content="text/html charset=iso-8859-1"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><br><div><div>On Mar 7, 2013, at 3:53 PM, Anton Yartsev <<a href="mailto:anton.yartsev@gmail.com">anton.yartsev@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;">On 07.03.2013 21:29, Jordan Rose wrote:<br><blockquote type="cite">On Mar 7, 2013, at 4:47 , Anton Yartsev <<a href="mailto:anton.yartsev@gmail.com">anton.yartsev@gmail.com</a>> wrote:<br><br><blockquote type="cite">On 06.03.2013 21:46, Anna Zaks wrote:<br><blockquote type="cite">CC-ing the patch author!<br><br>Also,<br><br>Could you split out the ObjC NoCopy + FreeWhenDone change into a separate patch. It does not seem to be directly related to the other changes. Also, I am not 100% sure what changes we are making there. One part is refactoring, however, you've also removed the check for the message calls from the doesNotFreeMemory(). Do we expect any behavior changes from this?<br>(Sorry if I've missed something; the patch is getting big.)<br></blockquote>Splitted ObjC NoCopy + FreeWhenDone change, kept changes in doesNotFreeMemory().<br>The logic of doesNotFreeMemory() was broken - it treated all 'NoCopy' and 'FreeWhenDone==1' methods as freeing memory and unknown to us. This lead to removal of RefState from the State and impossibility for further alloc/dealloc matching analysis.<br></blockquote>Can we just do the Objective-C part first? Can you send that patch too?<br></blockquote>Attached. I'll update the main patch after this one gets in.<br><br></div></blockquote><br>This has a functionality change (as Anton mentioned in one of the previous emails). It's an enhancement - we are now tracking the object after it's been freed with the NoCopy functions. As such, the patch needs a test case. I think you should be able to test for double free here.</div><div><br></div><div>Anna.<br><blockquote type="cite"><div style="letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;"><blockquote type="cite"><blockquote type="cite">Have not found any suitable place in lib/Frontend/CompilerInvocation.cpp<br>Did you mean to update clang/lib/Driver/Tools.cpp ?<br></blockquote>Whoops, I grepped for "unix" and found the comment there. You're right, and that's the right change.<br></blockquote><br>--<span class="Apple-converted-space"> </span><br>Anton<br><br><span><MallocCheckerRefactoring.patch></span></div></blockquote></div><br></body></html>