squeak-smalltalk / squeak-object-memory

Issues and assets related to the Squeak object memory.
https://bugs.squeak.org
MIT License
11 stars 1 forks source link

The Squeak window turns black #71

Open no-e-in opened 1 year ago

no-e-in commented 1 year ago

On Win7-64 (if it is still taken into account), Current Release Squeak 6.0 (32 or 64, cog-spur or strack-spur). After a few minutes of use, the Squeak window turns black and win7 slows down. With squeak.stack.spur_win32x86_debug, the SqueakDebug.log:

ZeroDivide: 
6 October 2022 10:08:03.274924 pm

VM: Win32 - Smalltalk
Image: Squeak6.0 [latest update: #22104]

SecurityManager state:
Restricted: false
FileAccess: true
SocketAccess: true
Working Dir E:\test\Squeak6.0-22104-32bit-202206021410-Windows-x86
Trusted Dir E:\test\Squeak6.0-22104-32bit-202206021410-Windows-x86\luigi
Untrusted Dir C:\Users\luigi\Documents\My Squeak

BoxedFloat64>>/
    Receiver: 1.0
    Arguments and temporary variables: 
        aNumber:    0.0
    Receiver's instance variables: 
1.0
DisplayScreen>>platformScaleFactor:
    Receiver: DisplayScreen(731x535x32)
    Arguments and temporary variables: 
        aFloatOrNil:    1.0
        old:    0.0
        new:    1.0
    Receiver's instance variables: 
        bits:   a Bitmap of length 391085
        width:  731
        height:     535
        depth:  32
        offset:     0@0
        clippingBox:    0@0 corner: 731@535
        extraRegions:   nil

DisplayScreen class>>checkForNewScreenScaleFactor
    Receiver: DisplayScreen
    Arguments and temporary variables: 

    Receiver's instance variables: 
        superclass:     Form
        methodDict:     a MethodDictionary(#actualDisplay->(DisplayScreen>>#actualDisplay "...etc...
        format:     65543
        instanceVariables:  #('clippingBox' 'extraRegions')
        organization:   ('blitter defaults' defaultBitBltClass defaultWarpBltClass)
('dis...etc...
        subclasses:     {DisplayHostWindow . OLPCVirtualScreen}
        name:   #DisplayScreen
        classPool:  a Dictionary(#DeferringUpdates->false #DisplayChangeSignature->58244...etc...
        sharedPools:    nil
        environment:    Smalltalk
        category:   #'Graphics-Display Objects'

WorldState>>doOneCycleNowFor:
    Receiver: a WorldState
    Arguments and temporary variables: 
        aWorld:     a PasteUpMorph(2434915) [world]
        capturingGesture:   nil
    Receiver's instance variables: 
        hands:  {a HandMorph(3765585)}
        viewBox:    0@0 corner: 731@535
        canvas:     a FormCanvas on: DisplayScreen(731x535x32)
        damageRecorder:     a DamageRecorder
        stepList:   a Heap(StepMessage(#stepAt: -> a DockingBarUpdatingItemMorph(337190)'...etc...
        lastStepTime:   3842539683248
        lastStepMessage:    nil
        lastCycleTime:  3842539683263
        commandHistory:     nil
        alarms:     a MorphicAlarmQueue
        lastAlarmTime:  3842539683248
        remoteServer:   nil
        multiCanvas:    nil
        interCycleDelay:    a Delay(13 msecs)

WorldState>>doOneCycleFor:
    Receiver: a WorldState
    Arguments and temporary variables: 
        aWorld:     a PasteUpMorph(2434915) [world]
    Receiver's instance variables: 
        hands:  {a HandMorph(3765585)}
        viewBox:    0@0 corner: 731@535
        canvas:     a FormCanvas on: DisplayScreen(731x535x32)
        damageRecorder:     a DamageRecorder
        stepList:   a Heap(StepMessage(#stepAt: -> a DockingBarUpdatingItemMorph(337190)'...etc...
        lastStepTime:   3842539683248
        lastStepMessage:    nil
        lastCycleTime:  3842539683263
        commandHistory:     nil
        alarms:     a MorphicAlarmQueue
        lastAlarmTime:  3842539683248
        remoteServer:   nil
        multiCanvas:    nil
        interCycleDelay:    a Delay(13 msecs)

PasteUpMorph>>doOneCycle
    Receiver: a PasteUpMorph(2434915) [world]
    Arguments and temporary variables: 

    Receiver's instance variables: 
        bounds:     0@0 corner: 731@535
        owner:  nil
        submorphs:  {a DockingBarMorph(2192019) . a PluggableSystemWindow<Welcome to Squ...etc...
        fullBounds:     0@0 corner: 731@535
        color:  (Color r: 0.0 g: 0.194 b: 0.258)
        extension:  a MorphExtension (3078998) [eventHandler = an EventHandler]  [other:...etc...
        borderWidth:    0
        borderColor:    (Color r: 0.515 g: 0.181 b: 0.263)
        presenter:  an EtoysPresenter (3596190)
        model:  a MorphicModel(1247841)
        cursor:     1
        padding:    3
        turtleTrailsForm:   nil
        turtlePen:  nil
        lastTurtlePositions:    nil
        isPartsBin:     nil
        indicateCursor:     nil
        wantsMouseOverHalos:    nil
        worldState:     a WorldState

[] in MorphicProject>>spawnNewProcess
    Receiver: a MorphicProject (HomeProject) in a PasteUpMorph(2434915) [world]
    Arguments and temporary variables: 

    Receiver's instance variables: 
        dependents:     nil
        world:  a PasteUpMorph(2434915) [world]
        uiManager:  a MorphicUIManager
        changeSet:  a ChangeSet named HomeProject
        transcript:     a TranscriptStream
        parentProject:  a MVCProject (RootProject) in a ControlManager
        previousProject:    nil
        displayDepth:   32
        viewSize:   151@132
        thumbnail:  Form(151x132x32)
        nextProject:    nil
        projectParameters:  an IdentityDictionary(#PrevailingProjectFlags->an IdentityDictionary...etc...
        version:    nil
        urlList:    nil
        lastDirectory:  nil
        lastSavedAtSeconds:     nil
        projectPreferenceFlagDictionary:    an IdentityDictionary(#enablePortraitMode->fal...etc...
        resourceManager:    a ResourceManager
        uiProcess:  a Process(59975) in nil

[] in FullBlockClosure(BlockClosure)>>newProcess
    Receiver: [closure] in MorphicProject>>spawnNewProcess
    Arguments and temporary variables: 

    Receiver's instance variables: 
        outerContext:   MorphicProject>>spawnNewProcess
        startpcOrMethod:    ([] in MorphicProject>>#spawnNewProcess "a CompiledBlock(32849...etc...
        numArgs:    0
        receiver:   a MorphicProject (HomeProject) in a PasteUpMorph(2434915) [world]

--- The full stack ---
BoxedFloat64>>/
DisplayScreen>>platformScaleFactor:
DisplayScreen class>>checkForNewScreenScaleFactor
WorldState>>doOneCycleNowFor:
WorldState>>doOneCycleFor:
PasteUpMorph>>doOneCycle
[] in MorphicProject>>spawnNewProcess
[] in FullBlockClosure(BlockClosure)>>newProcess
LinqLover commented 1 year ago

Looks as if DisplayScreen actualScreenScaleFactor would answer 0 for you. What VM version are you using (see the screenshot for an example)?

image

no-e-in commented 1 year ago

The problem occurs with all the latest versions of Squeak 6.0. The first version that I tried (and the problem occurred after a few minutes) is:

E:\test\Squeak6.0-22104-64bit-202206021410-Windows-x64\Squeak.exe
Open Smalltalk Cog[Spur] VM [CoInterpreterPrimitives VMMaker.oscog-dtl.3185]
Win32 built on Jun  2 2022 15:29:44 Compiler: Clang 14.0.3
platform sources revision VM: 202206021410