_calculateFlags speed is about 10k edges per second.
It requires 150sec for the snapshot with 1.5m edges.
The root of problem is var node = list.shift();
It is not effective in term of memory and cpu.
In our case it can be replaced with pop().
Created attachment 122389 [details]
Comment on attachment 122389 [details]
Clearing flags on attachment: 122389
Committed r104916: <http://trac.webkit.org/changeset/104916>
All reviewed patches have been landed. Closing bug.