[Mono.Profiler.Log] Remove coverage event support.
[mono.git] / mcs / class / Mono.Profiler.Log / Mono.Profiler.Log / LogEvents.cs
1 // Licensed to the .NET Foundation under one or more agreements.
2 // The .NET Foundation licenses this file to you under the MIT license.
3 // See the LICENSE file in the project root for more information.
4
5 using System;
6 using System.Collections.Generic;
7
8 namespace Mono.Profiler.Log {
9
10         public sealed class AppDomainLoadEvent : LogEvent {
11
12                 public long AppDomainId { get; internal set; }
13
14                 internal override void Accept (LogEventVisitor visitor)
15                 {
16                         visitor.Visit (this);
17                 }
18         }
19
20         public sealed class AppDomainUnloadEvent : LogEvent {
21
22                 public long AppDomainId { get; internal set; }
23
24                 internal override void Accept (LogEventVisitor visitor)
25                 {
26                         visitor.Visit (this);
27                 }
28         }
29
30         public sealed class AppDomainNameEvent : LogEvent {
31
32                 public long AppDomainId { get; internal set; }
33
34                 public string Name { get; internal set; }
35
36                 internal override void Accept (LogEventVisitor visitor)
37                 {
38                         visitor.Visit (this);
39                 }
40         }
41
42         public sealed class ContextLoadEvent : LogEvent {
43
44                 public long ContextId { get; internal set; }
45
46                 public long AppDomainId { get; internal set; }
47
48                 internal override void Accept (LogEventVisitor visitor)
49                 {
50                         visitor.Visit (this);
51                 }
52         }
53
54         public sealed class ContextUnloadEvent : LogEvent {
55
56                 public long ContextId { get; internal set; }
57
58                 public long AppDomainId { get; internal set; }
59
60                 internal override void Accept (LogEventVisitor visitor)
61                 {
62                         visitor.Visit (this);
63                 }
64         }
65
66         public sealed class ThreadStartEvent : LogEvent {
67
68                 public long ThreadId { get; internal set; }
69
70                 internal override void Accept (LogEventVisitor visitor)
71                 {
72                         visitor.Visit (this);
73                 }
74         }
75
76         public sealed class ThreadEndEvent : LogEvent {
77
78                 public long ThreadId { get; internal set; }
79
80                 internal override void Accept (LogEventVisitor visitor)
81                 {
82                         visitor.Visit (this);
83                 }
84         }
85
86         public sealed class ThreadNameEvent : LogEvent {
87
88                 public long ThreadId { get; internal set; }
89
90                 public string Name { get; internal set; }
91
92                 internal override void Accept (LogEventVisitor visitor)
93                 {
94                         visitor.Visit (this);
95                 }
96         }
97
98         public sealed class ImageLoadEvent : LogEvent {
99
100                 public long ImagePointer { get; internal set; }
101
102                 public string Name { get; internal set; }
103
104                 internal override void Accept (LogEventVisitor visitor)
105                 {
106                         visitor.Visit (this);
107                 }
108         }
109
110         public sealed class ImageUnloadEvent : LogEvent {
111
112                 public long ImagePointer { get; internal set; }
113
114                 public string Name { get; internal set; }
115
116                 internal override void Accept (LogEventVisitor visitor)
117                 {
118                         visitor.Visit (this);
119                 }
120         }
121
122         public sealed class AssemblyLoadEvent : LogEvent {
123
124                 public long AssemblyPointer { get; internal set; }
125
126                 public long ImagePointer { get; internal set; }
127
128                 public string Name { get; internal set; }
129
130                 internal override void Accept (LogEventVisitor visitor)
131                 {
132                         visitor.Visit (this);
133                 }
134         }
135
136         public sealed class AssemblyUnloadEvent : LogEvent {
137
138                 public long AssemblyPointer { get; internal set; }
139
140                 public long ImagePointer { get; internal set; }
141
142                 public string Name { get; internal set; }
143
144                 internal override void Accept (LogEventVisitor visitor)
145                 {
146                         visitor.Visit (this);
147                 }
148         }
149
150         public sealed class ClassLoadEvent : LogEvent {
151
152                 public long ClassPointer { get; internal set; }
153
154                 public long ImagePointer { get; internal set; }
155
156                 public string Name { get; internal set; }
157
158                 internal override void Accept (LogEventVisitor visitor)
159                 {
160                         visitor.Visit (this);
161                 }
162         }
163
164         public sealed class JitEvent : LogEvent {
165
166                 public long MethodPointer { get; internal set; }
167
168                 public long CodePointer { get; internal set; }
169
170                 public long CodeSize { get; internal set; }
171
172                 public string Name { get; internal set; }
173
174                 internal override void Accept (LogEventVisitor visitor)
175                 {
176                         visitor.Visit (this);
177                 }
178         }
179
180         public sealed class JitHelperEvent : LogEvent {
181
182                 public LogJitHelper Type { get; internal set; }
183
184                 public long BufferPointer { get; internal set; }
185
186                 public long BufferSize { get; internal set; }
187
188                 public string Name { get; internal set; }
189
190                 internal override void Accept (LogEventVisitor visitor)
191                 {
192                         visitor.Visit (this);
193                 }
194         }
195
196         public sealed class AllocationEvent : LogEvent {
197
198                 public long ClassPointer { get; internal set; }
199
200                 public long ObjectPointer { get; internal set; }
201
202                 public long ObjectSize { get; internal set; }
203
204                 public IReadOnlyList<long> Backtrace { get; internal set; }
205
206                 internal override void Accept (LogEventVisitor visitor)
207                 {
208                         visitor.Visit (this);
209                 }
210         }
211
212         public sealed class HeapBeginEvent : LogEvent {
213
214                 internal override void Accept (LogEventVisitor visitor)
215                 {
216                         visitor.Visit (this);
217                 }
218         }
219
220         public sealed class HeapEndEvent : LogEvent {
221
222                 internal override void Accept (LogEventVisitor visitor)
223                 {
224                         visitor.Visit (this);
225                 }
226         }
227
228         public sealed class HeapObjectEvent : LogEvent {
229
230                 public struct HeapObjectReference {
231
232                         public long Offset { get; internal set; }
233
234                         public long ObjectPointer { get; internal set; }
235                 }
236
237                 public long ObjectPointer { get; internal set; }
238
239                 public long ClassPointer { get; internal set; }
240
241                 public long ObjectSize { get; internal set; }
242
243                 public IReadOnlyList<HeapObjectReference> References { get; internal set; }
244
245                 internal override void Accept (LogEventVisitor visitor)
246                 {
247                         visitor.Visit (this);
248                 }
249         }
250
251         public sealed class HeapRootsEvent : LogEvent {
252
253                 public struct HeapRoot {
254
255                         public long ObjectPointer { get; internal set; }
256
257                         public LogHeapRootAttributes Attributes { get; internal set; }
258
259                         public long ExtraInfo { get; internal set; }
260                 }
261
262                 public long MaxGenerationCollectionCount { get; internal set; }
263
264                 public IReadOnlyList<HeapRoot> Roots { get; internal set; }
265
266                 internal override void Accept (LogEventVisitor visitor)
267                 {
268                         visitor.Visit (this);
269                 }
270         }
271
272         public sealed class GCEvent : LogEvent {
273
274                 public LogGCEvent Type { get; internal set; }
275
276                 public byte Generation { get; internal set; }
277
278                 internal override void Accept (LogEventVisitor visitor)
279                 {
280                         visitor.Visit (this);
281                 }
282         }
283
284         public sealed class GCResizeEvent : LogEvent {
285
286                 public long NewSize { get; internal set; }
287
288                 internal override void Accept (LogEventVisitor visitor)
289                 {
290                         visitor.Visit (this);
291                 }
292         }
293
294         public sealed class GCMoveEvent : LogEvent {
295
296                 public IReadOnlyList<long> OldObjectPointers { get; internal set; }
297
298                 public IReadOnlyList<long> NewObjectPointers { get; internal set; }
299
300                 internal override void Accept (LogEventVisitor visitor)
301                 {
302                         visitor.Visit (this);
303                 }
304         }
305
306         public sealed class GCHandleCreationEvent : LogEvent {
307
308                 public LogGCHandleType Type { get; internal set; }
309
310                 public long Handle { get; internal set; }
311
312                 public long ObjectPointer { get; internal set; }
313
314                 public IReadOnlyList<long> Backtrace { get; internal set; }
315
316                 internal override void Accept (LogEventVisitor visitor)
317                 {
318                         visitor.Visit (this);
319                 }
320         }
321
322         public sealed class GCHandleDeletionEvent : LogEvent {
323
324                 public LogGCHandleType Type { get; internal set; }
325
326                 public long Handle { get; internal set; }
327
328                 public IReadOnlyList<long> Backtrace { get; internal set; }
329
330                 internal override void Accept (LogEventVisitor visitor)
331                 {
332                         visitor.Visit (this);
333                 }
334         }
335
336         public sealed class GCFinalizeBeginEvent : LogEvent {
337
338                 internal override void Accept (LogEventVisitor visitor)
339                 {
340                         visitor.Visit (this);
341                 }
342         }
343
344         public sealed class GCFinalizeEndEvent : LogEvent {
345
346                 internal override void Accept (LogEventVisitor visitor)
347                 {
348                         visitor.Visit (this);
349                 }
350         }
351
352         public sealed class GCFinalizeObjectBeginEvent : LogEvent {
353
354                 public long ObjectPointer { get; internal set; }
355
356                 internal override void Accept (LogEventVisitor visitor)
357                 {
358                         visitor.Visit (this);
359                 }
360         }
361
362         public sealed class GCFinalizeObjectEndEvent : LogEvent {
363
364                 public long ObjectPointer { get; internal set; }
365
366                 internal override void Accept (LogEventVisitor visitor)
367                 {
368                         visitor.Visit (this);
369                 }
370         }
371
372         public sealed class ThrowEvent : LogEvent {
373
374                 public long ObjectPointer { get; internal set; }
375
376                 public IReadOnlyList<long> Backtrace { get; internal set; }
377
378                 internal override void Accept (LogEventVisitor visitor)
379                 {
380                         visitor.Visit (this);
381                 }
382         }
383
384         public sealed class ExceptionClauseEvent : LogEvent {
385
386                 public LogExceptionClause Type { get; internal set; }
387
388                 public long Index { get; internal set; }
389
390                 public long MethodPointer { get; internal set; }
391
392                 public long ObjectPointer { get; internal set; }
393
394                 internal override void Accept (LogEventVisitor visitor)
395                 {
396                         visitor.Visit (this);
397                 }
398         }
399
400         public sealed class EnterEvent : LogEvent {
401
402                 public long MethodPointer { get; internal set; }
403
404                 internal override void Accept (LogEventVisitor visitor)
405                 {
406                         visitor.Visit (this);
407                 }
408         }
409
410         public sealed class LeaveEvent : LogEvent {
411
412                 public long MethodPointer { get; internal set; }
413
414                 internal override void Accept (LogEventVisitor visitor)
415                 {
416                         visitor.Visit (this);
417                 }
418         }
419
420         public sealed class ExceptionalLeaveEvent : LogEvent {
421
422                 public long MethodPointer { get; internal set; }
423
424                 internal override void Accept (LogEventVisitor visitor)
425                 {
426                         visitor.Visit (this);
427                 }
428         }
429
430         public sealed class MonitorEvent : LogEvent {
431
432                 public LogMonitorEvent Event { get; internal set; }
433
434                 public long ObjectPointer { get; internal set; }
435
436                 public IReadOnlyList<long> Backtrace { get; internal set; }
437
438                 internal override void Accept (LogEventVisitor visitor)
439                 {
440                         visitor.Visit (this);
441                 }
442         }
443
444         public sealed class SampleHitEvent : LogEvent {
445
446                 public long ThreadId { get; internal set; }
447
448                 public IReadOnlyList<long> UnmanagedBacktrace { get; internal set; }
449
450                 public IReadOnlyList<long> ManagedBacktrace { get; internal set; }
451
452                 internal override void Accept (LogEventVisitor visitor)
453                 {
454                         visitor.Visit (this);
455                 }
456         }
457
458         public sealed class CounterSamplesEvent : LogEvent {
459
460                 public struct CounterSample {
461
462                         public long Index { get; internal set; }
463
464                         public LogCounterType Type { get; internal set; }
465
466                         public object Value { get; internal set; }
467                 }
468
469                 public IReadOnlyList<CounterSample> Samples { get; internal set; }
470
471                 internal override void Accept (LogEventVisitor visitor)
472                 {
473                         visitor.Visit (this);
474                 }
475         }
476
477         public sealed class CounterDescriptionsEvent : LogEvent {
478
479                 public struct CounterDescription {
480
481                         public LogCounterSection Section { get; internal set; }
482
483                         public string SectionName { get; internal set; }
484
485                         public string CounterName { get; internal set; }
486
487                         public LogCounterType Type { get; internal set; }
488
489                         public LogCounterUnit Unit { get; internal set; }
490
491                         public LogCounterVariance Variance { get; internal set; }
492
493                         public long Index { get; internal set; }
494                 }
495
496                 public IReadOnlyList<CounterDescription> Descriptions { get; internal set; }
497
498                 internal override void Accept (LogEventVisitor visitor)
499                 {
500                         visitor.Visit (this);
501                 }
502         }
503
504         public sealed class UnmanagedBinaryEvent : LogEvent {
505
506                 public long SegmentPointer { get; internal set; }
507
508                 public long SegmentOffset { get; internal set; }
509
510                 public long SegmentSize { get; internal set; }
511
512                 public string FileName { get; internal set; }
513
514                 internal override void Accept (LogEventVisitor visitor)
515                 {
516                         visitor.Visit (this);
517                 }
518         }
519
520         public sealed class UnmanagedSymbolEvent : LogEvent {
521
522                 public long CodePointer { get; internal set; }
523
524                 public long CodeSize { get; internal set; }
525
526                 public string Name { get; internal set; }
527
528                 internal override void Accept (LogEventVisitor visitor)
529                 {
530                         visitor.Visit (this);
531                 }
532         }
533
534         public sealed class SynchronizationPointEvent : LogEvent {
535
536                 public LogSynchronizationPoint Type { get; internal set; }
537
538                 internal override void Accept (LogEventVisitor visitor)
539                 {
540                         visitor.Visit (this);
541                 }
542         }
543 }