<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div dir="ltr"><br></div><div dir="ltr"><br><blockquote type="cite">On Sep 29, 2020, at 1:07 AM, Marcel Taeumel <marcel.taeumel@hpi.de> wrote:<br><br></blockquote></div><blockquote type="cite"><div dir="ltr"><div id="__MailbirdStyleContent" style="font-size: 10pt;font-family: Arial;color: #000000">
                                        
                                        
                                            
                                        
                                        
                                        Hi Eliot, hi all!<div><br></div><div>I fixed the issue with Tools-mt.989. The logic was already there in #runUntil.</div></div></div></blockquote><div><br></div><3 thank you, thank you, thank you!!<br><div><br></div><br><blockquote type="cite"><div dir="ltr"><div id="__MailbirdStyleContent" style="font-size: 10pt;font-family: Arial;color: #000000"><div>Best,</div><div>Marcel</div><div class="mb_sig"></div>
                                        
                                        <blockquote class="history_container" type="cite" style="border-left-style: solid;border-width: 1px;margin-top: 20px;margin-left: 0px;padding-left: 10px;min-width: 500px">
                        <p style="color: #AAAAAA; margin-top: 10px;">Am 19.09.2020 23:00:33 schrieb Levente Uzonyi <leves@caesar.elte.hu>:</p><div style="font-family:Arial,Helvetica,sans-serif">Hi Christoph,
<br>
<br>On Sat, 19 Sep 2020, Thiede, Christoph wrote:
<br>
<br>> 
<br>> Hi Eliot,
<br>> 
<br>> 
<br>> very nice finding once again! I #timeProfile'd the menu button action and as I expected, the most expensive operation is the shout styling by the new inspectors, including the decompilation of every method:
<br>
<br>What was it exactly that you profiled?
<br>
<br>The screenshot shows that 76.9% was spent in #initializeVariablesFromContext, 
<br>of which 52.5% of the time was spent in CompiledMethod(CompiledCode) >> 
<br>#getSource. The rest of the tree is not visible, but these methods have 
<br>nothing to do with parsing or styling, they initialize the parser and 
<br>normally should take <1 ms.
<br>
<br>Also, why is the decompiler producing the source code?
<br>
<br>> 
<br>> 
<br>> [IMAGE]
<br>> 
<br>> 
<br>> First, when loading ShoutCore-ct.78 (Inbox), the speed doubles (but probably that's rather a problem with my sources file, see the thread about this commit).
<br>
<br>You may want to try compiling a VM where FilePlugin's CreateFile does not 
<br>set the FILE_FLAG_SEQUENTIAL_SCAN flag, and see if it helps with file 
<br>reading performance.
<br>
<br>
<br>Levente
<br>
<br>> 
<br>> Second, we do not redraw the world while running to the selection, so we do not need to update the inspectors at all. I think we could split up #doStep into some #basicDoStep (which would perform the actual stepping logic) +
<br>> some #updateContextDuring: (which would update the stack list and the inspectors), then we would need to trigger the updates only once from #runToSelection:.
<br>> As an alternative, we could make this method a bit more complex but responsive by applying the same updating logic from #runUntil.
<br>> 
<br>> What do you think? :-)
<br>> 
<br>> Best,
<br>> Christoph
<br>> 
<br>> _________________________________________________________________________________________________________________________________________________________________________________________________________________________________
<br>> Von: Squeak-dev <squeak-dev-bounces@lists.squeakfoundation.org> im Auftrag von Eliot Miranda <eliot.miranda@gmail.com>
<br>> Gesendet: Samstag, 19. September 2020 20:17:12
<br>> An: The general-purpose Squeak developers list; Taeumel, Marcel
<br>> Betreff: [squeak-dev] Can we make computing the local variables in the debugger lazy?  
<br>> Hi Marcel,
<br>> 
<br>>     can we try and reduce the frequency at which we compute the variables in the context inspector in the debugger?  It is a noticeable performance hit.  I really like the user interface, but the performance hit is making
<br>> debugging difficult.
<br>> 
<br>> As an example use this:
<br>> 
<br>> | samples sineTable sound |
<br>> "1 second of A below middle C (220Hz). 16000 / 220 is 72.72 recurring"
<br>> sineTable := SoundPlayer sineTable: 73.
<br>> sineTable doWithIndex: "And let's not deafen anyone..."
<br>> [:sample :index| sineTable at: index put: sample // 4].
<br>> samples := SoundBuffer new: 16000.
<br>> 1 to: samples size by: sineTable size do:
<br>> [:i| samples replaceFrom: i to: (i + sineTable size - 1 min: 16000) with: sineTable startingAt: 1].
<br>> 1 to: 146 do:
<br>> [:i|
<br>> samples at: i put: ((samples at: i) * i / 146) asInteger.
<br>> samples at: 16001 - i put: ((samples at: 16001 - i) * i / 146) asInteger].
<br>> sound := SampledSound
<br>> samples: samples
<br>> samplingRate: 16000.
<br>> sound := MixedSound new
<br>> add: sound pan: 0.25;
<br>> add: sound pan: 0.75;
<br>> yourself.
<br>> sound computeSamplesForSeconds: sound duration
<br>> 
<br>> 
<br>> Open a workspace in e.g. a 64-bit image prior to Tools-mt.965 (I used an image containing Tools-mt.942).  Debug the above in the workspace.  Position the cursor at "sound computeSamplesForSeconds: sound duration" and do "run
<br>> to here".  It is essentially instantaneous.
<br>> 
<br>> Now do the same in a contemporary trunk image.  It takes almost 6 seconds.
<br>> 
<br>> I used to be able to click step as fast as I could and the system would keep up with me.  Now I find that if I click too fast I can accumulate excess clicks and when I stp clicking the system will continue stepping and go too
<br>> far.
<br>> 
<br>> I don't want to lose the feedback the new variables list gives us.  But I do find the performance hit tedious.  I wonder could we cache the list and only update it
<br>> - when Morphic updates, and
<br>> - when the context changes?
<br>> 
<br>> 
<br>> _,,,^..^,,,_
<br>> best, Eliot
<br>> 
<br>></eliot.miranda@gmail.com></squeak-dev-bounces@lists.squeakfoundation.org></div></blockquote></div><span></span><br></div></blockquote></body></html>