Skip to content

Commit

Permalink
Smallest senders chain
Browse files Browse the repository at this point in the history
  • Loading branch information
jordanmontt committed Dec 17, 2024
1 parent 17bd4e0 commit 9f0c3ba
Showing 1 changed file with 5 additions and 12 deletions.
17 changes: 5 additions & 12 deletions src/IllimaniProfiler/IllEphemeron.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -174,21 +174,14 @@ IllEphemeron >> sendersCallStack [
{ #category : 'accessing' }
IllEphemeron >> sendersCallStack: aContext [

| sender i n |
n := 200.
senders := Array new: n.
i := 1.
| sender |
senders := Array new: 10.
sender := aContext.
[ sender isNil or: [ i > n ] ] whileFalse: [
senders at: i put: sender method.
senders at: i + 1 put: sender pc - 1.
sender := sender sender.
i := i + 2 ]
"1 to: 10 by: 2 do: [ :i |
1 to: 10 by: 2 do: [ :i |
sender ifNil: [ ^ self ].
senders at: i put: sender method.
senders at: i + 1 put: (sender pc - 1).
sender := sender sender ]"
senders at: i + 1 put: sender pc - 1.
sender := sender sender ]
]

{ #category : 'accessing' }
Expand Down

0 comments on commit 9f0c3ba

Please sign in to comment.