diff options
| author | Jonathan Herman <hermanjl@cs.unc.edu> | 2012-09-29 13:04:40 -0400 |
|---|---|---|
| committer | Jonathan Herman <hermanjl@cs.unc.edu> | 2012-09-29 13:04:40 -0400 |
| commit | daf1e620bff2cb6d830ef66725369bba9c858f62 (patch) | |
| tree | 1aed8f7cb55371c70d2139b6754d90ea89a26147 /include/litmus/trace.h | |
| parent | 451ed3b075c2a8e322e5a44f177e2470426a821d (diff) | |
| parent | 1cb90226816c7af7808be4c0de866c54da17ecc9 (diff) | |
Merge branch 'wip-color' into wip-mc
Conflicts:
include/litmus/budget.h
include/litmus/litmus.h
include/litmus/rt_param.h
include/litmus/sched_trace.h
include/litmus/trace.h
include/trace/events/litmus.h
litmus/Makefile
litmus/budget.c
litmus/ftdev.c
litmus/jobs.c
litmus/litmus.c
litmus/locking.c
litmus/preempt.c
litmus/rt_domain.c
litmus/sched_gsn_edf.c
litmus/trace.c
Diffstat (limited to 'include/litmus/trace.h')
| -rw-r--r-- | include/litmus/trace.h | 37 |
1 files changed, 11 insertions, 26 deletions
diff --git a/include/litmus/trace.h b/include/litmus/trace.h index c1bbf168e6d4..d868144f6928 100644 --- a/include/litmus/trace.h +++ b/include/litmus/trace.h | |||
| @@ -23,7 +23,9 @@ struct timestamp { | |||
| 23 | uint32_t seq_no; | 23 | uint32_t seq_no; |
| 24 | uint8_t cpu; | 24 | uint8_t cpu; |
| 25 | uint8_t event; | 25 | uint8_t event; |
| 26 | uint8_t task_type; | 26 | uint8_t task_type:2; |
| 27 | uint8_t irq_flag:1; | ||
| 28 | uint8_t irq_count:5; | ||
| 27 | }; | 29 | }; |
| 28 | 30 | ||
| 29 | /* tracing callbacks */ | 31 | /* tracing callbacks */ |
| @@ -32,7 +34,6 @@ feather_callback void save_timestamp_def(unsigned long event, unsigned long type | |||
| 32 | feather_callback void save_timestamp_task(unsigned long event, unsigned long t_ptr); | 34 | feather_callback void save_timestamp_task(unsigned long event, unsigned long t_ptr); |
| 33 | feather_callback void save_timestamp_cpu(unsigned long event, unsigned long cpu); | 35 | feather_callback void save_timestamp_cpu(unsigned long event, unsigned long cpu); |
| 34 | feather_callback void save_task_latency(unsigned long event, unsigned long when_ptr); | 36 | feather_callback void save_task_latency(unsigned long event, unsigned long when_ptr); |
| 35 | feather_callback void save_timestamp_time(unsigned long event, unsigned long time_ptr); | ||
| 36 | 37 | ||
| 37 | #define TIMESTAMP(id) ft_event0(id, save_timestamp) | 38 | #define TIMESTAMP(id) ft_event0(id, save_timestamp) |
| 38 | 39 | ||
| @@ -47,11 +48,6 @@ feather_callback void save_timestamp_time(unsigned long event, unsigned long tim | |||
| 47 | #define LTIMESTAMP(id, task) \ | 48 | #define LTIMESTAMP(id, task) \ |
| 48 | ft_event1(id, save_task_latency, (unsigned long) task) | 49 | ft_event1(id, save_task_latency, (unsigned long) task) |
| 49 | 50 | ||
| 50 | #define TIMESTAMP_TIME(id, time_ptr) \ | ||
| 51 | ft_event1(id, save_timestamp_time, (unsigned long) time_ptr) | ||
| 52 | |||
| 53 | #define TIMESTAMP_PID(id) ft_event0(id, save_timestamp_pid) | ||
| 54 | |||
| 55 | #else /* !CONFIG_SCHED_OVERHEAD_TRACE */ | 51 | #else /* !CONFIG_SCHED_OVERHEAD_TRACE */ |
| 56 | 52 | ||
| 57 | #define TIMESTAMP(id) /* no tracing */ | 53 | #define TIMESTAMP(id) /* no tracing */ |
| @@ -64,10 +60,6 @@ feather_callback void save_timestamp_time(unsigned long event, unsigned long tim | |||
| 64 | 60 | ||
| 65 | #define LTIMESTAMP(id, when_ptr) /* no tracing */ | 61 | #define LTIMESTAMP(id, when_ptr) /* no tracing */ |
| 66 | 62 | ||
| 67 | #define TIMESTAMP_TIME(id, time_ptr) /* no tracing */ | ||
| 68 | |||
| 69 | #define TIMESTAMP_PID(id) /* no tracing */ | ||
| 70 | |||
| 71 | #endif | 63 | #endif |
| 72 | 64 | ||
| 73 | 65 | ||
| @@ -79,21 +71,6 @@ feather_callback void save_timestamp_time(unsigned long event, unsigned long tim | |||
| 79 | * always the next number after the start time event id. | 71 | * always the next number after the start time event id. |
| 80 | */ | 72 | */ |
| 81 | 73 | ||
| 82 | #define __TS_SYSCALL_IN_START(p) TIMESTAMP_TIME(10, p) | ||
| 83 | #define TS_SYSCALL_IN_END TIMESTAMP_PID(11) | ||
| 84 | |||
| 85 | #define TS_SYSCALL_OUT_START TIMESTAMP_PID(20) | ||
| 86 | #define TS_SYSCALL_OUT_END TIMESTAMP_PID(21) | ||
| 87 | |||
| 88 | #define TS_LOCK_START TIMESTAMP_PID(30) | ||
| 89 | #define TS_LOCK_END TIMESTAMP_PID(31) | ||
| 90 | |||
| 91 | #define TS_LOCK_SUSPEND TIMESTAMP_PID(38) | ||
| 92 | #define TS_LOCK_RESUME TIMESTAMP_PID(39) | ||
| 93 | |||
| 94 | #define TS_UNLOCK_START TIMESTAMP_PID(40) | ||
| 95 | #define TS_UNLOCK_END TIMESTAMP_PID(41) | ||
| 96 | |||
| 97 | #define TS_SCHED_START DTIMESTAMP(100, TSK_UNKNOWN) /* we only | 74 | #define TS_SCHED_START DTIMESTAMP(100, TSK_UNKNOWN) /* we only |
| 98 | * care | 75 | * care |
| 99 | * about | 76 | * about |
| @@ -144,6 +121,14 @@ feather_callback void save_timestamp_time(unsigned long event, unsigned long tim | |||
| 144 | #define TS_EXIT_NP_START TIMESTAMP(150) | 121 | #define TS_EXIT_NP_START TIMESTAMP(150) |
| 145 | #define TS_EXIT_NP_END TIMESTAMP(151) | 122 | #define TS_EXIT_NP_END TIMESTAMP(151) |
| 146 | 123 | ||
| 124 | #define TS_LOCK_START TIMESTAMP(170) | ||
| 125 | #define TS_LOCK_SUSPEND TIMESTAMP(171) | ||
| 126 | #define TS_LOCK_RESUME TIMESTAMP(172) | ||
| 127 | #define TS_LOCK_END TIMESTAMP(173) | ||
| 128 | |||
| 129 | #define TS_UNLOCK_START TIMESTAMP(180) | ||
| 130 | #define TS_UNLOCK_END TIMESTAMP(181) | ||
| 131 | |||
| 147 | #define TS_SEND_RESCHED_START(c) CTIMESTAMP(190, c) | 132 | #define TS_SEND_RESCHED_START(c) CTIMESTAMP(190, c) |
| 148 | #define TS_SEND_RESCHED_END DTIMESTAMP(191, TSK_UNKNOWN) | 133 | #define TS_SEND_RESCHED_END DTIMESTAMP(191, TSK_UNKNOWN) |
| 149 | 134 | ||
