Skip to content

Commit

Permalink
Removing conditional saving of the perm space
Browse files Browse the repository at this point in the history
  • Loading branch information
tesonep committed Jun 27, 2022
1 parent aaa96ca commit 6f9edd2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 23 deletions.
4 changes: 0 additions & 4 deletions smalltalksrc/VMMaker/ComposedImageWriter.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,6 @@ ComposedImageWriter >> writeImageFile: imageFileName fromHeader: header [
{ #category : #'perm - space' }
ComposedImageWriter >> writeImagePermanentSpace: imageFileName [

objectMemory isPermSpaceDirty ifFalse: [ ^ objectMemory totalBytesInPermanentSpace ].

objectMemory setPermSpaceDirty: false.

self writePermanentSpaceMetadata: imageFileName.

^ self writePermanentSpaceData: imageFileName
Expand Down
21 changes: 2 additions & 19 deletions smalltalksrc/VMMaker/SpurMemoryManager.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -618,7 +618,6 @@ Class {
'statMaxAllocSegmentTime',
'unscannedEphemeronsQueueInitialSize',
'permSpaceFreeStart',
'permSpaceDirty',
'fromOldSpaceRememberedSet',
'fromPermSpaceRememberedSet'
],
Expand Down Expand Up @@ -2509,7 +2508,6 @@ SpurMemoryManager >> allocateSlotsInPermSpace: numSlots bytes: totalBytes format
memoryMap extendPermObjectsSpace
ifFalse: [ ^ nil ] ].
permSpaceDirty := true.
chunk := permSpaceFreeStart.
permSpaceFreeStart := permSpaceFreeStart + totalBytes.
Expand Down Expand Up @@ -6362,7 +6360,7 @@ SpurMemoryManager >> initialize [
remapBufferCount := extraRootCount := 0. "see below"
freeListsMask := totalFreeOldSpace := lowSpaceThreshold := 0.
checkForLeaks := 0.
permSpaceDirty := needGCFlag := signalLowSpace := marking := false.
needGCFlag := signalLowSpace := marking := false.
becomeEffectsFlags := gcPhaseInProgress := 0.
statScavenges := statIncrGCs := statFullGCs := 0.
statMaxAllocSegmentTime := 0.
Expand Down Expand Up @@ -6390,8 +6388,7 @@ SpurMemoryManager >> initialize [
maxOldSpaceSize := self class initializationOptions
ifNotNil: [:initOpts| initOpts at: #maxOldSpaceSize ifAbsent: [0]]
ifNil: [0].
permSpaceDirty := false
]
{ #category : #bootstrap }
Expand Down Expand Up @@ -6571,8 +6568,6 @@ SpurMemoryManager >> initializeObjectMemory: bytesToShift [
shrinkThreshold := 32*1024*1024. "free space before shrinking"
self setHeapSizeAtPreviousGC.
heapGrowthToSizeGCRatio := 0.333333. "By default GC after scavenge if heap has grown by a third since the last GC"
permSpaceDirty := false.
]
{ #category : #'free space' }
Expand Down Expand Up @@ -7452,12 +7447,6 @@ SpurMemoryManager >> isOopMutable: oop [
and: [(self isImmutable: oop) not]
]
{ #category : #'perm - space' }
SpurMemoryManager >> isPermSpaceDirty [
^ permSpaceDirty
]
{ #category : #'object testing' }
SpurMemoryManager >> isPermanent: oop [
Expand Down Expand Up @@ -11312,12 +11301,6 @@ SpurMemoryManager >> setObjectFree: objOop [
self setFree: objOop
]
{ #category : #'perm - space' }
SpurMemoryManager >> setPermSpaceDirty: aValue [
permSpaceDirty := aValue
]
{ #category : #accessing }
SpurMemoryManager >> setPermSpaceFreeStart: aValue [
Expand Down

0 comments on commit 6f9edd2

Please sign in to comment.