-
Notifications
You must be signed in to change notification settings - Fork 67
/
wrapfcaliper.F
1304 lines (1154 loc) · 53.4 KB
/
wrapfcaliper.F
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
! wrapfcaliper.F
! This file is generated by Shroud 0.13.0. Do not edit.
!>
!! \file wrapfcaliper.F
!! \brief Shroud generated wrapper for cali namespace
!<
! splicer begin file_top
! splicer end file_top
module caliper_mod
use iso_c_binding, only : C_INT, C_INT64_T, C_LONG, C_NULL_PTR, C_PTR, C_SIZE_T
! splicer begin module_use
! splicer end module_use
implicit none
! splicer begin module_top
! splicer end module_top
! helper capsule_data_helper
type, bind(C) :: cali_SHROUD_capsule_data
type(C_PTR) :: addr = C_NULL_PTR ! address of C++ memory
integer(C_INT) :: idtor = 0 ! index of destructor
end type cali_SHROUD_capsule_data
! helper array_context
type, bind(C) :: cali_SHROUD_array
! address of C++ memory
type(cali_SHROUD_capsule_data) :: cxx
! address of data in cxx
type(C_PTR) :: base_addr = C_NULL_PTR
! type of element
integer(C_INT) :: type
! bytes-per-item or character len of data in cxx
integer(C_SIZE_T) :: elem_len = 0_C_SIZE_T
! size of data in cxx
integer(C_SIZE_T) :: size = 0_C_SIZE_T
! number of dimensions
integer(C_INT) :: rank = -1
integer(C_LONG) :: shape(7) = 0
end type cali_SHROUD_array
! typedef cali::cali_id_t
! splicer begin typedef.cali_id_t
integer, parameter :: cali_id_t = C_INT64_T
! splicer end typedef.cali_id_t
! enum cali::cali_attr_properties
integer(C_INT), parameter :: cali_attr_default = 0
integer(C_INT), parameter :: cali_attr_asvalue = 1
integer(C_INT), parameter :: cali_attr_nomerge = 2
integer(C_INT), parameter :: cali_attr_scope_process = 12
integer(C_INT), parameter :: cali_attr_scope_thread = 20
integer(C_INT), parameter :: cali_attr_scope_task = 24
integer(C_INT), parameter :: cali_attr_skip_events = 64
integer(C_INT), parameter :: cali_attr_hidden = 128
integer(C_INT), parameter :: cali_attr_nested = 256
integer(C_INT), parameter :: cali_attr_global = 512
integer(C_INT), parameter :: cali_attr_unaligned = 1024
integer(C_INT), parameter :: cali_attr_aggregatable = 2048
! enum cali::cali_attr_type
integer(C_INT), parameter :: cali_type_inv = 0
integer(C_INT), parameter :: cali_type_usr = 1
integer(C_INT), parameter :: cali_type_int = 2
integer(C_INT), parameter :: cali_type_uint = 3
integer(C_INT), parameter :: cali_type_string = 4
integer(C_INT), parameter :: cali_type_addr = 5
integer(C_INT), parameter :: cali_type_double = 6
integer(C_INT), parameter :: cali_type_bool = 7
integer(C_INT), parameter :: cali_type_type = 8
integer(C_INT), parameter :: cali_type_ptr = 9
! enum cali::cali_flush_opts
integer(C_INT), parameter :: cali_flush_clear_buffers = 1
type scopeannotation
type(cali_SHROUD_capsule_data) :: cxxmem
! splicer begin class.ScopeAnnotation.component_part
! splicer end class.ScopeAnnotation.component_part
contains
procedure :: end => scopeannotation_end
procedure :: get_instance => scopeannotation_get_instance
procedure :: set_instance => scopeannotation_set_instance
procedure :: associated => scopeannotation_associated
! splicer begin class.ScopeAnnotation.type_bound_procedure_part
! splicer end class.ScopeAnnotation.type_bound_procedure_part
end type scopeannotation
type annotation
type(cali_SHROUD_capsule_data) :: cxxmem
! splicer begin class.Annotation.component_part
! splicer end class.Annotation.component_part
contains
procedure :: delete => annotation_delete
procedure :: begin_int => annotation_begin_int
procedure :: begin_string => annotation_begin_string
procedure :: set_int => annotation_set_int
procedure :: set_string => annotation_set_string
procedure :: end => annotation_end
procedure :: get_instance => annotation_get_instance
procedure :: set_instance => annotation_set_instance
procedure :: associated => annotation_associated
generic :: begin => begin_int, begin_string
generic :: set => set_int, set_string
! splicer begin class.Annotation.type_bound_procedure_part
! splicer end class.Annotation.type_bound_procedure_part
end type annotation
type configmanager
type(cali_SHROUD_capsule_data) :: cxxmem
! splicer begin class.ConfigManager.component_part
! splicer end class.ConfigManager.component_part
contains
procedure :: delete => configmanager_delete
procedure :: set_default_parameter => configmanager_set_default_parameter
procedure :: set_default_parameter_for_config => configmanager_set_default_parameter_for_config
procedure :: add_config_spec => configmanager_add_config_spec
procedure :: add_option_spec => configmanager_add_option_spec
procedure :: add => configmanager_add
procedure :: error => configmanager_error
procedure :: error_msg => configmanager_error_msg
procedure :: start => configmanager_start
procedure :: stop => configmanager_stop
procedure :: flush => configmanager_flush
procedure :: get_instance => configmanager_get_instance
procedure :: set_instance => configmanager_set_instance
procedure :: associated => configmanager_associated
! splicer begin class.ConfigManager.type_bound_procedure_part
! splicer end class.ConfigManager.type_bound_procedure_part
end type configmanager
type bufferedregionprofile
type(cali_SHROUD_capsule_data) :: cxxmem
! splicer begin class.BufferedRegionProfile.component_part
! splicer end class.BufferedRegionProfile.component_part
contains
procedure :: delete => bufferedregionprofile_delete
procedure :: start => bufferedregionprofile_start
procedure :: stop => bufferedregionprofile_stop
procedure :: clear => bufferedregionprofile_clear
procedure :: fetch_exclusive_region_times => bufferedregionprofile_fetch_exclusive_region_times
procedure :: fetch_inclusive_region_times => bufferedregionprofile_fetch_inclusive_region_times
procedure :: total_profiling_time => bufferedregionprofile_total_profiling_time
procedure :: total_region_time => bufferedregionprofile_total_region_time
procedure :: region_time => bufferedregionprofile_region_time
procedure :: get_instance => bufferedregionprofile_get_instance
procedure :: set_instance => bufferedregionprofile_set_instance
procedure :: associated => bufferedregionprofile_associated
! splicer begin class.BufferedRegionProfile.type_bound_procedure_part
! splicer end class.BufferedRegionProfile.type_bound_procedure_part
end type bufferedregionprofile
interface operator (.eq.)
module procedure scopeannotation_eq
module procedure annotation_eq
module procedure configmanager_eq
module procedure bufferedregionprofile_eq
end interface
interface operator (.ne.)
module procedure scopeannotation_ne
module procedure annotation_ne
module procedure configmanager_ne
module procedure bufferedregionprofile_ne
end interface
interface
function c_scopeannotation_begin(name, SHT_rv) &
result(SHT_prv) &
bind(C, name="cali_ScopeAnnotation_begin")
use iso_c_binding, only : C_CHAR, C_PTR
import :: cali_SHROUD_capsule_data
implicit none
character(kind=C_CHAR), intent(IN) :: name(*)
type(cali_SHROUD_capsule_data), intent(OUT) :: SHT_rv
type(C_PTR) SHT_prv
end function c_scopeannotation_begin
subroutine c_scopeannotation_end(self) &
bind(C, name="cali_ScopeAnnotation_end")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(INOUT) :: self
end subroutine c_scopeannotation_end
function c_annotation_new(key, SHT_rv) &
result(SHT_prv) &
bind(C, name="cali_Annotation_new")
use iso_c_binding, only : C_CHAR, C_PTR
import :: cali_SHROUD_capsule_data
implicit none
character(kind=C_CHAR), intent(IN) :: key(*)
type(cali_SHROUD_capsule_data), intent(OUT) :: SHT_rv
type(C_PTR) SHT_prv
end function c_annotation_new
function c_annotation_new_with_properties(key, properties, &
SHT_rv) &
result(SHT_prv) &
bind(C, name="cali_Annotation_new_with_properties")
use iso_c_binding, only : C_CHAR, C_INT, C_PTR
import :: cali_SHROUD_capsule_data
implicit none
character(kind=C_CHAR), intent(IN) :: key(*)
integer(C_INT), value, intent(IN) :: properties
type(cali_SHROUD_capsule_data), intent(OUT) :: SHT_rv
type(C_PTR) SHT_prv
end function c_annotation_new_with_properties
subroutine c_annotation_delete(self) &
bind(C, name="cali_Annotation_delete")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(INOUT) :: self
end subroutine c_annotation_delete
subroutine c_annotation_begin_int(self, val) &
bind(C, name="cali_Annotation_begin_int")
use iso_c_binding, only : C_INT
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
integer(C_INT), value, intent(IN) :: val
end subroutine c_annotation_begin_int
subroutine c_annotation_begin_string(self, val) &
bind(C, name="cali_Annotation_begin_string")
use iso_c_binding, only : C_CHAR
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
character(kind=C_CHAR), intent(IN) :: val(*)
end subroutine c_annotation_begin_string
subroutine c_annotation_set_int(self, val) &
bind(C, name="cali_Annotation_set_int")
use iso_c_binding, only : C_INT
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
integer(C_INT), value, intent(IN) :: val
end subroutine c_annotation_set_int
subroutine c_annotation_set_string(self, val) &
bind(C, name="cali_Annotation_set_string")
use iso_c_binding, only : C_CHAR
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
character(kind=C_CHAR), intent(IN) :: val(*)
end subroutine c_annotation_set_string
subroutine c_annotation_end(self) &
bind(C, name="cali_Annotation_end")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
end subroutine c_annotation_end
function c_configmanager_new(SHT_rv) &
result(SHT_prv) &
bind(C, name="cali_ConfigManager_new")
use iso_c_binding, only : C_PTR
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(OUT) :: SHT_rv
type(C_PTR) SHT_prv
end function c_configmanager_new
subroutine c_configmanager_delete(self) &
bind(C, name="cali_ConfigManager_delete")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(INOUT) :: self
end subroutine c_configmanager_delete
subroutine c_configmanager_set_default_parameter(self, option, &
val) &
bind(C, name="cali_ConfigManager_set_default_parameter")
use iso_c_binding, only : C_CHAR
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
character(kind=C_CHAR), intent(IN) :: option(*)
character(kind=C_CHAR), intent(IN) :: val(*)
end subroutine c_configmanager_set_default_parameter
subroutine c_configmanager_set_default_parameter_for_config( &
self, config, option, val) &
bind(C, name="cali_ConfigManager_set_default_parameter_for_config")
use iso_c_binding, only : C_CHAR
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
character(kind=C_CHAR), intent(IN) :: config(*)
character(kind=C_CHAR), intent(IN) :: option(*)
character(kind=C_CHAR), intent(IN) :: val(*)
end subroutine c_configmanager_set_default_parameter_for_config
subroutine c_configmanager_add_config_spec(self, spec) &
bind(C, name="cali_ConfigManager_add_config_spec")
use iso_c_binding, only : C_CHAR
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
character(kind=C_CHAR), intent(IN) :: spec(*)
end subroutine c_configmanager_add_config_spec
subroutine c_configmanager_add_option_spec(self, spec) &
bind(C, name="cali_ConfigManager_add_option_spec")
use iso_c_binding, only : C_CHAR
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
character(kind=C_CHAR), intent(IN) :: spec(*)
end subroutine c_configmanager_add_option_spec
subroutine c_configmanager_add(self, config) &
bind(C, name="cali_ConfigManager_add")
use iso_c_binding, only : C_CHAR
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
character(kind=C_CHAR), intent(IN) :: config(*)
end subroutine c_configmanager_add
function c_configmanager_error(self) &
result(SHT_rv) &
bind(C, name="cali_ConfigManager_error")
use iso_c_binding, only : C_BOOL
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
logical(C_BOOL) :: SHT_rv
end function c_configmanager_error
subroutine c_configmanager_error_msg_bufferify(self, SHT_rv) &
bind(C, name="cali_ConfigManager_error_msg_bufferify")
import :: cali_SHROUD_array, cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
type(cali_SHROUD_array), intent(OUT) :: SHT_rv
end subroutine c_configmanager_error_msg_bufferify
subroutine c_configmanager_start(self) &
bind(C, name="cali_ConfigManager_start")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
end subroutine c_configmanager_start
subroutine c_configmanager_stop(self) &
bind(C, name="cali_ConfigManager_stop")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
end subroutine c_configmanager_stop
subroutine c_configmanager_flush(self) &
bind(C, name="cali_ConfigManager_flush")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
end subroutine c_configmanager_flush
function c_bufferedregionprofile_new(SHT_rv) &
result(SHT_prv) &
bind(C, name="cali_BufferedRegionProfile_new")
use iso_c_binding, only : C_PTR
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(OUT) :: SHT_rv
type(C_PTR) SHT_prv
end function c_bufferedregionprofile_new
subroutine c_bufferedregionprofile_delete(self) &
bind(C, name="cali_BufferedRegionProfile_delete")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(INOUT) :: self
end subroutine c_bufferedregionprofile_delete
subroutine c_bufferedregionprofile_start(self) &
bind(C, name="cali_BufferedRegionProfile_start")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
end subroutine c_bufferedregionprofile_start
subroutine c_bufferedregionprofile_stop(self) &
bind(C, name="cali_BufferedRegionProfile_stop")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
end subroutine c_bufferedregionprofile_stop
subroutine c_bufferedregionprofile_clear(self) &
bind(C, name="cali_BufferedRegionProfile_clear")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
end subroutine c_bufferedregionprofile_clear
subroutine c_bufferedregionprofile_fetch_exclusive_region_times( &
self) &
bind(C, name="cali_BufferedRegionProfile_fetch_exclusive_region_times")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
end subroutine c_bufferedregionprofile_fetch_exclusive_region_times
subroutine c_bufferedregionprofile_fetch_inclusive_region_times( &
self) &
bind(C, name="cali_BufferedRegionProfile_fetch_inclusive_region_times")
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
end subroutine c_bufferedregionprofile_fetch_inclusive_region_times
pure function c_bufferedregionprofile_total_profiling_time(self) &
result(SHT_rv) &
bind(C, name="cali_BufferedRegionProfile_total_profiling_time")
use iso_c_binding, only : C_DOUBLE
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
real(C_DOUBLE) :: SHT_rv
end function c_bufferedregionprofile_total_profiling_time
pure function c_bufferedregionprofile_total_region_time(self) &
result(SHT_rv) &
bind(C, name="cali_BufferedRegionProfile_total_region_time")
use iso_c_binding, only : C_DOUBLE
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
real(C_DOUBLE) :: SHT_rv
end function c_bufferedregionprofile_total_region_time
function c_bufferedregionprofile_region_time(self, region) &
result(SHT_rv) &
bind(C, name="cali_BufferedRegionProfile_region_time")
use iso_c_binding, only : C_CHAR, C_DOUBLE
import :: cali_SHROUD_capsule_data
implicit none
type(cali_SHROUD_capsule_data), intent(IN) :: self
character(kind=C_CHAR), intent(IN) :: region(*)
real(C_DOUBLE) :: SHT_rv
end function c_bufferedregionprofile_region_time
#ifdef CALIPER_HAVE_MPI
subroutine cali_mpi_init() &
bind(C, name="cali_mpi_init")
implicit none
end subroutine cali_mpi_init
#endif
subroutine cali_init() &
bind(C, name="cali_init")
implicit none
end subroutine cali_init
subroutine c_cali_config_preset(key, value) &
bind(C, name="cali_config_preset")
use iso_c_binding, only : C_CHAR
implicit none
character(kind=C_CHAR), intent(IN) :: key(*)
character(kind=C_CHAR), intent(IN) :: value(*)
end subroutine c_cali_config_preset
subroutine c_cali_config_set(key, value) &
bind(C, name="cali_config_set")
use iso_c_binding, only : C_CHAR
implicit none
character(kind=C_CHAR), intent(IN) :: key(*)
character(kind=C_CHAR), intent(IN) :: value(*)
end subroutine c_cali_config_set
subroutine cali_flush(flush_opts) &
bind(C, name="cali_flush")
use iso_c_binding, only : C_INT
implicit none
integer(C_INT), value, intent(IN) :: flush_opts
end subroutine cali_flush
function c_cali_create_attribute(name, type, prop) &
result(SHT_rv) &
bind(C, name="cali_create_attribute")
use iso_c_binding, only : C_CHAR, C_INT
import :: cali_id_t
implicit none
character(kind=C_CHAR), intent(IN) :: name(*)
integer(C_INT), value, intent(IN) :: type
integer(C_INT), value, intent(IN) :: prop
integer(cali_id_t) :: SHT_rv
end function c_cali_create_attribute
function c_cali_find_attribute(name) &
result(SHT_rv) &
bind(C, name="cali_find_attribute")
use iso_c_binding, only : C_CHAR
import :: cali_id_t
implicit none
character(kind=C_CHAR), intent(IN) :: name(*)
integer(cali_id_t) :: SHT_rv
end function c_cali_find_attribute
subroutine cali_begin_int(attr_id, val) &
bind(C, name="cali_begin_int")
use iso_c_binding, only : C_INT
import :: cali_id_t
implicit none
integer(cali_id_t), value, intent(IN) :: attr_id
integer(C_INT), value, intent(IN) :: val
end subroutine cali_begin_int
subroutine c_cali_begin_string(attr_id, val) &
bind(C, name="cali_begin_string")
use iso_c_binding, only : C_CHAR
import :: cali_id_t
implicit none
integer(cali_id_t), value, intent(IN) :: attr_id
character(kind=C_CHAR), intent(IN) :: val(*)
end subroutine c_cali_begin_string
subroutine cali_end(attr_id) &
bind(C, name="cali_end")
import :: cali_id_t
implicit none
integer(cali_id_t), value, intent(IN) :: attr_id
end subroutine cali_end
subroutine c_cali_begin_int_byname(attr_name, val) &
bind(C, name="cali_begin_int_byname")
use iso_c_binding, only : C_CHAR, C_INT
implicit none
character(kind=C_CHAR), intent(IN) :: attr_name(*)
integer(C_INT), value, intent(IN) :: val
end subroutine c_cali_begin_int_byname
subroutine c_cali_begin_string_byname(attr_name, val) &
bind(C, name="cali_begin_string_byname")
use iso_c_binding, only : C_CHAR
implicit none
character(kind=C_CHAR), intent(IN) :: attr_name(*)
character(kind=C_CHAR), intent(IN) :: val(*)
end subroutine c_cali_begin_string_byname
subroutine c_cali_end_byname(attr_name) &
bind(C, name="cali_end_byname")
use iso_c_binding, only : C_CHAR
implicit none
character(kind=C_CHAR), intent(IN) :: attr_name(*)
end subroutine c_cali_end_byname
subroutine c_cali_begin_region(name) &
bind(C, name="cali_begin_region")
use iso_c_binding, only : C_CHAR
implicit none
character(kind=C_CHAR), intent(IN) :: name(*)
end subroutine c_cali_begin_region
subroutine c_cali_end_region(name) &
bind(C, name="cali_end_region")
use iso_c_binding, only : C_CHAR
implicit none
character(kind=C_CHAR), intent(IN) :: name(*)
end subroutine c_cali_end_region
subroutine c_cali_begin_phase(name) &
bind(C, name="cali_begin_phase")
use iso_c_binding, only : C_CHAR
implicit none
character(kind=C_CHAR), intent(IN) :: name(*)
end subroutine c_cali_begin_phase
subroutine c_cali_end_phase(name) &
bind(C, name="cali_end_phase")
use iso_c_binding, only : C_CHAR
implicit none
character(kind=C_CHAR), intent(IN) :: name(*)
end subroutine c_cali_end_phase
function c_cali_make_loop_iteration_attribute(name) &
result(SHT_rv) &
bind(C, name="cali_make_loop_iteration_attribute")
use iso_c_binding, only : C_CHAR
import :: cali_id_t
implicit none
character(kind=C_CHAR), intent(IN) :: name(*)
integer(cali_id_t) :: SHT_rv
end function c_cali_make_loop_iteration_attribute
subroutine c_cali_set_global_int_byname(name, val) &
bind(C, name="cali_set_global_int_byname")
use iso_c_binding, only : C_CHAR, C_INT
implicit none
character(kind=C_CHAR), intent(IN) :: name(*)
integer(C_INT), value, intent(IN) :: val
end subroutine c_cali_set_global_int_byname
subroutine c_cali_set_global_string_byname(name, val) &
bind(C, name="cali_set_global_string_byname")
use iso_c_binding, only : C_CHAR
implicit none
character(kind=C_CHAR), intent(IN) :: name(*)
character(kind=C_CHAR), intent(IN) :: val(*)
end subroutine c_cali_set_global_string_byname
subroutine c_cali_set_global_double_byname(name, val) &
bind(C, name="cali_set_global_double_byname")
use iso_c_binding, only : C_CHAR, C_DOUBLE
implicit none
character(kind=C_CHAR), intent(IN) :: name(*)
real(C_DOUBLE), value, intent(IN) :: val
end subroutine c_cali_set_global_double_byname
end interface
interface annotation
module procedure annotation_new
module procedure annotation_new_with_properties
end interface annotation
interface annotation_begin
module procedure annotation_begin_int
module procedure annotation_begin_string
end interface annotation_begin
interface annotation_set
module procedure annotation_set_int
module procedure annotation_set_string
end interface annotation_set
interface bufferedregionprofile
module procedure bufferedregionprofile_new
end interface bufferedregionprofile
interface configmanager
module procedure configmanager_new
end interface configmanager
interface scopeannotation
module procedure scopeannotation_begin
end interface scopeannotation
interface
! helper copy_string
! Copy the char* or std::string in context into c_var.
subroutine cali_SHROUD_copy_string_and_free(context, c_var, c_var_size) &
bind(c,name="cali_ShroudCopyStringAndFree")
use, intrinsic :: iso_c_binding, only : C_CHAR, C_SIZE_T
import cali_SHROUD_array
type(cali_SHROUD_array), intent(IN) :: context
character(kind=C_CHAR), intent(OUT) :: c_var(*)
integer(C_SIZE_T), value :: c_var_size
end subroutine cali_SHROUD_copy_string_and_free
end interface
! splicer begin additional_declarations
! splicer end additional_declarations
contains
function scopeannotation_begin(name) &
result(SHT_rv)
use iso_c_binding, only : C_NULL_CHAR, C_PTR
character(len=*), intent(IN) :: name
type(scopeannotation) :: SHT_rv
type(C_PTR) :: SHT_prv
! splicer begin class.ScopeAnnotation.method.begin
SHT_prv = c_scopeannotation_begin(trim(name)//C_NULL_CHAR, &
SHT_rv%cxxmem)
! splicer end class.ScopeAnnotation.method.begin
end function scopeannotation_begin
subroutine scopeannotation_end(obj)
class(scopeannotation) :: obj
! splicer begin class.ScopeAnnotation.method.end
call c_scopeannotation_end(obj%cxxmem)
! splicer end class.ScopeAnnotation.method.end
end subroutine scopeannotation_end
! Return pointer to C++ memory.
function scopeannotation_get_instance(obj) result (cxxptr)
use iso_c_binding, only: C_PTR
class(scopeannotation), intent(IN) :: obj
type(C_PTR) :: cxxptr
cxxptr = obj%cxxmem%addr
end function scopeannotation_get_instance
subroutine scopeannotation_set_instance(obj, cxxmem)
use iso_c_binding, only: C_PTR
class(scopeannotation), intent(INOUT) :: obj
type(C_PTR), intent(IN) :: cxxmem
obj%cxxmem%addr = cxxmem
obj%cxxmem%idtor = 0
end subroutine scopeannotation_set_instance
function scopeannotation_associated(obj) result (rv)
use iso_c_binding, only: c_associated
class(scopeannotation), intent(IN) :: obj
logical rv
rv = c_associated(obj%cxxmem%addr)
end function scopeannotation_associated
! splicer begin class.ScopeAnnotation.additional_functions
! splicer end class.ScopeAnnotation.additional_functions
function annotation_new(key) &
result(SHT_rv)
use iso_c_binding, only : C_NULL_CHAR, C_PTR
character(len=*), intent(IN) :: key
type(annotation) :: SHT_rv
type(C_PTR) :: SHT_prv
! splicer begin class.Annotation.method.new
SHT_prv = c_annotation_new(trim(key)//C_NULL_CHAR, &
SHT_rv%cxxmem)
! splicer end class.Annotation.method.new
end function annotation_new
function annotation_new_with_properties(key, properties) &
result(SHT_rv)
use iso_c_binding, only : C_INT, C_NULL_CHAR, C_PTR
character(len=*), intent(IN) :: key
integer(C_INT), value, intent(IN) :: properties
type(annotation) :: SHT_rv
type(C_PTR) :: SHT_prv
! splicer begin class.Annotation.method.new_with_properties
SHT_prv = c_annotation_new_with_properties(trim(key)//C_NULL_CHAR, &
properties, SHT_rv%cxxmem)
! splicer end class.Annotation.method.new_with_properties
end function annotation_new_with_properties
subroutine annotation_delete(obj)
class(annotation) :: obj
! splicer begin class.Annotation.method.delete
call c_annotation_delete(obj%cxxmem)
! splicer end class.Annotation.method.delete
end subroutine annotation_delete
subroutine annotation_begin_int(obj, val)
use iso_c_binding, only : C_INT
class(annotation) :: obj
integer(C_INT), value, intent(IN) :: val
! splicer begin class.Annotation.method.begin_int
call c_annotation_begin_int(obj%cxxmem, val)
! splicer end class.Annotation.method.begin_int
end subroutine annotation_begin_int
subroutine annotation_begin_string(obj, val)
use iso_c_binding, only : C_NULL_CHAR
class(annotation) :: obj
character(len=*), intent(IN) :: val
! splicer begin class.Annotation.method.begin_string
call c_annotation_begin_string(obj%cxxmem, &
trim(val)//C_NULL_CHAR)
! splicer end class.Annotation.method.begin_string
end subroutine annotation_begin_string
subroutine annotation_set_int(obj, val)
use iso_c_binding, only : C_INT
class(annotation) :: obj
integer(C_INT), value, intent(IN) :: val
! splicer begin class.Annotation.method.set_int
call c_annotation_set_int(obj%cxxmem, val)
! splicer end class.Annotation.method.set_int
end subroutine annotation_set_int
subroutine annotation_set_string(obj, val)
use iso_c_binding, only : C_NULL_CHAR
class(annotation) :: obj
character(len=*), intent(IN) :: val
! splicer begin class.Annotation.method.set_string
call c_annotation_set_string(obj%cxxmem, trim(val)//C_NULL_CHAR)
! splicer end class.Annotation.method.set_string
end subroutine annotation_set_string
subroutine annotation_end(obj)
class(annotation) :: obj
! splicer begin class.Annotation.method.end
call c_annotation_end(obj%cxxmem)
! splicer end class.Annotation.method.end
end subroutine annotation_end
! Return pointer to C++ memory.
function annotation_get_instance(obj) result (cxxptr)
use iso_c_binding, only: C_PTR
class(annotation), intent(IN) :: obj
type(C_PTR) :: cxxptr
cxxptr = obj%cxxmem%addr
end function annotation_get_instance
subroutine annotation_set_instance(obj, cxxmem)
use iso_c_binding, only: C_PTR
class(annotation), intent(INOUT) :: obj
type(C_PTR), intent(IN) :: cxxmem
obj%cxxmem%addr = cxxmem
obj%cxxmem%idtor = 0
end subroutine annotation_set_instance
function annotation_associated(obj) result (rv)
use iso_c_binding, only: c_associated
class(annotation), intent(IN) :: obj
logical rv
rv = c_associated(obj%cxxmem%addr)
end function annotation_associated
! splicer begin class.Annotation.additional_functions
! splicer end class.Annotation.additional_functions
function configmanager_new() &
result(SHT_rv)
use iso_c_binding, only : C_PTR
type(configmanager) :: SHT_rv
type(C_PTR) :: SHT_prv
! splicer begin class.ConfigManager.method.new
SHT_prv = c_configmanager_new(SHT_rv%cxxmem)
! splicer end class.ConfigManager.method.new
end function configmanager_new
subroutine configmanager_delete(obj)
class(configmanager) :: obj
! splicer begin class.ConfigManager.method.delete
call c_configmanager_delete(obj%cxxmem)
! splicer end class.ConfigManager.method.delete
end subroutine configmanager_delete
subroutine configmanager_set_default_parameter(obj, option, val)
use iso_c_binding, only : C_NULL_CHAR
class(configmanager) :: obj
character(len=*), intent(IN) :: option
character(len=*), intent(IN) :: val
! splicer begin class.ConfigManager.method.set_default_parameter
call c_configmanager_set_default_parameter(obj%cxxmem, &
trim(option)//C_NULL_CHAR, trim(val)//C_NULL_CHAR)
! splicer end class.ConfigManager.method.set_default_parameter
end subroutine configmanager_set_default_parameter
subroutine configmanager_set_default_parameter_for_config(obj, &
config, option, val)
use iso_c_binding, only : C_NULL_CHAR
class(configmanager) :: obj
character(len=*), intent(IN) :: config
character(len=*), intent(IN) :: option
character(len=*), intent(IN) :: val
! splicer begin class.ConfigManager.method.set_default_parameter_for_config
call c_configmanager_set_default_parameter_for_config(obj%cxxmem, &
trim(config)//C_NULL_CHAR, trim(option)//C_NULL_CHAR, &
trim(val)//C_NULL_CHAR)
! splicer end class.ConfigManager.method.set_default_parameter_for_config
end subroutine configmanager_set_default_parameter_for_config
subroutine configmanager_add_config_spec(obj, spec)
use iso_c_binding, only : C_NULL_CHAR
class(configmanager) :: obj
character(len=*), intent(IN) :: spec
! splicer begin class.ConfigManager.method.add_config_spec
call c_configmanager_add_config_spec(obj%cxxmem, &
trim(spec)//C_NULL_CHAR)
! splicer end class.ConfigManager.method.add_config_spec
end subroutine configmanager_add_config_spec
subroutine configmanager_add_option_spec(obj, spec)
use iso_c_binding, only : C_NULL_CHAR
class(configmanager) :: obj
character(len=*), intent(IN) :: spec
! splicer begin class.ConfigManager.method.add_option_spec
call c_configmanager_add_option_spec(obj%cxxmem, &
trim(spec)//C_NULL_CHAR)
! splicer end class.ConfigManager.method.add_option_spec
end subroutine configmanager_add_option_spec
subroutine configmanager_add(obj, config)
use iso_c_binding, only : C_NULL_CHAR
class(configmanager) :: obj
character(len=*), intent(IN) :: config
! splicer begin class.ConfigManager.method.add
call c_configmanager_add(obj%cxxmem, trim(config)//C_NULL_CHAR)
! splicer end class.ConfigManager.method.add
end subroutine configmanager_add
function configmanager_error(obj) &
result(SHT_rv)
use iso_c_binding, only : C_BOOL
class(configmanager) :: obj
logical :: SHT_rv
! splicer begin class.ConfigManager.method.error
SHT_rv = c_configmanager_error(obj%cxxmem)
! splicer end class.ConfigManager.method.error
end function configmanager_error
function configmanager_error_msg(obj) &
result(SHT_rv)
class(configmanager) :: obj
character(len=:), allocatable :: SHT_rv
! splicer begin class.ConfigManager.method.error_msg
type(cali_SHROUD_array) :: SHT_rv_cdesc
call c_configmanager_error_msg_bufferify(obj%cxxmem, &
SHT_rv_cdesc)
allocate(character(len=SHT_rv_cdesc%elem_len):: SHT_rv)
call cali_SHROUD_copy_string_and_free(SHT_rv_cdesc, SHT_rv, &
SHT_rv_cdesc%elem_len)
! splicer end class.ConfigManager.method.error_msg
end function configmanager_error_msg
subroutine configmanager_start(obj)
class(configmanager) :: obj
! splicer begin class.ConfigManager.method.start
call c_configmanager_start(obj%cxxmem)
! splicer end class.ConfigManager.method.start
end subroutine configmanager_start
subroutine configmanager_stop(obj)
class(configmanager) :: obj
! splicer begin class.ConfigManager.method.stop
call c_configmanager_stop(obj%cxxmem)
! splicer end class.ConfigManager.method.stop
end subroutine configmanager_stop
subroutine configmanager_flush(obj)
class(configmanager) :: obj
! splicer begin class.ConfigManager.method.flush
call c_configmanager_flush(obj%cxxmem)
! splicer end class.ConfigManager.method.flush
end subroutine configmanager_flush
! Return pointer to C++ memory.
function configmanager_get_instance(obj) result (cxxptr)
use iso_c_binding, only: C_PTR
class(configmanager), intent(IN) :: obj
type(C_PTR) :: cxxptr
cxxptr = obj%cxxmem%addr
end function configmanager_get_instance
subroutine configmanager_set_instance(obj, cxxmem)
use iso_c_binding, only: C_PTR
class(configmanager), intent(INOUT) :: obj
type(C_PTR), intent(IN) :: cxxmem
obj%cxxmem%addr = cxxmem
obj%cxxmem%idtor = 0
end subroutine configmanager_set_instance
function configmanager_associated(obj) result (rv)
use iso_c_binding, only: c_associated
class(configmanager), intent(IN) :: obj
logical rv
rv = c_associated(obj%cxxmem%addr)
end function configmanager_associated
! splicer begin class.ConfigManager.additional_functions
! splicer end class.ConfigManager.additional_functions
function bufferedregionprofile_new() &
result(SHT_rv)
use iso_c_binding, only : C_PTR
type(bufferedregionprofile) :: SHT_rv
type(C_PTR) :: SHT_prv
! splicer begin class.BufferedRegionProfile.method.new
SHT_prv = c_bufferedregionprofile_new(SHT_rv%cxxmem)
! splicer end class.BufferedRegionProfile.method.new
end function bufferedregionprofile_new
subroutine bufferedregionprofile_delete(obj)
class(bufferedregionprofile) :: obj
! splicer begin class.BufferedRegionProfile.method.delete
call c_bufferedregionprofile_delete(obj%cxxmem)
! splicer end class.BufferedRegionProfile.method.delete
end subroutine bufferedregionprofile_delete
subroutine bufferedregionprofile_start(obj)
class(bufferedregionprofile) :: obj
! splicer begin class.BufferedRegionProfile.method.start
call c_bufferedregionprofile_start(obj%cxxmem)
! splicer end class.BufferedRegionProfile.method.start
end subroutine bufferedregionprofile_start
subroutine bufferedregionprofile_stop(obj)
class(bufferedregionprofile) :: obj
! splicer begin class.BufferedRegionProfile.method.stop
call c_bufferedregionprofile_stop(obj%cxxmem)
! splicer end class.BufferedRegionProfile.method.stop
end subroutine bufferedregionprofile_stop
subroutine bufferedregionprofile_clear(obj)
class(bufferedregionprofile) :: obj
! splicer begin class.BufferedRegionProfile.method.clear
call c_bufferedregionprofile_clear(obj%cxxmem)
! splicer end class.BufferedRegionProfile.method.clear
end subroutine bufferedregionprofile_clear
subroutine bufferedregionprofile_fetch_exclusive_region_times(obj)
class(bufferedregionprofile) :: obj
! splicer begin class.BufferedRegionProfile.method.fetch_exclusive_region_times
call c_bufferedregionprofile_fetch_exclusive_region_times(obj%cxxmem)
! splicer end class.BufferedRegionProfile.method.fetch_exclusive_region_times
end subroutine bufferedregionprofile_fetch_exclusive_region_times
subroutine bufferedregionprofile_fetch_inclusive_region_times(obj)
class(bufferedregionprofile) :: obj
! splicer begin class.BufferedRegionProfile.method.fetch_inclusive_region_times