| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 479 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 490 TRACE_EVENT_SET_SAMPLING_STATE_FOR_BUCKET(0, category, name) | 490 TRACE_EVENT_SET_SAMPLING_STATE_FOR_BUCKET(0, category, name) |
| 491 #define TRACE_EVENT_SET_NONCONST_SAMPLING_STATE(categoryAndName) \ | 491 #define TRACE_EVENT_SET_NONCONST_SAMPLING_STATE(categoryAndName) \ |
| 492 TRACE_EVENT_SET_NONCONST_SAMPLING_STATE_FOR_BUCKET(0, categoryAndName) | 492 TRACE_EVENT_SET_NONCONST_SAMPLING_STATE_FOR_BUCKET(0, categoryAndName) |
| 493 | 493 |
| 494 // Macros to track the life time and value of arbitrary client objects. | 494 // Macros to track the life time and value of arbitrary client objects. |
| 495 // See also TraceTrackableObject. | 495 // See also TraceTrackableObject. |
| 496 #define TRACE_EVENT_OBJECT_CREATED_WITH_ID(categoryGroup, name, id) \ | 496 #define TRACE_EVENT_OBJECT_CREATED_WITH_ID(categoryGroup, name, id) \ |
| 497 INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_CREATE_OBJECT, \ | 497 INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_CREATE_OBJECT, \ |
| 498 categoryGroup, name, TRACE_ID_DONT_MANGLE(id), TRACE_EVENT_FLAG_NONE) | 498 categoryGroup, name, TRACE_ID_DONT_MANGLE(id), TRACE_EVENT_FLAG_NONE) |
| 499 | 499 |
| 500 #define TRACE_EVENT_OBJECT_SNAPSHOT_WITH_ID(categoryGroup, name, id, snapshot) \ |
| 501 INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_SNAPSHOT_OBJECT, \ |
| 502 categoryGroup, name, TRACE_ID_DONT_MANGLE(id), TRACE_EVENT_FLAG_NONE, \ |
| 503 "snapshot", snapshot) |
| 504 |
| 500 #define TRACE_EVENT_OBJECT_DELETED_WITH_ID(categoryGroup, name, id) \ | 505 #define TRACE_EVENT_OBJECT_DELETED_WITH_ID(categoryGroup, name, id) \ |
| 501 INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_DELETE_OBJECT, \ | 506 INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_DELETE_OBJECT, \ |
| 502 categoryGroup, name, TRACE_ID_DONT_MANGLE(id), TRACE_EVENT_FLAG_NONE) | 507 categoryGroup, name, TRACE_ID_DONT_MANGLE(id), TRACE_EVENT_FLAG_NONE) |
| 503 | 508 |
| 504 // Macro to efficiently determine if a given category group is enabled. | 509 // Macro to efficiently determine if a given category group is enabled. |
| 505 #define TRACE_EVENT_CATEGORY_GROUP_ENABLED(categoryGroup, ret) \ | 510 #define TRACE_EVENT_CATEGORY_GROUP_ENABLED(categoryGroup, ret) \ |
| 506 do { \ | 511 do { \ |
| 507 INTERNAL_TRACE_EVENT_GET_CATEGORY_INFO(categoryGroup); \ | 512 INTERNAL_TRACE_EVENT_GET_CATEGORY_INFO(categoryGroup); \ |
| 508 if (INTERNAL_TRACE_EVENT_CATEGORY_GROUP_ENABLED_FOR_RECORDING_MODE()) {
\ | 513 if (INTERNAL_TRACE_EVENT_CATEGORY_GROUP_ENABLED_FOR_RECORDING_MODE()) {
\ |
| 509 *ret = true; \ | 514 *ret = true; \ |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 636 #define TRACE_EVENT_PHASE_INSTANT ('I') | 641 #define TRACE_EVENT_PHASE_INSTANT ('I') |
| 637 #define TRACE_EVENT_PHASE_INSTANT_WITH_SCOPE ('i') | 642 #define TRACE_EVENT_PHASE_INSTANT_WITH_SCOPE ('i') |
| 638 #define TRACE_EVENT_PHASE_ASYNC_BEGIN ('S') | 643 #define TRACE_EVENT_PHASE_ASYNC_BEGIN ('S') |
| 639 #define TRACE_EVENT_PHASE_ASYNC_STEP_INTO ('T') | 644 #define TRACE_EVENT_PHASE_ASYNC_STEP_INTO ('T') |
| 640 #define TRACE_EVENT_PHASE_ASYNC_STEP_PAST ('p') | 645 #define TRACE_EVENT_PHASE_ASYNC_STEP_PAST ('p') |
| 641 #define TRACE_EVENT_PHASE_ASYNC_END ('F') | 646 #define TRACE_EVENT_PHASE_ASYNC_END ('F') |
| 642 #define TRACE_EVENT_PHASE_METADATA ('M') | 647 #define TRACE_EVENT_PHASE_METADATA ('M') |
| 643 #define TRACE_EVENT_PHASE_COUNTER ('C') | 648 #define TRACE_EVENT_PHASE_COUNTER ('C') |
| 644 #define TRACE_EVENT_PHASE_SAMPLE ('P') | 649 #define TRACE_EVENT_PHASE_SAMPLE ('P') |
| 645 #define TRACE_EVENT_PHASE_CREATE_OBJECT ('N') | 650 #define TRACE_EVENT_PHASE_CREATE_OBJECT ('N') |
| 651 #define TRACE_EVENT_PHASE_SNAPSHOT_OBJECT ('O') |
| 646 #define TRACE_EVENT_PHASE_DELETE_OBJECT ('D') | 652 #define TRACE_EVENT_PHASE_DELETE_OBJECT ('D') |
| 647 | 653 |
| 648 // Flags for changing the behavior of TRACE_EVENT_API_ADD_TRACE_EVENT. | 654 // Flags for changing the behavior of TRACE_EVENT_API_ADD_TRACE_EVENT. |
| 649 #define TRACE_EVENT_FLAG_NONE (static_cast<unsigned char>(0)) | 655 #define TRACE_EVENT_FLAG_NONE (static_cast<unsigned char>(0)) |
| 650 #define TRACE_EVENT_FLAG_COPY (static_cast<unsigned char>(1 << 0)) | 656 #define TRACE_EVENT_FLAG_COPY (static_cast<unsigned char>(1 << 0)) |
| 651 #define TRACE_EVENT_FLAG_HAS_ID (static_cast<unsigned char>(1 << 1)) | 657 #define TRACE_EVENT_FLAG_HAS_ID (static_cast<unsigned char>(1 << 1)) |
| 652 #define TRACE_EVENT_FLAG_MANGLE_ID (static_cast<unsigned char>(1 << 2)) | 658 #define TRACE_EVENT_FLAG_MANGLE_ID (static_cast<unsigned char>(1 << 2)) |
| 653 | 659 |
| 654 // Type values for identifying types in the TraceValue union. | 660 // Type values for identifying types in the TraceValue union. |
| 655 #define TRACE_VALUE_TYPE_BOOL (static_cast<unsigned char>(1)) | 661 #define TRACE_VALUE_TYPE_BOOL (static_cast<unsigned char>(1)) |
| (...skipping 345 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1001 const char* m_categoryGroup; | 1007 const char* m_categoryGroup; |
| 1002 const char* m_name; | 1008 const char* m_name; |
| 1003 IDType m_id; | 1009 IDType m_id; |
| 1004 }; | 1010 }; |
| 1005 | 1011 |
| 1006 } // namespace TraceEvent | 1012 } // namespace TraceEvent |
| 1007 | 1013 |
| 1008 } // namespace WebCore | 1014 } // namespace WebCore |
| 1009 | 1015 |
| 1010 #endif | 1016 #endif |
| OLD | NEW |