0 Replies Latest reply on Jun 15, 2010 10:33 PM by John Hawkinson

    performanceMetrics

    John Hawkinson Level 5

      Over in a recent thread about crashing, Marc asked:

      Yep, I also noticed the obscure Application.performanceMetric( ) and PerformanceMetricOptions features. It seems really promising but I can't figure out how to use that stuff... Does anybody ever use it?

       

      I'm not sure what you mean exactly by how to use...probably you mean "what's it good for" rather than "how do I access the data?"; but just in case, here's an example:

       

      for (i in PerformanceMetricOptions) {
          $.writeln(
          function(text,length) {
              return text + "                                                                                                               ".substr(0,length-text.length);
           }(i,40)       +"\t" + app.performanceMetric(PerformanceMetricOptions[i]));
       }
      

       

      which produces:

      CPU_TIME                                     4198.368408
      NUMBER_OF_THREADS                            47
      OVERALL_SYSTEM_CPU                           1098.367074
      OVERALL_USER_CPU                             3100.104189
      CORE_ALLOCATION_COUNT                        0
      CORE_MEMORY_SIZE                             0
      RESIDENT_MEMORY_SIZE                         1947762688
      VIRTUAL_MEMORY_SIZE                          -1161183232
      CURRENT_MEMORY_MARK                          0
      HANDLE_COUNT                                 0
      GDI_OBJECT_COUNT                             0
      HEAP_ALLOCATIONS                             0
      HEAP_ALLOCATIONS_PEAK                        0
      MEMORY_PURGE_COUNT                           0
      MEMORY_PURGE_TIME                            0
      BIB_ALLOCATIONS                              1545628914
      BIB_ALLOCATIONS_PEAK                         1545628914
      BIB_CACHE                                    4064013
      BIB_CACHE_PEAK                               4064013
      PDF_ALLOCACTIONS                             0
      PDF_ALLOCACTIONS_PEAK                        0
      IMAGE_CACHE_ALLOCATIONS                      0
      IMAGE_CACHE_ALLOCATIONS_PEAK                 0
      IMAGE_CACHE_FILE_BYTES_READ                  0
      IMAGE_CACHE_FILE_BYTES_WRITTEN               0
      IMAGE_CACHE_FILE_READ_TIME                   0
      IMAGE_CACHE_FILE_WRITE_TIME                  0
      VXFERALLOC                                   0
      VXFERALLOCPEAK                               32768
      VXFERBYTESREAD                               67373
      VXFERBYTESWRITTEN                            67373
      VXFERREADTIME                                0
      VXFERWRITETIME                               0
      VXFERFILEBYTESREAD                           0
      VXFERFILEBYTESWRITTEN                        0
      PROCESS_IO_BYTES_READ                        0
      PROCESS_IO_BYTES_WRITTEN                     0
      AGMXSHOWTIME                                 0
      DATABASE_FILE_BYTES_READ                     0
      DATABASE_FILE_BYTES_WRITTEN                  0
      DATABASE_FILE_READ_TIME                      0
      DATABASE_FILE_WRITE_TIME                     0
      DROP_SHADOW_MEMORY_READ_TIME                 0
      DROP_SHADOW_MEMORY_READ_BYTES                0
      DROP_SHADOW_MEMORY_WRITE_TIME                0
      DROP_SHADOW_MEMORY_WRITE_BYTES               0
      DROP_SHADOW_FILE_READ_TIME                   0
      DROP_SHADOW_FILE_READ_BYTES                  0
      DROP_SHADOW_FILE_WRITE_TIME                  0
      DROP_SHADOW_FILE_WRITE_BYTES                 0
      CHANGE_MANAGER_UPDATE_CALL_COUNT             563410
      CHANGE_MANAGER_UPDATE_CALL_TIME              0
      SNAPSHOT_COUNT                               74969
      GALLEY_COMPOSITION_TIME                      0
      LAYOUT_COMPOSITION_TIME                      0
      GALLEY_COMPOSITION_COUNT                     0
      LAYOUT_COMPOSITION_COUNT                     1123
      DRAW_MANAGER_DRAW_TIME                       0
      DRAW_MANAGER_NUMBER_OF_INTERRUPTS            6
      SNAPSHOT_READ_WRITE_TIME                     0
      NEW_SNAPSHOT_TIME                            0
      DATABASE_NEW_UID_COUNT                       19025
      DATABASE_INSTANTIATE_COUNT                   435938180
      INSTANCE_CACHE_PURGE_COUNT                   65236
      MINISAVE_COUNT                               259
      XMP_FILTER_TIME                              0
      SNAPSHOT_READ_WRITE_BYTE_COUNT               834768
      DATABASE_FILE_PAGE_READS                     0
      ATTACHABLE_EVENT_COUNT                       2455
      ATTACHED_SCRIPTS_COUNT                       14
      DISPATCH_EVENT_TIME                          180