stepping overhead

Ross Boylan RossBoylan at stanfordalumni.org
Tue Aug 21 23:26:41 UTC 2001


I have an application with lots of UpdatingStringMorph's, which chew up
a lot of CPU via the step statement.  I would like advice about
overall strategy for dealing with this, as well as some of the
implementation details.

The overall strategy question is whether to use stepping or the more
traditional update/changed architecture.  I gather from some of the
docs that stepping and "liveness" is the new paradigm, so I'm a little
reluctant to move away from it.  On the other hand, using them in this
way may be abusing them.  Certainly most of the steps are doing
nothing, as they sit on things that don't change (there are some
exceptions, including counters that change as the clock ticks).

The detail I wonder about is the overhead of the stepping. By raising
the stepTimes (e.g., to 4000) I can reduce the CPU useage a lot.  But
there is still a noticeable level of activity.  According to the spy,
this is mostly spent in the stepping machinery.  It looks as if having
many items being managed by the stepper is expensive, even if they
usually don't step.  Is this guess accurate?  Is there a way to reduce
the expense other than reducing the number of objects subject to
stepping?

Thanks.




More information about the Squeak-dev mailing list