<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
        {font-family:Wingdings;
        panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
/* List Definitions */
@list l0
        {mso-list-id:1792240705;
        mso-list-template-ids:-1;}
@list l0:level1
        {mso-level-number-format:bullet;
        mso-level-text:\F0B7;
        mso-level-tab-stop:.5in;
        mso-level-number-position:left;
        text-indent:-.25in;
        mso-ansi-font-size:10.0pt;
        font-family:Symbol;}
@list l0:level2
        {mso-level-number-format:bullet;
        mso-level-text:o;
        mso-level-tab-stop:1.0in;
        mso-level-number-position:left;
        text-indent:-.25in;
        mso-ansi-font-size:10.0pt;
        font-family:"Courier New";
        mso-bidi-font-family:"Times New Roman";}
@list l0:level3
        {mso-level-number-format:bullet;
        mso-level-text:\F0A7;
        mso-level-tab-stop:1.5in;
        mso-level-number-position:left;
        text-indent:-.25in;
        mso-ansi-font-size:10.0pt;
        font-family:Wingdings;}
@list l0:level4
        {mso-level-number-format:bullet;
        mso-level-text:\F0A7;
        mso-level-tab-stop:2.0in;
        mso-level-number-position:left;
        text-indent:-.25in;
        mso-ansi-font-size:10.0pt;
        font-family:Wingdings;}
@list l0:level5
        {mso-level-number-format:bullet;
        mso-level-text:\F0A7;
        mso-level-tab-stop:2.5in;
        mso-level-number-position:left;
        text-indent:-.25in;
        mso-ansi-font-size:10.0pt;
        font-family:Wingdings;}
@list l0:level6
        {mso-level-number-format:bullet;
        mso-level-text:\F0A7;
        mso-level-tab-stop:3.0in;
        mso-level-number-position:left;
        text-indent:-.25in;
        mso-ansi-font-size:10.0pt;
        font-family:Wingdings;}
@list l0:level7
        {mso-level-number-format:bullet;
        mso-level-text:\F0A7;
        mso-level-tab-stop:3.5in;
        mso-level-number-position:left;
        text-indent:-.25in;
        mso-ansi-font-size:10.0pt;
        font-family:Wingdings;}
@list l0:level8
        {mso-level-number-format:bullet;
        mso-level-text:\F0A7;
        mso-level-tab-stop:4.0in;
        mso-level-number-position:left;
        text-indent:-.25in;
        mso-ansi-font-size:10.0pt;
        font-family:Wingdings;}
@list l0:level9
        {mso-level-number-format:bullet;
        mso-level-text:\F0A7;
        mso-level-tab-stop:4.5in;
        mso-level-number-position:left;
        text-indent:-.25in;
        mso-ansi-font-size:10.0pt;
        font-family:Wingdings;}
ol
        {margin-bottom:0in;}
ul
        {margin-bottom:0in;}
--></style>
</head>
<body lang="EN-US" link="blue" vlink="#954F72" style="word-wrap:break-word">
<div class="WordSection1">
<p class="MsoNormal">Ha, at least now tests 21 through 24 work now :) </p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Yeah, debugger tests are still a pretty unexplored area for me… I haven’t figured out how exactly test 20 is designed and why fails.</p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thanks, Marcel</p>
<p class="MsoNormal">Best,</p>
<p class="MsoNormal">Jaromir</p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div style="mso-element:para-border-div;border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal" style="border:none;padding:0in"><b>From: </b><a href="mailto:marcel.taeumel@hpi.de">Marcel Taeumel</a><br>
<b>Sent: </b>Tuesday, June 14, 2022 10:51<br>
<b>To: </b><a href="mailto:squeak-dev@lists.squeakfoundation.org">squeak-dev</a><br>
<b>Subject: </b>Re: [squeak-dev] The Trunk: Tools-jar.1161.mcz</p>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Hi Christoph, hi Jaromir --<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Reverted via Tools-mt.1163. However, we shoul now fix that failing test #test20TerminateProcess.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Best,<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Marcel<o:p></o:p></span></p>
</div>
<blockquote style="border:none;border-left:solid windowtext 1.0pt;padding:0in 0in 0in 8.0pt;margin-left:0in;margin-top:15.0pt;margin-bottom:5.0pt">
<p style="margin-top:7.5pt"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#AAAAAA">Am 14.06.2022 10:44:19 schrieb Marcel Taeumel <marcel.taeumel@hpi.de>:<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Hi Christoph --<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">In your example, one would just have to #yield the UI process for the moment within #windowIsClosing. ;-) <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">I will revert that for now.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Best,<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Marcel<o:p></o:p></span></p>
</div>
<blockquote style="border:none;border-left:solid windowtext 1.0pt;padding:0in 0in 0in 8.0pt;margin-left:0in;margin-top:15.0pt;margin-bottom:5.0pt">
<p style="margin-top:7.5pt"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#AAAAAA">Am 13.06.2022 21:06:42 schrieb Thiede, Christoph <christoph.thiede@student.hpi.uni-potsdam.de>:<o:p></o:p></span></p>
<div>
<div id="divtagdefaultwrapper">
<div id="divtagdefaultwrapper">
<p><span style="font-size:12.0pt;color:black">Hi Marcel,<o:p></o:p></span></p>
<p><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
<p><span style="font-size:12.0pt;color:black">thank you for the reply!<o:p></o:p></span></p>
<p><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
<p><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
<p><span style="font-size:12.0pt;color:black">> We could not think of a serious issue to use a helper process for termination.<o:p></o:p></span></p>
<p><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
<p><span style="font-size:12.0pt;color:black">Let's construct a simple example:<o:p></o:p></span></p>
<p><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<blockquote style="margin-left:30.0pt;margin-top:5.0pt;margin-right:0in;margin-bottom:5.0pt">
<div>
<div>
<p class="MsoNormal" style="margin-left:30.0pt"><span style="font-size:12.0pt;color:black">m := Morph new.<o:p></o:p></span></p>
</div>
</div>
<div>
<div>
<p class="MsoNormal" style="margin-left:30.0pt"><span style="font-size:12.0pt;color:black">[m halt]<o:p></o:p></span></p>
</div>
</div>
<div>
<div>
<p class="MsoNormal" style="margin-left:30.0pt"><span style="font-size:12.0pt;color:black">ensure: [m delete].<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:30.0pt"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:30.0pt"><span style="font-size:12.0pt;color:black">"From the debugger, abandon the process."<o:p></o:p></span></p>
</div>
</div>
</blockquote>
<div>
<p><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
<p><span style="font-size:12.0pt;color:black">In the past, first, the debugged process was unwound and after that, the UI was resumed.<o:p></o:p></span></p>
<p><span style="font-size:12.0pt;color:black">With the new change, both will happen concurrently. As Morphic is in general not concurrency-safe, this clearly violates the execution semantics from the debugger IMO.<o:p></o:p></span></p>
<p><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
<p><span style="font-size:12.0pt;color:black">> It's not quite different to what the debugger itself does and we also use helper processes to, for example, handle CMD+Dot.<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">I don't see any concurrent UI operations during the opening and closing of the Morphic debugger itself. Also, everything which happens concurrently here is under our explicit control, whereas we
 cannot know what any domain-specific logic in any ensure block of the debugger process might do.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">> > [...] this was visible in the past because the UI was blocked. Now it's no longer possible to see this directly. [...]
<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">> The Process Browser will show this very easily later without disturbing the user's flow for the moment. :-)<o:p></o:p></span></p>
</div>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">But that is very much more indirect and often unseen feedback.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">In 99% of all cases, unwinding will happen without any noticeable delay.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">In the remaining 1%, I argue that there is a high chance that something exceptional and interesting is happening - for instance, some very expensive clean-up code, a deadlock, or some modal operation
 (see also the examples in the appendix). It seems natural to me that "UI is blocked after pressing terminate" indicates that "termination has not yet completed". I think that users will benefit more from that direct feedback than that they will be glad about
 "continuing their work a tiny fraction of a second earlier".<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">We have been very hesitant to use concurrency in general in Squeak until yesterday, and I think this has preserved us from another dimension of complexity and a large number of hard-to-debug issues.
 (The only exception that comes to my mind are things like Shout background styling with a very small scope). Especially, we have never started to distribute user code to multiple processes, which we are effectively doing with this change. I insist that this
 will open a can of worms and will lead us into something like "concurrency hell".<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">Coming from the other side, what is the greatest advantage that this fork could do for us? I could not find any pointer on this in the referenced thread (The Trunk: ToolsTests-ct.107.mcz). The
 only argument seems to be in the version message:<br>
<br>
> Replace termination of the debugged process with an indirect termination via a forked process (otherwise the debugger waits until the debugged process is terminated but if another error is raised during unwind the termination is halted and the assertion fail).
<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">So are we talking about something like this?<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
</div>
<blockquote style="margin-left:30.0pt;margin-top:5.0pt;margin-right:0in;margin-bottom:5.0pt">
<div>
<div>
<p class="MsoNormal" style="margin-left:30.0pt"><span style="font-size:12.0pt;color:black">[self halt] ensure: [self error].<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:30.0pt"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal" style="margin-left:30.0pt"><span style="font-size:12.0pt;color:black">"Terminate from halt, then proceed from error"<o:p></o:p></span></p>
</div>
</div>
</blockquote>
<div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">Indeed this requires a user interrupt before seeing the second debugger if we don't fork in #windowIsClosing. However, as this does not happen when you #abandon instead of #terminate, I would rather
 suspect the new implementation of #terminate here (which I have not yet found the time to study). If this is the only reason for the #fork, I would consider the #fork a workaround for an issue in #terminate. From the perspective of getting the release done,
 I don't think that this special case (which is anyway kind of hidden via the debugger's window menu) should be prioritized higher than the negative consequences I mentioned above. Also, we don't support this case very well at all at the moment: if you abandon
 the second debugger, a MessageNotUnderstood: UndefinedObject>>stepToCallee will be raised from Context>>runUntilErrorOrReturnFrom:. Something else to investigate. :-)<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">(PS: Note to myself: We should have one or two explicit DebuggerTest for this situation.)<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">Also, note that the new implementation of #windowIsClosing leads to two dangling processes from running all DebuggerTests (nil MNU for interruptedProcess in #windowIsClosing) despite all tests
 are passing.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">tl;dr: I strongly vote for removing that #fork for two reasons: unexpected/unmanageable concurrency in user code, and a bad trade-off between beauty and informativeness.<o:p></o:p></span></p>
</div>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">But I'm always open to your arguments. :-)<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">Best,<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">Christoph<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black">Appendix 1 - further observations for terminate/abandon from debugger and comments:<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
</div>
<div>
<ul type="disc">
<li class="MsoNormal" style="color:black;mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;mso-list:l0 level1 lfo1">
<span style="font-size:12.0pt">[self halt] ensure: [1 second wait]. "Let the user know that something is happening"<o:p></o:p></span></li><li class="MsoNormal" style="color:black;mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;mso-list:l0 level1 lfo1">
<span style="font-size:12.0pt">[self halt] ensure: [self inform: #foo]. "! When should the debugger window disappear?<br>
If we had a proper hook for this in SystemWindow, I think that the termination should take place even BEFORE the window is actually deleted. This would make the aforementioned feedback even easier to grasp.<br>
(Asked differently, why is #windowIsClosing sent when the window has been deleted already? Shouldn't it be rather named #windowHasClosed then?)"<o:p></o:p></span></li><li class="MsoNormal" style="color:black;mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;mso-list:l0 level1 lfo1">
<span style="font-size:12.0pt">[self halt] ensure: [[Project current world doOneCycle.  Processor yield ] repeat]. "Do it, abandon, interrupt, abandon, then watch the process browser. Not a regression, but we have a stale process at [] in Context>>resume: here."<o:p></o:p></span></li><li class="MsoNormal" style="color:black;mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;mso-list:l0 level1 lfo1">
<span style="font-size:12.0pt">[self halt] ensure: [Transcript showln: Processor activeProcess = Project uiProcess]. "Outputs false after abandon. Not a regression, but this looks suspicious to me. I think we should temporarily set Project >> #uiProcess: back
 to the interruptedProcess in #windowIsClosing. Unfortunately, this only works in Morphic."<o:p></o:p></span></li></ul>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></p>
<div>
<p class="MsoNormal"><img border="0" width="326" height="2" style="width:3.3958in;height:.0208in" id="Horizontal_x0020_Line_x0020_1" src="cid:image002.png@01D87FDE.7B154B50"><span style="font-size:12.0pt;color:black"><o:p></o:p></span></p>
<div id="divRplyFwdMsg">
<p class="MsoNormal"><b><span style="font-size:12.0pt;color:black">Von:</span></b><span style="font-size:12.0pt;color:black"> Squeak-dev <squeak-dev-bounces@lists.squeakfoundation.org> im Auftrag von Taeumel, Marcel<br>
<b>Gesendet:</b> Montag, 13. Juni 2022 14:50 Uhr<br>
<b>An:</b> squeak-dev<br>
<b>Betreff:</b> Re: [squeak-dev] The Trunk: Tools-jar.1161.mcz <o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;color:black"> <o:p></o:p></span></p>
</div>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">That said, if we discover a serious issue during the next days, we can always make process termination in the debugger synchronous again.
<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Best,<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Marcel<o:p></o:p></span></p>
</div>
<blockquote style="border:none;border-left:solid windowtext 1.0pt;padding:0in 0in 0in 8.0pt;margin-left:0in;margin-top:15.0pt;margin-bottom:5.0pt">
<p style="margin-top:7.5pt"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#AAAAAA">Am 13.06.2022 14:49:05 schrieb Marcel Taeumel <marcel.taeumel@hpi.de>:<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">> [...] this was visible in the past because the UI was blocked. Now it's no longer possible to see this directly. [...]
<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">The Process Browser will show this very easily later without disturbing the user's flow for the moment. :-)<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Best,<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Marcel<o:p></o:p></span></p>
</div>
<blockquote style="border:none;border-left:solid windowtext 1.0pt;padding:0in 0in 0in 8.0pt;margin-left:0in;margin-top:15.0pt;margin-bottom:5.0pt">
<p style="margin-top:7.5pt"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#AAAAAA">Am 13.06.2022 14:48:01 schrieb Marcel Taeumel <marcel.taeumel@hpi.de>:<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Hi Christoph --
<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">I double-checked with Tom (tobe) on this. We could not think of a serious issue to use a helper process for termination. It's not quite different to what the debugger
 itself does and we also use helper processes to, for example, handle CMD+Dot.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Best,<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Marcel<o:p></o:p></span></p>
</div>
<blockquote style="border:none;border-left:solid windowtext 1.0pt;padding:0in 0in 0in 8.0pt;margin-left:0in;margin-top:15.0pt;margin-bottom:5.0pt">
<p style="margin-top:7.5pt"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#AAAAAA">Am 13.06.2022 14:03:13 schrieb Christoph Thiede <christoph.thiede@student.hpi.uni-potsdam.de>:<o:p></o:p></span></p>
<div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Hi Jaromir,
<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">sorry for not responding earlier!<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">> Replace termination of the debugged process with an indirect termination via a forked process (otherwise the debugger waits until the debugged process is terminated
 but if another error is raised during unwind the termination is halted and the assertion fail).<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Could you elaborate further on that? I have a bad feeling with it. If the termination behaves suspiciously and takes a longer time, or the process never ends (e.g.
 via a non-local return), this was visible in the past because the UI was blocked. Now it's no longer possible to see this directly. Furthermore, anything might happen during the termination which now happens in a separate process, opening a potential can of
 worm of concurrency issues (see also "async hell"). Couldn't we simply keep the termination running synchronously? User interrupt will still work if something goes wrong with the termination, but at least the user will notice.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Best,<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Christoph<o:p></o:p></span></p>
</div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Am 13.06.2022 09:42 schrieb commits@source.squeak.org:<br>
<br>
<o:p></o:p></span></p>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-top:5.0pt;margin-right:0in;margin-bottom:5.0pt">
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Marcel Taeumel uploaded a new version of Tools to project The Trunk:<br>
http://source.squeak.org/trunk/Tools-jar.1161.mcz<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">==================== Summary ====================<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Name: Tools-jar.1161<br>
Author: jar<br>
Time: 9 June 2022, 1:57:46.549529 pm<br>
UUID: f3921b2b-5628-104d-98a9-1e99671344a2<br>
Ancestors: Tools-ct.1160<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Fix an inconsistent Debugger behavior WRT the new alternative abandon/terminate/destroy modes introduced by Kernel-ct.1434 and Tools-ct.1092.<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">The suggestion is to make all three termination methods equal in terms of how the chosen termination mode is propagated to #windowIsClosing. Current asymmetrical approach leads to
 an incorrect debugger termination via #terminate mode. <o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Replace termination of the debugged process with an indirect termination via a forked process (otherwise the debugger waits until the debugged process is terminated but if another
 error is raised during unwind the termination is halted and the assertion fail).<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Following up a conversation in http://lists.squeakfoundation.org/pipermail/squeak-dev/2022-May/220675.html<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Complemented by ToolsTests-jar.111 fixing the failing/incorrects tests in ToolsTests-ct.107<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Please review as I'm no debugger expert and this is just my suggestion.<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Superseeds (or replaces) Tools-jar.1159 (please kindly remove from Inbox)<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">=============== Diff against Tools-ct.1160 ===============<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Item was changed:<br>
  CodeHolder subclass: #Debugger<br>
+ instanceVariableNames: 'interruptedProcess contextStack contextStackIndex contextStackList receiverInspector receiverInspectorState contextVariablesInspector contextVariablesInspectorState externalInterrupt proceedValue selectingPC savedCursor isolationHead
 failedProject labelString message untilExpression terminationMethod'<br>
- instanceVariableNames: 'interruptedProcess contextStack contextStackIndex contextStackList receiverInspector receiverInspectorState contextVariablesInspector contextVariablesInspectorState externalInterrupt proceedValue selectingPC savedCursor isolationHead
 failedProject labelString message untilExpression'<br>
  classVariableNames: 'ContextStackKeystrokes ErrorReportServer FullStackSize InterruptUIProcessIfBlockedOnErrorInBackgroundProcess NotifierStackSize SavedExtent StackSizeLimit WantsAnnotationPane'<br>
  poolDictionaries: ''<br>
  category: 'Tools-Debugger'!<br>
  <br>
  !Debugger commentStamp: 'mt 12/17/2019 12:19' prior: 0!<br>
  I represent the machine state at the time of an interrupted process. I also represent a query path into the state of the process. The debugger is typically viewed through a window that views the stack of suspended contexts, the code for, and execution point
 in, the currently selected message, and inspectors on both the receiver of the currently selected message, and the variables in the current context.<br>
  <br>
  Special note on recursive errors:<br>
  Some errors affect Squeak's ability to present a debugger.  This is normally an unrecoverable situation.  However, if such an error occurs in an isolation layer, Squeak will attempt to exit from the isolation layer and then present a debugger.  Here is the
 chain of events in such a recovery.<br>
  <br>
  * A recursive error is detected.<br>
  * The current project is queried for an isolationHead<br>
  * Changes in the isolationHead are revoked<br>
  * The parent project of isolated project is returned to<br>
  * The debugger is opened there and execution resumes.<br>
  <br>
  If the user closes that debugger, execution continues in the outer project and layer.  If, after repairing some damage, the user proceeds from the debugger, then the isolationHead is re-invoked, the failed project is re-entered, and execution resumes in that
 world. <br>
  <br>
  ---<br>
  <br>
  In September 2019, we added MorphicDebugger and MVCDebugger to untangle framework-specific features in our debugger infrastructure. However, this is just an intermediate step. The overall goal would be to remove those two subclasses again while preserving
 their functionality. Mostly, MVC and Morphic differ in their GUI-process management. This means that "proceed" and "close" work differently depending on the process that is being debugged. --- One idea is to attach that framework-specific information to the
 process objects. See Process >> #environmentAt: and #environmentAt:put:. Also see ToolSet's #handle* and #debug* methods.!<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Item was changed:<br>
  ----- Method: Debugger>>abandon (in category 'context stack menu') -----<br>
  abandon<br>
+ "close the debugger and terminate the debugged process"<br>
- "abandon the debugger from its pre-debug notifier"<br>
  <br>
+ terminationMethod := #terminateAggressively.<br>
+ self close<br>
+ !<br>
- self close.!<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Item was changed:<br>
  ----- Method: Debugger>>initialize (in category 'initialize') -----<br>
  initialize<br>
  <br>
  super initialize.<br>
  <br>
  Smalltalk at: #MessageTally ifPresentAndInMemory: [ :tally |<br>
  tally terminateTimerProcess].<br>
  <br>
  externalInterrupt := false.<br>
  selectingPC := true.<br>
  <br>
+ contextStackIndex := 0.<br>
+ <br>
+ terminationMethod := #terminateAggressively "debugger's default termination method"!<br>
- contextStackIndex := 0.!<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Item was changed:<br>
  ----- Method: Debugger>>terminateProcess (in category 'context stack menu') -----<br>
  terminateProcess<br>
+ "close the debugger and terminate the debugged process"<br>
  <br>
+ terminationMethod := #terminate.<br>
+ self close<br>
+ !<br>
- interruptedProcess terminate.<br>
- interruptedProcess := nil.<br>
- self close.!<o:p></o:p></span></p>
<p><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black">Item was changed:<br>
  ----- Method: Debugger>>windowIsClosing (in category 'initialize') -----<br>
  windowIsClosing<br>
  "My window is being closed; clean up. Restart the low space watcher."<br>
  <br>
  contextStack := nil.<br>
  receiverInspector := nil.<br>
  contextVariablesInspector := nil.<br>
  <br>
  interruptedProcess == nil ifTrue: [^ self].<br>
+ [interruptedProcess perform: terminationMethod.<br>
+ interruptedProcess := nil] fork.<br>
- interruptedProcess terminateAggressively.<br>
- interruptedProcess := nil.<br>
  <br>
  Smalltalk installLowSpaceWatcher.  "restart low space handler"!<o:p></o:p></span></p>
</blockquote>
</div>
</div>
</div>
</div>
</blockquote>
</div>
</blockquote>
</div>
</blockquote>
</div>
</div>
</div>
</div>
</div>
</blockquote>
</div>
</blockquote>
<p class="MsoNormal" style="mso-margin-top-alt:0in;margin-right:2.5in;margin-bottom:5.0pt;margin-left:0in">
<span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</body>
</html>