diff -r 4816d766a08a -r f345bda72bc4 Symbian3/PDK/Source/GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0.dita --- a/Symbian3/PDK/Source/GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0.dita Tue Mar 30 11:42:04 2010 +0100 +++ b/Symbian3/PDK/Source/GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0.dita Tue Mar 30 11:56:28 2010 +0100 @@ -1,90 +1,90 @@ - - - - - -Performance -LoggingSymbian platform provides macros that you can use in device driver -and kernel extension programs to write a trace log. -

You can use the trace log to test the performance of the programs.

-
Perfomance macros

There are three macros that you -can insert into your code. They only differ with respect to the optional data -that you can add to the trace record. All are defined in kernperfloger.h

    -
  • PERF_LOG0 (aSubCategory)

  • -
  • PERF_LOG1 (aSubCategory,aUserData)

  • -
  • PERF_LOG2 (aSubCategory,aUserData,aUserData2)

    Note: -the PERF_LOG macro is identical to PERF_LOG2.

  • -

You must specify an the 8-bit integer subcategory value in the aSubCategory argument. -You can also supply one or two (or zero) 32-bit values; you are free to decide -on the meaning of such values.

The macros wrap around the standard BTrace*** macros. -All trace records generated by these macros are given a category of BTrace::EKernPerfLog.

The -generation and capture of trace information is implemented as a kernel extension. -This means that it is loaded and activated at an early stage in the startup -process of the device.

-
Performance macro output format

The following table -shows which fields of a trace record are generated by each of the macros PERF_LOG0, PERF_LOG1, -and PERF_LOG2:

- - - -

Field

-

PERF_LOG0

-

PERF_LOG1

-

PERF_LOG2

-
- -

Fast Counter Timestamp

-

Yes

-

Yes

-

Yes

-
- -

Context Id

-

Yes

-

Yes

-

Yes

-
- -

PC value

-

Yes

-

Yes

-

Yes

-
- -

the 32-bit integer value passed as aUserData

-

NO

-

Yes

-

Yes

-
- -

the 32-bit integer value passed as aUserData2

-

NO

-

NO

-

Yes

-
- -

Tick Count as returned from a call to NKern::TickCount()

-

Yes

-

Yes

-

Yes

-
- - -
-
How to use the macros

To use the macros:

    -
  • Include the header file kernperfloger.h in -your source code.

  • -
  • Link to btrace.lib in -your project

  • -
  • Call the PERF_LOG*** macros -at appropriate points in your code.

    For examples, see the test code -for the macros in ...\e32test\group\d_perflogger_test_ldd.mmp and ...\e32test\group\t_perflogger.mmp

  • -
  • Rebuild your project

  • -
+ + + + + +Performance +LoggingSymbian platform provides macros that you can use in device driver +and kernel extension programs to write a trace log. +

You can use the trace log to test the performance of the programs.

+
Perfomance macros

There are three macros that you +can insert into your code. They only differ with respect to the optional data +that you can add to the trace record. All are defined in kernperfloger.h

    +
  • PERF_LOG0 (aSubCategory)

  • +
  • PERF_LOG1 (aSubCategory,aUserData)

  • +
  • PERF_LOG2 (aSubCategory,aUserData,aUserData2)

    Note: +the PERF_LOG macro is identical to PERF_LOG2.

  • +

You must specify an the 8-bit integer subcategory value in the aSubCategory argument. +You can also supply one or two (or zero) 32-bit values; you are free to decide +on the meaning of such values.

The macros wrap around the standard BTrace*** macros. +All trace records generated by these macros are given a category of BTrace::EKernPerfLog.

The +generation and capture of trace information is implemented as a kernel extension. +This means that it is loaded and activated at an early stage in the startup +process of the device.

+
Performance macro output format

The following table +shows which fields of a trace record are generated by each of the macros PERF_LOG0, PERF_LOG1, +and PERF_LOG2:

+ + + +

Field

+

PERF_LOG0

+

PERF_LOG1

+

PERF_LOG2

+
+ +

Fast Counter Timestamp

+

Yes

+

Yes

+

Yes

+
+ +

Context Id

+

Yes

+

Yes

+

Yes

+
+ +

PC value

+

Yes

+

Yes

+

Yes

+
+ +

the 32-bit integer value passed as aUserData

+

NO

+

Yes

+

Yes

+
+ +

the 32-bit integer value passed as aUserData2

+

NO

+

NO

+

Yes

+
+ +

Tick Count as returned from a call to NKern::TickCount()

+

Yes

+

Yes

+

Yes

+
+ + +
+
How to use the macros

To use the macros:

    +
  • Include the header file kernperfloger.h in +your source code.

  • +
  • Link to btrace.lib in +your project

  • +
  • Call the PERF_LOG*** macros +at appropriate points in your code.

    For examples, see the test code +for the macros in ...\e32test\group\d_perflogger_test_ldd.mmp and ...\e32test\group\t_perflogger.mmp

  • +
  • Rebuild your project

  • +
\ No newline at end of file