[Vm-dev] VM Maker: VMMaker.oscog-eem.1858.mcz
commits at source.squeak.org
commits at source.squeak.org
Wed May 11 18:31:18 UTC 2016
Eliot Miranda uploaded a new version of VMMaker to project VM Maker:
http://source.squeak.org/VMMaker/VMMaker.oscog-eem.1858.mcz
==================== Summary ====================
Name: VMMaker.oscog-eem.1858
Author: eem
Time: 11 May 2016, 11:29:11.609577 am
UUID: 4b71a017-2e37-4c2f-bab6-9010e95cb2ea
Ancestors: VMMaker.oscog-tpr.1857
Fix slip in closedPICRefersToUnmarkedObject:
=============== Diff against VMMaker.oscog-tpr.1857 ===============
Item was changed:
----- Method: Cogit>>closedPICRefersToUnmarkedObject: (in category 'garbage collection') -----
closedPICRefersToUnmarkedObject: cPIC
"Answer if the ClosedPIC refers to any unmarked objects or freed/freeable target methods,
applying markAndTraceOrFreeCogMethod:firstVisit: to those targets to determine if freed/freeable."
<var: #cPIC type: #'CogMethod *'>
| pc object |
((objectMemory isImmediate: cPIC selector)
or: [objectMemory isMarked: cPIC selector]) ifFalse:
[^true].
"First jump is unconditional; subsequent ones are conditional."
"Check the potential method oop for the first case only.
Inline cache tags for the 1st case are at the send site."
pc := self addressOfEndOfCase: 1 inCPIC: cPIC.
(objectRepresentation couldBeObject: (object := backEnd literalBeforeFollowingAddress: pc - backEnd jumpLongByteSize)) ifTrue:
[(objectMemory isMarked: object) ifFalse:
[^true]].
"Check the first target"
(self markAndTraceOrFreePICTarget: (backEnd jumpLongTargetBeforeFollowingAddress: pc) in: cPIC) ifTrue:
[^true].
2 to: cPIC cPICNumCases do:
[:i|
pc := self addressOfEndOfCase: i inCPIC: cPIC.
(self inlineCacheTagsAreIndexes not
and: [objectRepresentation inlineCacheTagsMayBeObjects
+ and: [objectRepresentation couldBeObject: (object := backEnd literal32BeforeFollowingAddress: pc - backEnd jumpLongConditionalByteSize)]]) ifTrue:
- and: [objectRepresentation couldBeObject: (object := literalsManager backEnd literal32BeforeFollowingAddress: pc - backEnd jumpLongConditionalByteSize)]]) ifTrue:
[(objectMemory isMarked: object) ifFalse:
[^true]].
"Check the potential method oop for subsequent cases."
(objectRepresentation couldBeObject: (object := backEnd literalBeforeFollowingAddress: pc - backEnd jumpLongConditionalByteSize - backEnd cmpC32RTempByteSize)) ifTrue:
[(objectMemory isMarked: object) ifFalse:
[^true]].
"Check subsequent targets"
(self markAndTraceOrFreePICTarget: (backEnd jumpLongConditionalTargetBeforeFollowingAddress: pc) in: cPIC) ifTrue:
[^true]].
^false!
More information about the Vm-dev
mailing list