et-rs 0.5.2

Host-side Rust interface to the Esperanto ET-SoC-1 RISC-V accelerator
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
/* automatically generated by rust-bindgen 0.72.1 */

#[repr(C)]
#[derive(Default)]
pub struct __IncompleteArrayField<T>(::core::marker::PhantomData<T>, [T; 0]);
impl<T> __IncompleteArrayField<T> {
    #[inline]
    pub const fn new() -> Self {
        __IncompleteArrayField(::core::marker::PhantomData, [])
    }
    #[inline]
    pub fn as_ptr(&self) -> *const T {
        self as *const _ as *const T
    }
    #[inline]
    pub fn as_mut_ptr(&mut self) -> *mut T {
        self as *mut _ as *mut T
    }
    #[inline]
    pub unsafe fn as_slice(&self, len: usize) -> &[T] {
        unsafe { ::core::slice::from_raw_parts(self.as_ptr(), len) }
    }
    #[inline]
    pub unsafe fn as_mut_slice(&mut self, len: usize) -> &mut [T] {
        unsafe { ::core::slice::from_raw_parts_mut(self.as_mut_ptr(), len) }
    }
}
impl<T> ::core::fmt::Debug for __IncompleteArrayField<T> {
    fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
        fmt.write_str("__IncompleteArrayField")
    }
}
pub const TRACE_STRING_MAX_SIZE: u32 = 512;
pub const TRACE_MAGIC_HEADER: u32 = 1985229328;
pub const TRACE_VERSION_MAJOR: u32 = 0;
pub const TRACE_VERSION_MINOR: u32 = 6;
pub const TRACE_VERSION_PATCH: u32 = 0;
pub const TRACE_DEV_CONTEXT_GPRS: u32 = 31;
#[doc = " \\typedef trace_buffer_type_e\n\\brief Trace buffer type either MM, CM, SP etc."]
pub type trace_buffer_type_e = u8;
pub mod trace_buffer_type {
    #[doc = " \\enum trace_buffer_type\n\\brief Trace buffer type either MM, CM, or SP etc."]
    pub type Type = ::core::ffi::c_uint;
    pub const TRACE_MM_BUFFER: Type = 0;
    pub const TRACE_CM_BUFFER: Type = 1;
    pub const TRACE_SP_BUFFER: Type = 2;
    pub const TRACE_CM_UMODE_BUFFER: Type = 3;
    pub const TRACE_SP_STATS_BUFFER: Type = 4;
    pub const TRACE_MM_STATS_BUFFER: Type = 5;
}
#[doc = " \\typedef trace_header_type_e\n\\brief Trace buffer type either trace_buffer_std_header_t or trace_buffer_size_header_t."]
pub type trace_header_type_e = u8;
pub mod trace_header_type {
    #[doc = " \\enum trace_header_type\n\\brief Trace buffer header type."]
    pub type Type = ::core::ffi::c_uint;
    #[doc = "< Standard trace buffer header of type struct trace_buffer_std_header_t"]
    pub const TRACE_STD_HEADER: Type = 0;
    #[doc = "< Size only trace buffer header of type struct trace_buffer_size_header_t"]
    pub const TRACE_SIZE_HEADER: Type = 1;
}
#[doc = " \\typedef trace_type_e\n\\brief Trace packet type."]
pub type trace_type_e = u16;
pub mod trace_type {
    #[doc = " \\enum trace_type\n\\brief Trace packet types."]
    pub type Type = ::core::ffi::c_uint;
    pub const TRACE_TYPE_START: Type = 0;
    pub const TRACE_TYPE_STRING: Type = 0;
    pub const TRACE_TYPE_PMC_COUNTER: Type = 1;
    pub const TRACE_TYPE_PMC_COUNTERS_COMPUTE: Type = 2;
    pub const TRACE_TYPE_PMC_COUNTERS_MEMORY: Type = 3;
    pub const TRACE_TYPE_PMC_COUNTERS_SC: Type = 4;
    pub const TRACE_TYPE_PMC_COUNTERS_MS: Type = 5;
    pub const TRACE_TYPE_VALUE_U64: Type = 6;
    pub const TRACE_TYPE_VALUE_U32: Type = 7;
    pub const TRACE_TYPE_VALUE_U16: Type = 8;
    pub const TRACE_TYPE_VALUE_U8: Type = 9;
    pub const TRACE_TYPE_VALUE_FLOAT: Type = 10;
    pub const TRACE_TYPE_MEMORY: Type = 11;
    pub const TRACE_TYPE_EXCEPTION: Type = 12;
    pub const TRACE_TYPE_CMD_STATUS: Type = 13;
    pub const TRACE_TYPE_POWER_STATUS: Type = 14;
    pub const TRACE_TYPE_CUSTOM_EVENT: Type = 15;
    pub const TRACE_TYPE_USER_PROFILE_EVENT: Type = 16;
    pub const TRACE_TYPE_END: Type = 17;
}
pub mod trace_custom_type_sp {
    #[doc = " \\enum trace_custom_type_sp\n\\brief Trace custom type IDs for SP."]
    pub type Type = ::core::ffi::c_uint;
    pub const TRACE_CUSTOM_TYPE_SP_START: Type = 0;
    pub const TRACE_CUSTOM_TYPE_SP_PERF_GLOBALS: Type = 1;
    pub const TRACE_CUSTOM_TYPE_SP_POWER_GLOBALS: Type = 2;
    pub const TRACE_CUSTOM_TYPE_SP_POWER_STATES_GLOBALS: Type = 3;
    pub const TRACE_CUSTOM_TYPE_SP_OP_STATS: Type = 4;
    pub const TRACE_CUSTOM_TYPE_SP_COUNT: Type = 5;
    pub const TRACE_CUSTOM_TYPE_SP_END: Type = 999;
}
pub mod trace_custom_type_mm {
    #[doc = " \\enum trace_custom_type_mm\n\\brief Trace custom type IDs for MM."]
    pub type Type = ::core::ffi::c_uint;
    pub const TRACE_CUSTOM_TYPE_MM_START: Type = 1000;
    pub const TRACE_CUSTOM_TYPE_MM_COMPUTE_RESOURCES: Type = 1001;
    pub const TRACE_CUSTOM_TYPE_MM_COUNT: Type = 1002;
    pub const TRACE_CUSTOM_TYPE_MM_END: Type = 1999;
}
pub mod trace_custom_type_cm {
    #[doc = " \\enum trace_custom_type_cm\n\\brief Trace custom type IDs for CM."]
    pub type Type = ::core::ffi::c_uint;
    pub const TRACE_CUSTOM_TYPE_CM_START: Type = 2000;
    pub const TRACE_CUSTOM_TYPE_CM_COUNT: Type = 2001;
    pub const TRACE_CUSTOM_TYPE_CM_END: Type = 2999;
}
#[doc = " \\typedef trace_cmd_status_e\n\\brief Trace command statuses. Refers to enum trace_cmd_status."]
pub type trace_cmd_status_e = u8;
pub mod trace_cmd_status {
    #[doc = " \\enum trace_cmd_status\n\\brief Trace command statuses."]
    pub type Type = ::core::ffi::c_uint;
    #[doc = "< Conditional: Command is awaiting for Barrier to be released"]
    pub const CMD_STATUS_WAIT_BARRIER: Type = 1;
    #[doc = "< Command is popped/received from submission Queue."]
    pub const CMD_STATUS_RECEIVED: Type = 2;
    #[doc = "< Command is submitted for execution to respective component of device."]
    pub const CMD_STATUS_EXECUTING: Type = 3;
    #[doc = "< Command completed with a failure."]
    pub const CMD_STATUS_FAILED: Type = 4;
    #[doc = "< Command is aborted."]
    pub const CMD_STATUS_ABORTED: Type = 5;
    #[doc = "< Command completed successfully."]
    pub const CMD_STATUS_SUCCEEDED: Type = 6;
}
#[doc = " \\typedef pmc_counter_e\n\\brief Counter type of log timestamp. Refers to enum pmc_counter."]
pub type pmc_counter_e = u8;
pub mod pmc_counter {
    #[doc = " \\enum pmc_counter\n\\brief PMC counters to sample and log in trace."]
    pub type Type = ::core::ffi::c_uint;
    pub const PMC_COUNTER_HPMCOUNTER3: Type = 0;
    pub const PMC_COUNTER_HPMCOUNTER4: Type = 1;
    pub const PMC_COUNTER_HPMCOUNTER5: Type = 2;
    pub const PMC_COUNTER_HPMCOUNTER6: Type = 3;
    pub const PMC_COUNTER_HPMCOUNTER7: Type = 4;
    pub const PMC_COUNTER_HPMCOUNTER8: Type = 5;
    pub const PMC_COUNTER_SHIRE_CACHE_CYCLE: Type = 6;
    pub const PMC_COUNTER_SHIRE_CACHE_1: Type = 7;
    pub const PMC_COUNTER_SHIRE_CACHE_2: Type = 8;
    pub const PMC_COUNTER_MEMSHIRE_CYCLE: Type = 9;
    pub const PMC_COUNTER_MEMSHIRE_1: Type = 10;
    pub const PMC_COUNTER_MEMSHIRE_2: Type = 11;
    pub const PMC_COUNTER_MEMSHIRE0_CYCLE: Type = 12;
    pub const PMC_COUNTER_MEMSHIRE1_CYCLE: Type = 13;
    pub const PMC_COUNTER_MEMSHIRE2_CYCLE: Type = 14;
    pub const PMC_COUNTER_MEMSHIRE3_CYCLE: Type = 15;
    pub const PMC_COUNTER_MEMSHIRE4_CYCLE: Type = 16;
    pub const PMC_COUNTER_MEMSHIRE5_CYCLE: Type = 17;
    pub const PMC_COUNTER_MEMSHIRE6_CYCLE: Type = 18;
    pub const PMC_COUNTER_MEMSHIRE7_CYCLE: Type = 19;
    pub const PMC_COUNTER_MEMSHIRE0_1: Type = 20;
    pub const PMC_COUNTER_MEMSHIRE1_1: Type = 21;
    pub const PMC_COUNTER_MEMSHIRE2_1: Type = 22;
    pub const PMC_COUNTER_MEMSHIRE3_1: Type = 23;
    pub const PMC_COUNTER_MEMSHIRE4_1: Type = 24;
    pub const PMC_COUNTER_MEMSHIRE5_1: Type = 25;
    pub const PMC_COUNTER_MEMSHIRE6_1: Type = 26;
    pub const PMC_COUNTER_MEMSHIRE7_1: Type = 27;
    pub const PMC_COUNTER_MEMSHIRE0_2: Type = 28;
    pub const PMC_COUNTER_MEMSHIRE1_2: Type = 29;
    pub const PMC_COUNTER_MEMSHIRE2_2: Type = 30;
    pub const PMC_COUNTER_MEMSHIRE3_2: Type = 31;
    pub const PMC_COUNTER_MEMSHIRE4_2: Type = 32;
    pub const PMC_COUNTER_MEMSHIRE5_2: Type = 33;
    pub const PMC_COUNTER_MEMSHIRE6_2: Type = 34;
    pub const PMC_COUNTER_MEMSHIRE7_2: Type = 35;
}
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_version_t {
    pub major: u16,
    pub minor: u16,
    pub patch: u16,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_version_t"][::core::mem::size_of::<trace_version_t>() - 6usize];
    ["Alignment of trace_version_t"][::core::mem::align_of::<trace_version_t>() - 1usize];
    ["Offset of field: trace_version_t::major"]
        [::core::mem::offset_of!(trace_version_t, major) - 0usize];
    ["Offset of field: trace_version_t::minor"]
        [::core::mem::offset_of!(trace_version_t, minor) - 2usize];
    ["Offset of field: trace_version_t::patch"]
        [::core::mem::offset_of!(trace_version_t, patch) - 4usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_init_info_t {
    #[doc = "< Base address for Trace buffer."]
    pub buffer: u64,
    #[doc = "< Total size of the Trace buffer."]
    pub buffer_size: u32,
    #[doc = "< Threshold for free memory in the buffer for each hart."]
    pub threshold: u32,
    #[doc = "< Bit Mask of Shire to enable Trace Capture."]
    pub shire_mask: u64,
    #[doc = "< Bit Mask of Thread within a Shire to enable Trace Capture."]
    pub thread_mask: u64,
    #[doc = "< This is a bit mask, each bit corresponds to a specific Event to trace."]
    pub event_mask: u32,
    #[doc = "< This is a bit mask representing a list of filters for a given event to trace."]
    pub filter_mask: u32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_init_info_t"][::core::mem::size_of::<trace_init_info_t>() - 40usize];
    ["Alignment of trace_init_info_t"][::core::mem::align_of::<trace_init_info_t>() - 8usize];
    ["Offset of field: trace_init_info_t::buffer"]
        [::core::mem::offset_of!(trace_init_info_t, buffer) - 0usize];
    ["Offset of field: trace_init_info_t::buffer_size"]
        [::core::mem::offset_of!(trace_init_info_t, buffer_size) - 8usize];
    ["Offset of field: trace_init_info_t::threshold"]
        [::core::mem::offset_of!(trace_init_info_t, threshold) - 12usize];
    ["Offset of field: trace_init_info_t::shire_mask"]
        [::core::mem::offset_of!(trace_init_info_t, shire_mask) - 16usize];
    ["Offset of field: trace_init_info_t::thread_mask"]
        [::core::mem::offset_of!(trace_init_info_t, thread_mask) - 24usize];
    ["Offset of field: trace_init_info_t::event_mask"]
        [::core::mem::offset_of!(trace_init_info_t, event_mask) - 32usize];
    ["Offset of field: trace_init_info_t::filter_mask"]
        [::core::mem::offset_of!(trace_init_info_t, filter_mask) - 36usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_config_info_t {
    #[doc = "< This is a bit mask, each bit corresponds to a specific Event to trace."]
    pub event_mask: u32,
    #[doc = "< This is a bit mask representing a list of filters for a given event to trace."]
    pub filter_mask: u32,
    #[doc = "< Threshold for free memory in the buffer for each hart."]
    pub threshold: u32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_config_info_t"][::core::mem::size_of::<trace_config_info_t>() - 12usize];
    ["Alignment of trace_config_info_t"][::core::mem::align_of::<trace_config_info_t>() - 4usize];
    ["Offset of field: trace_config_info_t::event_mask"]
        [::core::mem::offset_of!(trace_config_info_t, event_mask) - 0usize];
    ["Offset of field: trace_config_info_t::filter_mask"]
        [::core::mem::offset_of!(trace_config_info_t, filter_mask) - 4usize];
    ["Offset of field: trace_config_info_t::threshold"]
        [::core::mem::offset_of!(trace_config_info_t, threshold) - 8usize];
};
#[doc = " \\struct trace_buffer_size_header_t\n\\brief Trace buffer header (resides at the beggining of the buffer).\nIt contains size of valid data in that buffer.\nThis header is used for sub-buffers when a buffer is partitioned into sub-bufers."]
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_buffer_size_header_t {
    #[doc = "< Data in the buffer."]
    pub data_size: u32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_buffer_size_header_t"]
        [::core::mem::size_of::<trace_buffer_size_header_t>() - 4usize];
    ["Alignment of trace_buffer_size_header_t"]
        [::core::mem::align_of::<trace_buffer_size_header_t>() - 1usize];
    ["Offset of field: trace_buffer_size_header_t::data_size"]
        [::core::mem::offset_of!(trace_buffer_size_header_t, data_size) - 0usize];
};
#[doc = " \\struct trace_buffer_std_header_t\n\\brief Trace buffer header (resides at the beggining of the buffer).\nIt contains size of valid data, type of buffer and Esperanto magic\nnumber to validate buffer. It is used for once for the whole buffer\nnot matter if it divided into sub-buffers or not\nNote: This structure must be cache-line aligned, i.e, 64-bytes aligned."]
#[repr(C)]
#[repr(align(64))]
#[derive(Debug, Copy, Clone)]
pub struct trace_buffer_std_header_t {
    #[doc = "< Esperanto magic header."]
    pub magic_header: u32,
    #[doc = "< Trace Layout version Major, Minor, and Patch"]
    pub version: trace_version_t,
    #[doc = "< Buffer type one of enum trace_buffer_type_e."]
    pub type_: u16,
    #[doc = "< Data size after trace buffer standard header. It does not include data\nin sub-buffers (if present)"]
    pub data_size: u32,
    #[doc = "< Size of one partition on Trace buffer, All partitions must be equal in size."]
    pub sub_buffer_size: u32,
    #[doc = "< Number of Trace buffer partitions."]
    pub sub_buffer_count: u16,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_buffer_std_header_t"]
        [::core::mem::size_of::<trace_buffer_std_header_t>() - 64usize];
    ["Alignment of trace_buffer_std_header_t"]
        [::core::mem::align_of::<trace_buffer_std_header_t>() - 64usize];
    ["Offset of field: trace_buffer_std_header_t::magic_header"]
        [::core::mem::offset_of!(trace_buffer_std_header_t, magic_header) - 0usize];
    ["Offset of field: trace_buffer_std_header_t::version"]
        [::core::mem::offset_of!(trace_buffer_std_header_t, version) - 4usize];
    ["Offset of field: trace_buffer_std_header_t::type_"]
        [::core::mem::offset_of!(trace_buffer_std_header_t, type_) - 10usize];
    ["Offset of field: trace_buffer_std_header_t::data_size"]
        [::core::mem::offset_of!(trace_buffer_std_header_t, data_size) - 12usize];
    ["Offset of field: trace_buffer_std_header_t::sub_buffer_size"]
        [::core::mem::offset_of!(trace_buffer_std_header_t, sub_buffer_size) - 16usize];
    ["Offset of field: trace_buffer_std_header_t::sub_buffer_count"]
        [::core::mem::offset_of!(trace_buffer_std_header_t, sub_buffer_count) - 20usize];
};
impl Default for trace_buffer_std_header_t {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[doc = " \\struct trace_entry_header_t\n\\brief Information common for different entry types."]
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_entry_header_t {
    #[doc = "< Current cycle"]
    pub cycle: u64,
    #[doc = "< Size of the event payload following the entry header"]
    pub payload_size: u32,
    #[doc = "< (optional) Hart ID of the Hart which is logging Trace"]
    pub hart_id: u16,
    #[doc = "< One of enum trace_type"]
    pub type_: trace_type_e,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_entry_header_t"][::core::mem::size_of::<trace_entry_header_t>() - 16usize];
    ["Alignment of trace_entry_header_t"][::core::mem::align_of::<trace_entry_header_t>() - 1usize];
    ["Offset of field: trace_entry_header_t::cycle"]
        [::core::mem::offset_of!(trace_entry_header_t, cycle) - 0usize];
    ["Offset of field: trace_entry_header_t::payload_size"]
        [::core::mem::offset_of!(trace_entry_header_t, payload_size) - 8usize];
    ["Offset of field: trace_entry_header_t::hart_id"]
        [::core::mem::offset_of!(trace_entry_header_t, hart_id) - 12usize];
    ["Offset of field: trace_entry_header_t::type_"]
        [::core::mem::offset_of!(trace_entry_header_t, type_) - 14usize];
};
#[doc = " \\struct trace_pmc_counters_compute_t\n\\brief A Trace packet strucure for all compute PMC counters."]
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_pmc_counters_compute_t {
    pub header: trace_entry_header_t,
    pub hpmcounter3: u64,
    pub hpmcounter4: u64,
    pub hpmcounter5: u64,
    pub hpmcounter6: u64,
    pub hpmcounter7: u64,
    pub hpmcounter8: u64,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_pmc_counters_compute_t"]
        [::core::mem::size_of::<trace_pmc_counters_compute_t>() - 64usize];
    ["Alignment of trace_pmc_counters_compute_t"]
        [::core::mem::align_of::<trace_pmc_counters_compute_t>() - 1usize];
    ["Offset of field: trace_pmc_counters_compute_t::header"]
        [::core::mem::offset_of!(trace_pmc_counters_compute_t, header) - 0usize];
    ["Offset of field: trace_pmc_counters_compute_t::hpmcounter3"]
        [::core::mem::offset_of!(trace_pmc_counters_compute_t, hpmcounter3) - 16usize];
    ["Offset of field: trace_pmc_counters_compute_t::hpmcounter4"]
        [::core::mem::offset_of!(trace_pmc_counters_compute_t, hpmcounter4) - 24usize];
    ["Offset of field: trace_pmc_counters_compute_t::hpmcounter5"]
        [::core::mem::offset_of!(trace_pmc_counters_compute_t, hpmcounter5) - 32usize];
    ["Offset of field: trace_pmc_counters_compute_t::hpmcounter6"]
        [::core::mem::offset_of!(trace_pmc_counters_compute_t, hpmcounter6) - 40usize];
    ["Offset of field: trace_pmc_counters_compute_t::hpmcounter7"]
        [::core::mem::offset_of!(trace_pmc_counters_compute_t, hpmcounter7) - 48usize];
    ["Offset of field: trace_pmc_counters_compute_t::hpmcounter8"]
        [::core::mem::offset_of!(trace_pmc_counters_compute_t, hpmcounter8) - 56usize];
};
#[doc = " \\struct trace_pmc_counters_sc_t\n\\brief A Trace packet strucure for all shire cache PMC counters."]
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_pmc_counters_sc_t {
    pub header: trace_entry_header_t,
    pub sc_pmc0: u64,
    pub sc_pmc1: u64,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_pmc_counters_sc_t"]
        [::core::mem::size_of::<trace_pmc_counters_sc_t>() - 32usize];
    ["Alignment of trace_pmc_counters_sc_t"]
        [::core::mem::align_of::<trace_pmc_counters_sc_t>() - 1usize];
    ["Offset of field: trace_pmc_counters_sc_t::header"]
        [::core::mem::offset_of!(trace_pmc_counters_sc_t, header) - 0usize];
    ["Offset of field: trace_pmc_counters_sc_t::sc_pmc0"]
        [::core::mem::offset_of!(trace_pmc_counters_sc_t, sc_pmc0) - 16usize];
    ["Offset of field: trace_pmc_counters_sc_t::sc_pmc1"]
        [::core::mem::offset_of!(trace_pmc_counters_sc_t, sc_pmc1) - 24usize];
};
#[doc = " \\struct trace_pmc_counters_ms_t\n\\brief A Trace packet strucure for all mem shire PMC counters."]
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_pmc_counters_ms_t {
    pub header: trace_entry_header_t,
    pub ms_pmc0: u64,
    pub ms_pmc1: u64,
    pub ms_id: u8,
    pub pad: [u8; 7usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_pmc_counters_ms_t"]
        [::core::mem::size_of::<trace_pmc_counters_ms_t>() - 40usize];
    ["Alignment of trace_pmc_counters_ms_t"]
        [::core::mem::align_of::<trace_pmc_counters_ms_t>() - 1usize];
    ["Offset of field: trace_pmc_counters_ms_t::header"]
        [::core::mem::offset_of!(trace_pmc_counters_ms_t, header) - 0usize];
    ["Offset of field: trace_pmc_counters_ms_t::ms_pmc0"]
        [::core::mem::offset_of!(trace_pmc_counters_ms_t, ms_pmc0) - 16usize];
    ["Offset of field: trace_pmc_counters_ms_t::ms_pmc1"]
        [::core::mem::offset_of!(trace_pmc_counters_ms_t, ms_pmc1) - 24usize];
    ["Offset of field: trace_pmc_counters_ms_t::ms_id"]
        [::core::mem::offset_of!(trace_pmc_counters_ms_t, ms_id) - 32usize];
    ["Offset of field: trace_pmc_counters_ms_t::pad"]
        [::core::mem::offset_of!(trace_pmc_counters_ms_t, pad) - 33usize];
};
#[doc = " \\struct trace_pmc_counter_t\n\\brief A Trace packet strucure for a single PMC counter."]
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_pmc_counter_t {
    pub header: trace_entry_header_t,
    pub value: u64,
    pub counter: u8,
    pub pad: [u8; 7usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_pmc_counter_t"][::core::mem::size_of::<trace_pmc_counter_t>() - 32usize];
    ["Alignment of trace_pmc_counter_t"][::core::mem::align_of::<trace_pmc_counter_t>() - 1usize];
    ["Offset of field: trace_pmc_counter_t::header"]
        [::core::mem::offset_of!(trace_pmc_counter_t, header) - 0usize];
    ["Offset of field: trace_pmc_counter_t::value"]
        [::core::mem::offset_of!(trace_pmc_counter_t, value) - 16usize];
    ["Offset of field: trace_pmc_counter_t::counter"]
        [::core::mem::offset_of!(trace_pmc_counter_t, counter) - 24usize];
    ["Offset of field: trace_pmc_counter_t::pad"]
        [::core::mem::offset_of!(trace_pmc_counter_t, pad) - 25usize];
};
#[doc = " \\struct trace_event_cmd_status_t\n\\brief A Trace event strucure for a command execution status."]
#[repr(C, packed)]
#[derive(Copy, Clone)]
pub struct trace_event_cmd_status_t {
    pub __bindgen_anon_1: trace_event_cmd_status_t__bindgen_ty_1,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union trace_event_cmd_status_t__bindgen_ty_1 {
    pub __bindgen_anon_1: trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1,
    pub raw_cmd: u64,
}
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1 {
    #[doc = "< Command message ID"]
    pub mesg_id: u16,
    #[doc = "< Command execution status, One of enum trace_cmd_status"]
    pub cmd_status: trace_cmd_status_e,
    #[doc = "< Submission Queue ID from which command is popped"]
    pub queue_slot_id: u8,
    #[doc = "< transaction ID of command e.g. Tag ID."]
    pub trans_id: u16,
    #[doc = "< Reserved"]
    pub reserved: [u8; 2usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1"]
        [::core::mem::size_of::<trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1>() - 8usize];
    ["Alignment of trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1"]
        [::core::mem::align_of::<trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1>() - 1usize];
    ["Offset of field: trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1::mesg_id"][::core::mem::offset_of!(
        trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1,
        mesg_id
    ) - 0usize];
    ["Offset of field: trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1::cmd_status"][::core::mem::offset_of!(
        trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1,
        cmd_status
    )
        - 2usize];
    ["Offset of field: trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1::queue_slot_id"][::core::mem::offset_of!(
        trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1,
        queue_slot_id
    )
        - 3usize];
    ["Offset of field: trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1::trans_id"][::core::mem::offset_of!(
        trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1,
        trans_id
    ) - 4usize];
    ["Offset of field: trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1::reserved"][::core::mem::offset_of!(
        trace_event_cmd_status_t__bindgen_ty_1__bindgen_ty_1,
        reserved
    ) - 6usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_event_cmd_status_t__bindgen_ty_1"]
        [::core::mem::size_of::<trace_event_cmd_status_t__bindgen_ty_1>() - 8usize];
    ["Alignment of trace_event_cmd_status_t__bindgen_ty_1"]
        [::core::mem::align_of::<trace_event_cmd_status_t__bindgen_ty_1>() - 8usize];
    ["Offset of field: trace_event_cmd_status_t__bindgen_ty_1::raw_cmd"]
        [::core::mem::offset_of!(trace_event_cmd_status_t__bindgen_ty_1, raw_cmd) - 0usize];
};
impl Default for trace_event_cmd_status_t__bindgen_ty_1 {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_event_cmd_status_t"]
        [::core::mem::size_of::<trace_event_cmd_status_t>() - 8usize];
    ["Alignment of trace_event_cmd_status_t"]
        [::core::mem::align_of::<trace_event_cmd_status_t>() - 1usize];
};
impl Default for trace_event_cmd_status_t {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[doc = " \\struct trace_entry_header_t\n\\brief A Trace packet strucure for a command execution status."]
#[repr(C, packed)]
#[derive(Copy, Clone)]
pub struct trace_cmd_status_t {
    pub header: trace_entry_header_t,
    pub cmd: trace_event_cmd_status_t,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_cmd_status_t"][::core::mem::size_of::<trace_cmd_status_t>() - 24usize];
    ["Alignment of trace_cmd_status_t"][::core::mem::align_of::<trace_cmd_status_t>() - 1usize];
    ["Offset of field: trace_cmd_status_t::header"]
        [::core::mem::offset_of!(trace_cmd_status_t, header) - 0usize];
    ["Offset of field: trace_cmd_status_t::cmd"]
        [::core::mem::offset_of!(trace_cmd_status_t, cmd) - 16usize];
};
impl Default for trace_cmd_status_t {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[doc = " \\struct trace_entry_header_t\n\\brief A Trace event strucure for a power status."]
#[repr(C, packed)]
#[derive(Copy, Clone)]
pub struct trace_event_power_status_t {
    pub __bindgen_anon_1: trace_event_power_status_t__bindgen_ty_1,
    pub __bindgen_anon_2: trace_event_power_status_t__bindgen_ty_2,
    pub pad_2: [u8; 4usize],
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union trace_event_power_status_t__bindgen_ty_1 {
    pub __bindgen_anon_1: trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1,
    pub raw_bits_64: u64,
}
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1 {
    #[doc = "< Current Power in mW"]
    pub current_power: u16,
    #[doc = "< Power Throttle State: UP, Down"]
    pub throttle_state: u8,
    #[doc = "< Power State: Max, Managed, Safe, Low"]
    pub power_state: u8,
    #[doc = "< Current Temperature in C"]
    pub current_temp: u8,
    pub pad_1: [u8; 3usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1"]
        [::core::mem::size_of::<trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1>() - 8usize];
    ["Alignment of trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1"][::core::mem::align_of::<
        trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1,
    >() - 1usize];
    ["Offset of field: trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1::current_power"][::core::mem::offset_of!(
        trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1,
        current_power
    )
        - 0usize];
    ["Offset of field: trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1::throttle_state"][::core::mem::offset_of!(
        trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1,
        throttle_state
    )
        - 2usize];
    ["Offset of field: trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1::power_state"][::core::mem::offset_of!(
        trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1,
        power_state
    )
        - 3usize];
    ["Offset of field: trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1::current_temp"][::core::mem::offset_of!(
        trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1,
        current_temp
    )
        - 4usize];
    ["Offset of field: trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1::pad_1"][::core::mem::offset_of!(
        trace_event_power_status_t__bindgen_ty_1__bindgen_ty_1,
        pad_1
    ) - 5usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_event_power_status_t__bindgen_ty_1"]
        [::core::mem::size_of::<trace_event_power_status_t__bindgen_ty_1>() - 8usize];
    ["Alignment of trace_event_power_status_t__bindgen_ty_1"]
        [::core::mem::align_of::<trace_event_power_status_t__bindgen_ty_1>() - 8usize];
    ["Offset of field: trace_event_power_status_t__bindgen_ty_1::raw_bits_64"]
        [::core::mem::offset_of!(trace_event_power_status_t__bindgen_ty_1, raw_bits_64) - 0usize];
};
impl Default for trace_event_power_status_t__bindgen_ty_1 {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union trace_event_power_status_t__bindgen_ty_2 {
    pub __bindgen_anon_1: trace_event_power_status_t__bindgen_ty_2__bindgen_ty_1,
    pub raw_bits_32: u32,
}
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_event_power_status_t__bindgen_ty_2__bindgen_ty_1 {
    #[doc = "< Target Frequency in Mhz"]
    pub tgt_freq: u16,
    #[doc = "< Target Voltage in mV"]
    pub tgt_voltage: u16,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_event_power_status_t__bindgen_ty_2__bindgen_ty_1"]
        [::core::mem::size_of::<trace_event_power_status_t__bindgen_ty_2__bindgen_ty_1>() - 4usize];
    ["Alignment of trace_event_power_status_t__bindgen_ty_2__bindgen_ty_1"][::core::mem::align_of::<
        trace_event_power_status_t__bindgen_ty_2__bindgen_ty_1,
    >() - 1usize];
    ["Offset of field: trace_event_power_status_t__bindgen_ty_2__bindgen_ty_1::tgt_freq"][::core::mem::offset_of!(
        trace_event_power_status_t__bindgen_ty_2__bindgen_ty_1,
        tgt_freq
    )
        - 0usize];
    ["Offset of field: trace_event_power_status_t__bindgen_ty_2__bindgen_ty_1::tgt_voltage"][::core::mem::offset_of!(
        trace_event_power_status_t__bindgen_ty_2__bindgen_ty_1,
        tgt_voltage
    )
        - 2usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_event_power_status_t__bindgen_ty_2"]
        [::core::mem::size_of::<trace_event_power_status_t__bindgen_ty_2>() - 4usize];
    ["Alignment of trace_event_power_status_t__bindgen_ty_2"]
        [::core::mem::align_of::<trace_event_power_status_t__bindgen_ty_2>() - 4usize];
    ["Offset of field: trace_event_power_status_t__bindgen_ty_2::raw_bits_32"]
        [::core::mem::offset_of!(trace_event_power_status_t__bindgen_ty_2, raw_bits_32) - 0usize];
};
impl Default for trace_event_power_status_t__bindgen_ty_2 {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_event_power_status_t"]
        [::core::mem::size_of::<trace_event_power_status_t>() - 16usize];
    ["Alignment of trace_event_power_status_t"]
        [::core::mem::align_of::<trace_event_power_status_t>() - 1usize];
    ["Offset of field: trace_event_power_status_t::pad_2"]
        [::core::mem::offset_of!(trace_event_power_status_t, pad_2) - 12usize];
};
impl Default for trace_event_power_status_t {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[doc = " \\struct trace_entry_header_t\n\\brief A Trace packet strucure for a power status."]
#[repr(C, packed)]
#[derive(Copy, Clone)]
pub struct trace_power_status_t {
    pub header: trace_entry_header_t,
    pub power: trace_event_power_status_t,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_power_status_t"][::core::mem::size_of::<trace_power_status_t>() - 32usize];
    ["Alignment of trace_power_status_t"][::core::mem::align_of::<trace_power_status_t>() - 1usize];
    ["Offset of field: trace_power_status_t::header"]
        [::core::mem::offset_of!(trace_power_status_t, header) - 0usize];
    ["Offset of field: trace_power_status_t::power"]
        [::core::mem::offset_of!(trace_power_status_t, power) - 16usize];
};
impl Default for trace_power_status_t {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[doc = " \\struct trace_entry_header_t\n\\brief A Trace packet strucure for a string message."]
#[repr(C, packed)]
pub struct trace_string_t {
    pub header: trace_entry_header_t,
    pub string: __IncompleteArrayField<::core::ffi::c_char>,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_string_t"][::core::mem::size_of::<trace_string_t>() - 16usize];
    ["Alignment of trace_string_t"][::core::mem::align_of::<trace_string_t>() - 1usize];
    ["Offset of field: trace_string_t::header"]
        [::core::mem::offset_of!(trace_string_t, header) - 0usize];
    ["Offset of field: trace_string_t::string"]
        [::core::mem::offset_of!(trace_string_t, string) - 16usize];
};
impl Default for trace_string_t {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[doc = " \\struct trace_entry_header_t\n\\brief A Trace packet strucure for a memory dump of variable size."]
#[repr(C, packed)]
pub struct trace_memory_t {
    pub header: trace_entry_header_t,
    pub src_addr: u64,
    pub size: u64,
    pub data: __IncompleteArrayField<u8>,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_memory_t"][::core::mem::size_of::<trace_memory_t>() - 32usize];
    ["Alignment of trace_memory_t"][::core::mem::align_of::<trace_memory_t>() - 1usize];
    ["Offset of field: trace_memory_t::header"]
        [::core::mem::offset_of!(trace_memory_t, header) - 0usize];
    ["Offset of field: trace_memory_t::src_addr"]
        [::core::mem::offset_of!(trace_memory_t, src_addr) - 16usize];
    ["Offset of field: trace_memory_t::size"]
        [::core::mem::offset_of!(trace_memory_t, size) - 24usize];
    ["Offset of field: trace_memory_t::data"]
        [::core::mem::offset_of!(trace_memory_t, data) - 32usize];
};
impl Default for trace_memory_t {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[doc = " \\struct dev_context_registers_t\n\\brief A structure containing the device context registers."]
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct dev_context_registers_t {
    pub epc: u64,
    pub tval: u64,
    pub status: u64,
    pub cause: u64,
    pub gpr: [u64; 31usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of dev_context_registers_t"]
        [::core::mem::size_of::<dev_context_registers_t>() - 280usize];
    ["Alignment of dev_context_registers_t"]
        [::core::mem::align_of::<dev_context_registers_t>() - 1usize];
    ["Offset of field: dev_context_registers_t::epc"]
        [::core::mem::offset_of!(dev_context_registers_t, epc) - 0usize];
    ["Offset of field: dev_context_registers_t::tval"]
        [::core::mem::offset_of!(dev_context_registers_t, tval) - 8usize];
    ["Offset of field: dev_context_registers_t::status"]
        [::core::mem::offset_of!(dev_context_registers_t, status) - 16usize];
    ["Offset of field: dev_context_registers_t::cause"]
        [::core::mem::offset_of!(dev_context_registers_t, cause) - 24usize];
    ["Offset of field: dev_context_registers_t::gpr"]
        [::core::mem::offset_of!(dev_context_registers_t, gpr) - 32usize];
};
#[doc = " \\struct trace_execution_stack_t\n\\brief A Trace packet strucure for logging the execution stack of device registers."]
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_execution_stack_t {
    pub header: trace_entry_header_t,
    pub registers: dev_context_registers_t,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_execution_stack_t"]
        [::core::mem::size_of::<trace_execution_stack_t>() - 296usize];
    ["Alignment of trace_execution_stack_t"]
        [::core::mem::align_of::<trace_execution_stack_t>() - 1usize];
    ["Offset of field: trace_execution_stack_t::header"]
        [::core::mem::offset_of!(trace_execution_stack_t, header) - 0usize];
    ["Offset of field: trace_execution_stack_t::registers"]
        [::core::mem::offset_of!(trace_execution_stack_t, registers) - 16usize];
};
#[doc = " \\struct trace_custom_event_t\n\\brief A Trace packet strucure for logging a custom event in trace buffer."]
#[repr(C, packed)]
pub struct trace_custom_event_t {
    pub header: trace_entry_header_t,
    pub custom_type: u32,
    pub payload_size: u32,
    pub payload: __IncompleteArrayField<u8>,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_custom_event_t"][::core::mem::size_of::<trace_custom_event_t>() - 24usize];
    ["Alignment of trace_custom_event_t"][::core::mem::align_of::<trace_custom_event_t>() - 1usize];
    ["Offset of field: trace_custom_event_t::header"]
        [::core::mem::offset_of!(trace_custom_event_t, header) - 0usize];
    ["Offset of field: trace_custom_event_t::custom_type"]
        [::core::mem::offset_of!(trace_custom_event_t, custom_type) - 16usize];
    ["Offset of field: trace_custom_event_t::payload_size"]
        [::core::mem::offset_of!(trace_custom_event_t, payload_size) - 20usize];
    ["Offset of field: trace_custom_event_t::payload"]
        [::core::mem::offset_of!(trace_custom_event_t, payload) - 24usize];
};
impl Default for trace_custom_event_t {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_value_u64_t {
    pub header: trace_entry_header_t,
    pub tag: u32,
    pub value: u64,
    pub pad: [u8; 4usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_value_u64_t"][::core::mem::size_of::<trace_value_u64_t>() - 32usize];
    ["Alignment of trace_value_u64_t"][::core::mem::align_of::<trace_value_u64_t>() - 1usize];
    ["Offset of field: trace_value_u64_t::header"]
        [::core::mem::offset_of!(trace_value_u64_t, header) - 0usize];
    ["Offset of field: trace_value_u64_t::tag"]
        [::core::mem::offset_of!(trace_value_u64_t, tag) - 16usize];
    ["Offset of field: trace_value_u64_t::value"]
        [::core::mem::offset_of!(trace_value_u64_t, value) - 20usize];
    ["Offset of field: trace_value_u64_t::pad"]
        [::core::mem::offset_of!(trace_value_u64_t, pad) - 28usize];
};
#[repr(C, packed)]
pub struct trace_value_u32_t {
    pub header: trace_entry_header_t,
    pub tag: u32,
    pub value: u32,
    pub pad: __IncompleteArrayField<u8>,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_value_u32_t"][::core::mem::size_of::<trace_value_u32_t>() - 24usize];
    ["Alignment of trace_value_u32_t"][::core::mem::align_of::<trace_value_u32_t>() - 1usize];
    ["Offset of field: trace_value_u32_t::header"]
        [::core::mem::offset_of!(trace_value_u32_t, header) - 0usize];
    ["Offset of field: trace_value_u32_t::tag"]
        [::core::mem::offset_of!(trace_value_u32_t, tag) - 16usize];
    ["Offset of field: trace_value_u32_t::value"]
        [::core::mem::offset_of!(trace_value_u32_t, value) - 20usize];
    ["Offset of field: trace_value_u32_t::pad"]
        [::core::mem::offset_of!(trace_value_u32_t, pad) - 24usize];
};
impl Default for trace_value_u32_t {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_value_u16_t {
    pub header: trace_entry_header_t,
    pub tag: u32,
    pub value: u16,
    pub pad: [u8; 2usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_value_u16_t"][::core::mem::size_of::<trace_value_u16_t>() - 24usize];
    ["Alignment of trace_value_u16_t"][::core::mem::align_of::<trace_value_u16_t>() - 1usize];
    ["Offset of field: trace_value_u16_t::header"]
        [::core::mem::offset_of!(trace_value_u16_t, header) - 0usize];
    ["Offset of field: trace_value_u16_t::tag"]
        [::core::mem::offset_of!(trace_value_u16_t, tag) - 16usize];
    ["Offset of field: trace_value_u16_t::value"]
        [::core::mem::offset_of!(trace_value_u16_t, value) - 20usize];
    ["Offset of field: trace_value_u16_t::pad"]
        [::core::mem::offset_of!(trace_value_u16_t, pad) - 22usize];
};
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_value_u8_t {
    pub header: trace_entry_header_t,
    pub tag: u32,
    pub value: u8,
    pub pad: [u8; 3usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_value_u8_t"][::core::mem::size_of::<trace_value_u8_t>() - 24usize];
    ["Alignment of trace_value_u8_t"][::core::mem::align_of::<trace_value_u8_t>() - 1usize];
    ["Offset of field: trace_value_u8_t::header"]
        [::core::mem::offset_of!(trace_value_u8_t, header) - 0usize];
    ["Offset of field: trace_value_u8_t::tag"]
        [::core::mem::offset_of!(trace_value_u8_t, tag) - 16usize];
    ["Offset of field: trace_value_u8_t::value"]
        [::core::mem::offset_of!(trace_value_u8_t, value) - 20usize];
    ["Offset of field: trace_value_u8_t::pad"]
        [::core::mem::offset_of!(trace_value_u8_t, pad) - 21usize];
};
#[repr(C, packed)]
pub struct trace_value_float_t {
    pub header: trace_entry_header_t,
    pub tag: u32,
    pub value: f32,
    pub pad: __IncompleteArrayField<u8>,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_value_float_t"][::core::mem::size_of::<trace_value_float_t>() - 24usize];
    ["Alignment of trace_value_float_t"][::core::mem::align_of::<trace_value_float_t>() - 1usize];
    ["Offset of field: trace_value_float_t::header"]
        [::core::mem::offset_of!(trace_value_float_t, header) - 0usize];
    ["Offset of field: trace_value_float_t::tag"]
        [::core::mem::offset_of!(trace_value_float_t, tag) - 16usize];
    ["Offset of field: trace_value_float_t::value"]
        [::core::mem::offset_of!(trace_value_float_t, value) - 20usize];
    ["Offset of field: trace_value_float_t::pad"]
        [::core::mem::offset_of!(trace_value_float_t, pad) - 24usize];
};
impl Default for trace_value_float_t {
    fn default() -> Self {
        let mut s = ::core::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::core::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[doc = " \\struct trace_user_profile_event_t\n\\brief A Trace pkt structure for profile events."]
#[repr(C, packed)]
#[derive(Debug, Default, Copy, Clone)]
pub struct trace_user_profile_event_t {
    #[doc = "< generic event header"]
    pub header: trace_entry_header_t,
    #[doc = "< ptr to func literal emitting the event"]
    pub func: u64,
    #[doc = "< retiredInsts when the event is emitted"]
    pub retiredInsts: u64,
    #[doc = "< line(4 bytes) region (2 bytes) status (2 bytes)"]
    pub line_region_status: u64,
    #[doc = "< ptr to user region name"]
    pub regionName: u64,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of trace_user_profile_event_t"]
        [::core::mem::size_of::<trace_user_profile_event_t>() - 48usize];
    ["Alignment of trace_user_profile_event_t"]
        [::core::mem::align_of::<trace_user_profile_event_t>() - 1usize];
    ["Offset of field: trace_user_profile_event_t::header"]
        [::core::mem::offset_of!(trace_user_profile_event_t, header) - 0usize];
    ["Offset of field: trace_user_profile_event_t::func"]
        [::core::mem::offset_of!(trace_user_profile_event_t, func) - 16usize];
    ["Offset of field: trace_user_profile_event_t::retiredInsts"]
        [::core::mem::offset_of!(trace_user_profile_event_t, retiredInsts) - 24usize];
    ["Offset of field: trace_user_profile_event_t::line_region_status"]
        [::core::mem::offset_of!(trace_user_profile_event_t, line_region_status) - 32usize];
    ["Offset of field: trace_user_profile_event_t::regionName"]
        [::core::mem::offset_of!(trace_user_profile_event_t, regionName) - 40usize];
};