Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

96
Vistas
How to keep the default events when using `perf stat` with custom events

When the perf stat command is used, many default events are measured. For example, when I run perf stat ls, I obtain the following output:

Performance counter stats for 'ls':

              0,55 msec task-clock                #    0,598 CPUs utilized
                 0      context-switches          #    0,000 /sec
                 0      cpu-migrations            #    0,000 /sec
                99      page-faults               #  179,071 K/sec
         2 324 694      cycles                    #    4,205 GHz
         1 851 372      instructions              #    0,80  insn per cycle
           357 918      branches                  #  647,403 M/sec
            12 897      branch-misses             #    3,60% of all branches

       0,000923884 seconds time elapsed

       0,000993000 seconds user
       0,000000000 seconds sys

Now, let's suppose I also want to measure the cache-references and cache-misses events. If I run perf stat -e cache-references,cache-misses, the output is:

 Performance counter stats for 'ls':

           101 148      cache-references
            34 261      cache-misses              #   33,872 % of all cache refs

       0,000973384 seconds time elapsed

       0,001014000 seconds user
       0,000000000 seconds sys

Is there a way to add events with the -e flag, but also keep the default events shown when not using -e (without having to list all of them explicitly in the command) ?

over 4 years ago · Santiago Trujillo
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda