protected function aggregateMemory($processes)
    {
        $memory = array();

        foreach ($processes as $process) {
            if (isset($memory[$process->getName()])) {
                $memory[$process->getName()] += $process->getMemory();
            }
            else {
                $memory[$process->getName()] = $process->getMemory();
            }
        }

        return $memory;
    }