A small optimization in node computation
authorIustin Pop <iustin@google.com>
Sun, 15 Feb 2009 13:40:42 +0000 (14:40 +0100)
committerIustin Pop <iustin@google.com>
Sun, 15 Feb 2009 13:40:42 +0000 (14:40 +0100)
commit256810de286c67c4ae68acbdb009ec94d4ca7776
tree59a5f8e289eb6e3645800a948ce876a2bc80e18e
parent1fd47ca2535088a05593add56a42b03fa991af96
A small optimization in node computation

Currently we always compute the available node list for moves (for an
instances) based on the nodes of the initial table. This works find,
however is a repeated calculation.

We optimize this by passing a node list (of indexes, not full objects),
which helps in two ways:
  - faster to filter later
  - allows restriction of target nodes by enforcing only this subset as
    target for moves
src/Cluster.hs
src/hbal.hs