memory-infra: compute shared memory footprint per process

This change adds a method to compute the shared memory footprint for each process.
This works by finding all the global nodes which are owned by shared memory nodes
in the graph and then attempting to figure out which ones should be apportioned
some of the size of the global node.

The code to decide sizes works by first considering the priority of each edge in
the graph which points to the global dump and only selecting the ones with the
highest importance. The size is then split between all the shared memory nodes
with the same importance and thus the process associated with each of these nodes
is incremented by the appropriate size

Bug: 781782
Change-Id: I9fce23cc2947658a8831244a46ffa7ca5bcb783d
Reviewed-on: https://chromium-review.googlesource.com/738050
Commit-Queue: Lalit Maganti <lalitm@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Reviewed-by: Primiano Tucci <primiano@chromium.org>
Cr-Commit-Position: refs/heads/master@{#514477}
8 files changed