Ejemplo n.º 1
0
def main():
  """Displays topdown hierarchy for localhost"""
  parser = argparse.ArgumentParser(description='Top down micro architecture analysis')
  parser.add_argument('--node', type=str, help='list pmu events for node - enter "all" to list events for all nodes')
  args = parser.parse_args()
  topdownCache = TopdownCache(EventsDbCache())
  from xpedite.util import getCpuId
  topdownHandle = topdownCache.get(getCpuId())

  if args.node:
    LOGGER.info('%s', topdownHandle.nodesToString(args.node))
    return

  LOGGER.info('%s', topdownHandle.hierarchy)
Ejemplo n.º 2
0
 def getCpuId(self):
     """Discovers and caches cpu model"""
     if not self.cpuId:
         from xpedite.util import getCpuId
         self.cpuId = getCpuId()
     return self.cpuId
Ejemplo n.º 3
0
def main():
    """Displays pmu events database for localhost"""
    from xpedite.util import getCpuId
    eventsDb = loadEventsDb(getCpuId())
    LOGGER.info('\n%s', eventsDb)