summaryrefslogtreecommitdiff
path: root/usr/src/lib/libc/spec/threads.spec
blob: 21e22d308a89f0c2c41a2eafac760ac756b75d84 (plain)
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
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
#
# CDDL HEADER START
#
# The contents of this file are subject to the terms of the
# Common Development and Distribution License (the "License").
# You may not use this file except in compliance with the License.
#
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
# or http://www.opensolaris.org/os/licensing.
# See the License for the specific language governing permissions
# and limitations under the License.
#
# When distributing Covered Code, include this CDDL HEADER in each
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
# If applicable, add the following below this CDDL HEADER, with the
# fields enclosed by brackets "[]" replaced with your own identifying
# information: Portions Copyright [yyyy] [name of copyright owner]
#
# CDDL HEADER END
#
#
# Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
# Use is subject to license terms.
#
# ident	"%Z%%M%	%I%	%E% SMI"
#
# lib/libc/spec/threads.spec

function	pthread_atfork
include		<unistd.h>, <sys/types.h>
declaration	int pthread_atfork(void (*prepare)(void), \
			void (*parent)(void), void (*child)(void))
version		SUNW_1.1
errno		ENOMEM
exception	$return != 0
end

function	pthread_attr_destroy
include		<pthread.h>
declaration	int pthread_attr_destroy(pthread_attr_t *attr)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_getdetachstate
include		<pthread.h>
declaration	int pthread_attr_getdetachstate(const pthread_attr_t *attr, \
			int *detachstate)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_getinheritsched
include		<pthread.h>
declaration	int pthread_attr_getinheritsched( \
			const pthread_attr_t *_RESTRICT_KYWD attr, \
			int *_RESTRICT_KYWD inheritsched)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_getschedparam
include		<pthread.h>
declaration	int pthread_attr_getschedparam( \
			const pthread_attr_t *_RESTRICT_KYWD attr, \
			struct sched_param *_RESTRICT_KYWD param)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_getschedpolicy
include		<pthread.h>
declaration	int pthread_attr_getschedpolicy( \
			const pthread_attr_t *_RESTRICT_KYWD attr, \
			int *_RESTRICT_KYWD policy)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_getscope
include		<pthread.h>
declaration	int pthread_attr_getscope( \
			const pthread_attr_t *_RESTRICT_KYWD attr, \
			int *_RESTRICT_KYWD contentionscope)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_getstack
include		<pthread.h>
declaration	int pthread_attr_getstack( \
			const pthread_attr_t *_RESTRICT_KYWD attr, \
			void **_RESTRICT_KYWD stackaddr, \
			size_t *_RESTRICT_KYWD stacksize)
version		SUNW_1.22
errno		EINVAL
end

function	pthread_attr_getstackaddr
include		<pthread.h>
declaration	int pthread_attr_getstackaddr( \
			const pthread_attr_t *_RESTRICT_KYWD attr, \
			void **_RESTRICT_KYWD stackaddr)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_getstacksize
include		<pthread.h>
declaration	int pthread_attr_getstacksize( \
			const pthread_attr_t *_RESTRICT_KYWD attr, \
			size_t *_RESTRICT_KYWD stacksize)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_init
include		<pthread.h>
declaration	int pthread_attr_init(pthread_attr_t *attr)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_setdetachstate
include		<pthread.h>
declaration	int pthread_attr_setdetachstate(pthread_attr_t *attr, \
			int detachstate)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_setinheritsched
include		<pthread.h>
declaration	int pthread_attr_setinheritsched(pthread_attr_t *attr, \
			int inheritsched)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_setschedparam
include		<pthread.h>
declaration	int pthread_attr_setschedparam( \
			pthread_attr_t *_RESTRICT_KYWD attr, \
			const struct sched_param *_RESTRICT_KYWD param)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_setschedpolicy
include		<pthread.h>
declaration	int pthread_attr_setschedpolicy(pthread_attr_t *attr, \
			int policy)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_setscope
include		<pthread.h>
declaration	int pthread_attr_setscope(pthread_attr_t *attr, \
			int contentionscope)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_setstack
include		<pthread.h>
declaration	int pthread_attr_setstack(pthread_attr_t *attr, \
			void *stackaddr, size_t stacksize)
version		SUNW_1.22
errno		EINVAL
end

function	pthread_attr_setstackaddr
include		<pthread.h>
declaration	int pthread_attr_setstackaddr(pthread_attr_t *attr, \
			void *stackaddr)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_attr_setstacksize
include		<pthread.h>
declaration	int pthread_attr_setstacksize(pthread_attr_t *attr, \
			size_t stacksize)
version		SUNW_1.1
errno		ENOMEM EINVAL ENOTSUP
end

function	pthread_barrierattr_init
include		<pthread.h>
declaration	int pthread_barrierattr_init(pthread_barrierattr_t *attr)
version		SUNW_1.22
exception	$return != 0
end

function	pthread_barrierattr_destroy
include		<pthread.h>
declaration	int pthread_barrierattr_destroy(pthread_barrierattr_t *attr)
version		SUNW_1.22
exception	$return != 0
end

function	pthread_barrierattr_setpshared
include		<pthread.h>
declaration	int pthread_barrierattr_setpshared( \
			pthread_barrierattr_t *attr, int pshared)
version		SUNW_1.22
exception	$return != 0
end

function	pthread_barrierattr_getpshared
include		<pthread.h>
declaration	int pthread_barrierattr_getpshared( \
			const pthread_barrierattr_t *attr, int *pshared)
version		SUNW_1.22
exception	$return != 0
end

function	pthread_barrier_init
include		<pthread.h>
declaration	int pthread_barrier_init(pthread_barrier_t *barrier, \
			const pthread_barrierattr_t *attr, uint_t count)
version		SUNW_1.22
exception	$return != 0
end

function	pthread_barrier_destroy
include		<pthread.h>
declaration	int pthread_barrier_destroy(pthread_barrier_t *barrier)
version		SUNW_1.22
exception	$return != 0
end

function	pthread_barrier_wait
include		<pthread.h>
declaration	int pthread_barrier_wait(pthread_barrier_t *barrier)
version		SUNW_1.22
exception	$return != 0
end

function	pthread_cancel
include		<pthread.h>
declaration	int pthread_cancel(pthread_t target_thread)
version		SUNW_1.1
errno		ESRCH
end

function	pthread_cond_broadcast
include		<pthread.h>
declaration	int pthread_cond_broadcast(pthread_cond_t *cond)
version		SUNW_0.9
errno		EINVAL
end

function	pthread_cond_destroy
include		<pthread.h>
declaration	int pthread_cond_destroy(pthread_cond_t *cond)
version		SUNW_0.9
errno		EBUSY, EINVAL
end

function	pthread_cond_init
include		<pthread.h>
declaration	int pthread_cond_init(pthread_cond_t *_RESTRICT_KYWD cond, \
			const pthread_condattr_t *_RESTRICT_KYWD attr)
version		SUNW_0.9
errno		EAGAIN, ENOMEM, EBUSY, EINVAL
end

function	pthread_cond_signal
include		<pthread.h>
declaration	int pthread_cond_signal(pthread_cond_t *cond)
version		SUNW_0.9
errno		EINVAL
end

function	pthread_cond_timedwait
include		<pthread.h>
declaration	int pthread_cond_timedwait( \
			pthread_cond_t *_RESTRICT_KYWD cond, \
			pthread_mutex_t *_RESTRICT_KYWD mutex, \
			const struct timespec *_RESTRICT_KYWD abstime)
version		SUNW_0.9
errno		ETIMEDOUT, EINVAL
end

function	pthread_cond_reltimedwait_np
include		<pthread.h>
declaration	int pthread_cond_reltimedwait_np(pthread_cond_t *cond, \
			pthread_mutex_t *mutex, const struct timespec *abstime)
version		SUNW_1.21
errno		ETIMEDOUT, EINVAL
end

function	pthread_cond_wait
include		<pthread.h>
declaration	int pthread_cond_wait(pthread_cond_t *_RESTRICT_KYWD cond, \
			pthread_mutex_t *_RESTRICT_KYWD mutex)
version		SUNW_0.9
errno		EINVAL
end

function	pthread_condattr_destroy
include		<pthread.h>
declaration	int pthread_condattr_destroy(pthread_condattr_t *attr)
version		SUNW_0.9
errno		ENOMEM EINVAL
end

function	pthread_condattr_getclock
include		<pthread.h>
declaration	int pthread_condattr_getclock( \
			const pthread_condattr_t *attr, clockid_t *clock_id)
version		SUNW_1.22
errno		EINVAL
end

function	pthread_condattr_getpshared
include		<pthread.h>
declaration	int pthread_condattr_getpshared( \
			const pthread_condattr_t *_RESTRICT_KYWD attr, \
			int *_RESTRICT_KYWD process_shared)
version		SUNW_0.9
errno		ENOMEM EINVAL
end

function	pthread_condattr_init
include		<pthread.h>
declaration	int pthread_condattr_init(pthread_condattr_t *attr)
version		SUNW_0.9
errno		ENOMEM EINVAL
end

function	pthread_condattr_setclock
include		<pthread.h>
declaration	int pthread_condattr_setclock( \
			pthread_condattr_t *attr, clockid_t clock_id)
version		SUNW_1.22
errno		EINVAL
end

function	pthread_condattr_setpshared
include		<pthread.h>
declaration	int pthread_condattr_setpshared(pthread_condattr_t *attr, \
			int process_shared)
version		SUNW_0.9
errno		ENOMEM EINVAL
end

function	pthread_create
include		<pthread.h>
declaration	int pthread_create(pthread_t *_RESTRICT_KYWD thread, \
			const pthread_attr_t *_RESTRICT_KYWD attr, \
			void *(*start_routine)(void*), \
			void *_RESTRICT_KYWD arg)
version		SUNW_1.1
errno		EAGAIN EINVAL ENOMEM
end

function	pthread_detach
include		<pthread.h>
declaration	int pthread_detach(pthread_t tid)
version		SUNW_1.1
errno		EINVAL ESRCH
end

function	pthread_equal
include		<pthread.h>
declaration	int pthread_equal(pthread_t t1, pthread_t t2)
version		SUNW_1.1
end

function	pthread_exit
include		<pthread.h>
declaration	void pthread_exit(void *status)
version		SUNW_1.1
end

function	pthread_getschedparam
include		<pthread.h>, <sched.h>
declaration	int pthread_getschedparam(pthread_t tid, \
			int *_RESTRICT_KYWD policy, \
			struct sched_param *_RESTRICT_KYWD param)
version		SUNW_1.1
errno		ESRCH ENOTSUP EINVAL
end

function	pthread_getspecific
include		<pthread.h>
declaration	void *pthread_getspecific(pthread_key_t key)
version		SUNW_1.1
end

function	pthread_join
include		<pthread.h>
declaration	int pthread_join(pthread_t tid, void **status)
version		SUNW_1.1
errno		ESRCH EDEADLK
end

function	pthread_key_create
include		<pthread.h>
declaration	int pthread_key_create(pthread_key_t *keyp, \
			void (*destructor)(void *))
version		SUNW_1.1
errno		EAGAIN ENOMEM EINVAL
end

function	pthread_key_delete
include		<pthread.h>
declaration	int pthread_key_delete(pthread_key_t key)
version		SUNW_1.1
errno		EAGAIN ENOMEM EINVAL
end

function	pthread_kill
include		<pthread.h>, <signal.h>
declaration	int pthread_kill(pthread_t tid, int signo)
version		SUNW_1.1
errno		ESRCH EINVAL
end

function	pthread_mutex_destroy
include		<pthread.h>
declaration	int pthread_mutex_destroy(pthread_mutex_t *mutex)
version		SUNW_0.9
errno		EBUSY, EINVAL
end

function	pthread_mutex_getprioceiling
include		<pthread.h>
declaration	int pthread_mutex_getprioceiling( \
			const pthread_mutex_t *_RESTRICT_KYWD mutex, \
			int *_RESTRICT_KYWD prioceiling)
version		SUNW_0.9
end

function	pthread_mutex_init
include		<pthread.h>
declaration	int pthread_mutex_init(pthread_mutex_t *_RESTRICT_KYWD mutex, \
			const pthread_mutexattr_t *_RESTRICT_KYWD attr)
version		SUNW_0.9
errno		EAGAIN, ENOMEM, EBUSY, EPERM, EINVAL
end

function	pthread_mutex_lock
include		<pthread.h>
declaration	int pthread_mutex_lock(pthread_mutex_t *mutex)
version		SUNW_0.9
errno		EINVAL, EDEADLK
end

function	pthread_mutex_setprioceiling
include		<pthread.h>
declaration	int pthread_mutex_setprioceiling( \
			pthread_mutex_t *_RESTRICT_KYWD mutex, \
			int prioceiling, int *_RESTRICT_KYWD old_ceiling)
version		SUNW_0.9
end

function	pthread_mutex_trylock
include		<pthread.h>
declaration	int pthread_mutex_trylock(pthread_mutex_t *mutex)
version		SUNW_0.9
errno		EINVAL, EBUSY
end

function	pthread_mutex_unlock
include		<pthread.h>
declaration	int pthread_mutex_unlock(pthread_mutex_t *mutex)
version		SUNW_0.9
errno		EINVAL, EPERM
end

function	pthread_mutexattr_destroy
include		<pthread.h>
declaration	int pthread_mutexattr_destroy(pthread_mutexattr_t *attr)
version		SUNW_0.9
errno		ENOMEM EINVAL ENOSYS
end

function	pthread_mutexattr_getprioceiling
include		<pthread.h>
declaration	int pthread_mutexattr_getprioceiling( \
			const pthread_mutexattr_t *_RESTRICT_KYWD attr, \
			int *_RESTRICT_KYWD prioceiling)
version		SUNW_0.9
end

function	pthread_mutexattr_getprotocol
include		<pthread.h>, <sched.h>
declaration	int pthread_mutexattr_getprotocol( \
			const pthread_mutexattr_t *_RESTRICT_KYWD attr, \
			int *_RESTRICT_KYWD protocol)
version		SUNW_0.9
end

function	pthread_mutexattr_getpshared
include		<pthread.h>
declaration	int pthread_mutexattr_getpshared( \
			const pthread_mutexattr_t *_RESTRICT_KYWD attr, \
			int *_RESTRICT_KYWD process_shared)
version		SUNW_0.9
errno		ENOMEM EINVAL ENOSYS
end

function	pthread_mutexattr_init
include		<pthread.h>
declaration	int pthread_mutexattr_init(pthread_mutexattr_t *attr)
version		SUNW_0.9
errno		ENOMEM EINVAL ENOSYS
end

function	pthread_mutexattr_setprotocol
include		<pthread.h>, <sched.h>
declaration	int pthread_mutexattr_setprotocol(pthread_mutexattr_t *attr, \
			int protocol)
version		SUNW_0.9
end

function	pthread_mutexattr_setpshared
include		<pthread.h>
declaration	int pthread_mutexattr_setpshared(pthread_mutexattr_t *attr, \
			int process_shared)
version		SUNW_0.9
errno		ENOMEM EINVAL ENOSYS
end

function	pthread_once
include		<pthread.h>
declaration	int pthread_once(pthread_once_t *once_control, \
			void (*init_routine)(void))
version		SUNW_1.1
errno		EINVAL
end

function	pthread_self
include		<pthread.h>
declaration	pthread_t pthread_self(void)
version		SUNW_1.1
end

function	pthread_setcancelstate
include		<pthread.h>
declaration	int pthread_setcancelstate(int state, int *oldstate)
version		SUNW_1.1
errno		EINVAL
end

function	pthread_setcanceltype
include		<pthread.h>
declaration	int pthread_setcanceltype(int type, int *oldtype)
version		SUNW_1.1
errno		EINVAL
end

function	pthread_setschedparam
include		<pthread.h>, <sched.h>
declaration	int pthread_setschedparam(pthread_t tid, int policy, \
			const struct sched_param *param)
version		SUNW_1.1
errno		ESRCH ENOTSUP EINVAL EPERM
end

function	pthread_setschedprio
include		<pthread.h>
declaration	int pthread_setschedprio(pthread_t tid, int prio)
version		SUNW_1.22
errno		ESRCH ENOTSUP EINVAL EPERM
end

function	pthread_setspecific
include		<pthread.h>
declaration	int pthread_setspecific(pthread_key_t key, const void *value)
version		SUNW_1.1
errno		ENOMEM EINVAL
end

function	pthread_sigmask
include		<pthread.h>, <signal.h>
declaration	int pthread_sigmask(int how, \
			const sigset_t *_RESTRICT_KYWD newmask, \
			sigset_t *_RESTRICT_KYWD oldmask)
version		SUNW_1.1
errno		EINVAL EFAULT
end

function	pthread_testcancel
include		<pthread.h>
declaration	void pthread_testcancel(void)
version		SUNW_1.1
end

function	pthread_mutex_timedlock
include		<pthread.h>, <time.h>
declaration	int pthread_mutex_timedlock(pthread_mutex_t *mutex, \
			const timespec_t *abstime)
version		SUNW_1.22
errno		EINVAL, ETIMEDOUT
end

function	pthread_mutex_reltimedlock_np
include		<pthread.h>, <time.h>
declaration	int pthread_mutex_reltimedlock_np(pthread_mutex_t *mutex, \
			const timespec_t *reltime)
version		SUNW_1.22
errno		EINVAL, ETIMEDOUT
end

function	pthread_mutexattr_setrobust_np
include		<pthread.h>
declaration	int pthread_mutexattr_setrobust_np(pthread_mutexattr_t *attr, \
			int robustness)
version		SUNW_1.22
errno		ENOTSUP EINVAL ENOSYS
exception	$return != 0
end

function	pthread_mutexattr_getrobust_np 
include		<pthread.h>
declaration	int pthread_mutexattr_getrobust_np( \
			const pthread_mutexattr_t *attr, int *robustness)
version		SUNW_1.22
errno		ENOTSUP EINVAL ENOSYS
exception	$return != 0
end

function	pthread_mutex_consistent_np
include		<pthread.h>
declaration	int pthread_mutex_consistent_np(pthread_mutex_t *mp)
version		SUNW_1.22
errno		EINVAL ENOSYS
exception	$return != 0
end

function	pthread_spin_init
include		<pthread.h>
declaration	int pthread_spin_init(pthread_spinlock_t *lock, int pshared)
version		SUNW_1.22
exception	$return != 0
end

function	pthread_spin_destroy
include		<pthread.h>
declaration	int pthread_spin_destroy(pthread_spinlock_t *lock)
version		SUNW_1.22
exception	$return != 0
end

function	pthread_spin_trylock
include		<pthread.h>
declaration	int pthread_spin_trylock(pthread_spinlock_t *lock)
version		SUNW_1.22
exception	$return != 0
end

function	pthread_spin_lock
include		<pthread.h>
declaration	int pthread_spin_lock(pthread_spinlock_t *lock)
version		SUNW_1.22
exception	$return != 0
end

function	pthread_spin_unlock
include		<pthread.h>
declaration	int pthread_spin_unlock(pthread_spinlock_t *lock)
version		SUNW_1.22
exception	$return != 0
end

function	schedctl_init
include		<schedctl.h>
declaration	schedctl_t *schedctl_init(void)
version		SUNW_1.22
end

function	_schedctl_init
weak		schedctl_init
version		SUNWprivate_1.1
end

function	schedctl_lookup
include		<schedctl.h>
declaration	schedctl_t *schedctl_lookup(void)
version		SUNW_1.22
end

function	_schedctl_lookup
weak		schedctl_lookup
version		SUNWprivate_1.1
end

function	schedctl_exit
include		<schedctl.h>
declaration	void schedctl_exit(void)
version		SUNW_1.22
end

function	_schedctl_exit
weak		schedctl_exit
version		SUNWprivate_1.1
end

function	thr_continue
include		<thread.h>
declaration	int thr_continue(thread_t tid)
version		SUNW_0.8
end

function	thr_create
include		<thread.h>
declaration	int thr_create(void *stack_base, size_t stack_size, \
			void *(*start_func)(void *), void *arg, long flags, \
			thread_t *new_thread_ID)
version		SUNW_0.8
end

function	thr_exit
include		<thread.h>
declaration	void thr_exit(void *status)
version		SUNW_0.8
end

function	thr_getconcurrency
include		<thread.h>
declaration	int thr_getconcurrency(void)
version		SUNW_0.8
end

function	thr_getprio
include		<thread.h>
declaration	int thr_getprio(thread_t tid, int *priop)
version		SUNW_0.8
end

function	thr_getspecific
include		<thread.h>
declaration	int thr_getspecific(thread_key_t key, void **valuep)
version		SUNW_0.8
end

function	thr_join
include		<thread.h>
declaration	int thr_join(thread_t tid, thread_t *dtidp, void **statusp)
version		SUNW_0.8
end

function	thr_keycreate
include		<thread.h>
declaration	int thr_keycreate(thread_key_t *keyp, \
			void (*destructor)(void *value))
version		SUNW_0.8
end

function	thr_kill
include		<thread.h>, <signal.h>
declaration	int thr_kill(thread_t tid, int signo)
version		SUNW_0.8
end

function	thr_main
include		<thread.h>
declaration	int thr_main(void)
version		SUNW_1.1
errno
end

function	thr_min_stack
include		<thread.h>
declaration	size_t thr_min_stack(void)
version		SUNW_0.9
end

function	thr_self
include		<thread.h>
declaration	thread_t thr_self(void)
version		SUNW_0.8
end

function	thr_setconcurrency
include		<thread.h>
declaration	int thr_setconcurrency(int level)
version		SUNW_0.8
end

function	thr_setprio
include		<thread.h>
declaration	int thr_setprio(thread_t tid, int prio)
version		SUNW_0.8
end

function	thr_setspecific
include		<thread.h>
declaration	int thr_setspecific(thread_key_t key, void *value)
version		SUNW_0.8
end

function	thr_sigsetmask
include		<thread.h>, <signal.h>
declaration	int thr_sigsetmask(int how, const sigset_t *newp, \
			sigset_t *oldp)
version		SUNW_0.8
end

function	thr_stksegment
include		<thread.h>, <sys/signal.h>
declaration	int thr_stksegment(stack_t *sp)
version		SUNW_0.9
errno		EFAULT EAGAIN
end

function	thr_suspend
include		<thread.h>
declaration	int thr_suspend(thread_t tid)
version		SUNW_0.8
end

function	thr_yield
include		<thread.h>
declaration	void thr_yield(void)
version		SUNW_0.8
end

data		thr_probe_getfunc_addr
version		SUNWprivate_1.1
end

function	thr_probe_setup
version		SUNWprivate_1.1
end		

function	_pthread_mutexattr_setrobust_np
weak		pthread_mutexattr_setrobust_np
version		SUNWprivate_1.1
end

function	_pthread_mutexattr_getrobust_np
weak		pthread_mutexattr_getrobust_np
version		SUNWprivate_1.1
end

function	_pthread_mutex_consistent_np
weak		pthread_mutex_consistent_np
version		SUNWprivate_1.1
end

function	_pthread_setcleanupinit
version		SUNWprivate_1.1
end

function	__pthread_min_stack
version		SUNWprivate_1.1
end

function	lwp_self
version		SUNWprivate_1.1
end		

function	_thr_continue_allmutators
version		SUNWprivate_1.1
end		

function	_thr_continue_mutator
version		SUNWprivate_1.1
end		

function	_thr_getstate
version		SUNWprivate_1.1
end		

function	_thr_mutators_barrier
version		SUNWprivate_1.1
end		

function	_thr_setmutator
version		SUNWprivate_1.1
end		

function	_thr_setstate
version		SUNWprivate_1.1
end		

function	_thr_sighndlrinfo
version		SUNWprivate_1.1
end		

function	_thr_suspend_allmutators
version		SUNWprivate_1.1
end		

function	_thr_suspend_mutator
version		SUNWprivate_1.1
end		

function	_thr_wait_mutator
version		SUNWprivate_1.1
end		

function	thr_continue_allmutators
version		SUNWprivate_1.1
end		

function	thr_continue_mutator
version		SUNWprivate_1.1
end		

function	thr_getstate
version		SUNWprivate_1.1
end		

function	thr_mutators_barrier
version		SUNWprivate_1.1
end		

function	thr_setmutator
version		SUNWprivate_1.1
end		

function	thr_setstate
version		SUNWprivate_1.1
end		

function	thr_sighndlrinfo
version		SUNWprivate_1.1
end		

function	thr_suspend_allmutators
version		SUNWprivate_1.1
end		

function	thr_suspend_mutator
version		SUNWprivate_1.1
end		

function	thr_wait_mutator
version		SUNWprivate_1.1
end		

function	__gettsp
version		SUNWprivate_1.1
end		

function	_assfail
version		SUNWprivate_1.1
end		

function	__tls_get_addr
version		SUNWprivate_1.1
end		

function	___tls_get_addr
arch		i386
version		i386=SUNWprivate_1.1
end		

function	_sigoff
version		SUNWprivate_1.1
end

function	_sigon
version		SUNWprivate_1.1
end

function	_thr_detach
version		SUNWprivate_1.1
end		

function	_thr_key_delete
version		SUNWprivate_1.1
end		

function	_thr_schedctl
version		SUNWprivate_1.1
end		

function	_thr_slot_offset
version		SUNWprivate_1.1
end		

function	_resume
version		SUNWprivate_1.1
end

function	_resume_ret
version		SUNWprivate_1.1
end

function	posix_spawn
include		<spawn.h>
declaration	int posix_spawn( \
			pid_t *, \
			const char *, \
			const posix_spawn_file_actions_t *, \
			const posix_spawnattr_t *, \
			char *const [], \
			char *const [])
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnp
include		<spawn.h>
declaration	int posix_spawnp( \
			pid_t *, \
			const char *, \
			const posix_spawn_file_actions_t *, \
			const posix_spawnattr_t *attrp, \
			char *const [], \
			char *const [])
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawn_file_actions_init
include		<spawn.h>
declaration	int posix_spawn_file_actions_init( \
			posix_spawn_file_actions_t *)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawn_file_actions_destroy
include		<spawn.h>
declaration	int posix_spawn_file_actions_destroy( \
			posix_spawn_file_actions_t *)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawn_file_actions_addopen
include		<spawn.h>
declaration	int posix_spawn_file_actions_addopen( \
			posix_spawn_file_actions_t *, \
			int, \
			const char *, \
			int, \
			mode_t)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawn_file_actions_addclose
include		<spawn.h>
declaration	int posix_spawn_file_actions_addclose( \
			posix_spawn_file_actions_t *, \
			int)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawn_file_actions_adddup2
include		<spawn.h>
declaration	int posix_spawn_file_actions_adddup2( \
			posix_spawn_file_actions_t *, \
			int, \
			int)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_init
include		<spawn.h>
declaration	int posix_spawnattr_init( \
			posix_spawnattr_t *)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_destroy
include		<spawn.h>
declaration	int posix_spawnattr_destroy( \
			posix_spawnattr_t *)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_setflags
include		<spawn.h>
declaration	int posix_spawnattr_setflags( \
			posix_spawnattr_t *, \
			short)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_getflags
include		<spawn.h>
declaration	int posix_spawnattr_getflags( \
			const posix_spawnattr_t *, \
			short *)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_setpgroup
include		<spawn.h>
declaration	int posix_spawnattr_setpgroup( \
			posix_spawnattr_t *, \
			pid_t)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_getpgroup
include		<spawn.h>
declaration	int posix_spawnattr_getpgroup( \
			const posix_spawnattr_t *, \
			pid_t *)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_setschedparam
include		<spawn.h>
declaration	int posix_spawnattr_setschedparam( \
			posix_spawnattr_t *, \
			const struct sched_param *)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_getschedparam
include		<spawn.h>
declaration	int posix_spawnattr_getschedparam( \
			const posix_spawnattr_t *, \
			struct sched_param *)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_setschedpolicy
include		<spawn.h>
declaration	int posix_spawnattr_setschedpolicy( \
			posix_spawnattr_t *, \
			int)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_getschedpolicy
include		<spawn.h>
declaration	int posix_spawnattr_getschedpolicy( \
			const posix_spawnattr_t *, \
			int *)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_setsigdefault
include		<spawn.h>
declaration	int posix_spawnattr_setsigdefault( \
			posix_spawnattr_t *, \
			const sigset_t *)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_getsigdefault
include		<spawn.h>
declaration	int posix_spawnattr_getsigdefault( \
			const posix_spawnattr_t *, \
			sigset_t *)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_setsigmask
include		<spawn.h>
declaration	int posix_spawnattr_setsigmask( \
			posix_spawnattr_t *, \
			const sigset_t *)
version		SUNW_1.22
exception	$return != 0
end

function	posix_spawnattr_getsigmask
include		<spawn.h>
declaration	int posix_spawnattr_getsigmask( \
			const posix_spawnattr_t *, \
			sigset_t *)
version		SUNW_1.22
exception	$return != 0
end

function	_posix_spawn
weak		posix_spawn
version		SUNWprivate_1.1
end

function	_posix_spawnp
weak		posix_spawnp
version		SUNWprivate_1.1
end

function	_posix_spawn_file_actions_init
weak		posix_spawn_file_actions_init
version		SUNWprivate_1.1
end

function	_posix_spawn_file_actions_destroy
weak		posix_spawn_file_actions_destroy
version		SUNWprivate_1.1
end

function	_posix_spawn_file_actions_addopen
weak		posix_spawn_file_actions_addopen
version		SUNWprivate_1.1
end

function	_posix_spawn_file_actions_addclose
weak		posix_spawn_file_actions_addclose
version		SUNWprivate_1.1
end

function	_posix_spawn_file_actions_adddup2
weak		posix_spawn_file_actions_adddup2
version		SUNWprivate_1.1
end

function	_posix_spawnattr_init
weak		posix_spawnattr_init
version		SUNWprivate_1.1
end

function	_posix_spawnattr_destroy
weak		posix_spawnattr_destroy
version		SUNWprivate_1.1
end

function	_posix_spawnattr_setflags
weak		posix_spawnattr_setflags
version		SUNWprivate_1.1
end

function	_posix_spawnattr_getflags
weak		posix_spawnattr_getflags
version		SUNWprivate_1.1
end

function	_posix_spawnattr_setpgroup
weak		posix_spawnattr_setpgroup
version		SUNWprivate_1.1
end

function	_posix_spawnattr_getpgroup
weak		posix_spawnattr_getpgroup
version		SUNWprivate_1.1
end

function	_posix_spawnattr_setschedparam
weak		posix_spawnattr_setschedparam
version		SUNWprivate_1.1
end

function	_posix_spawnattr_getschedparam
weak		posix_spawnattr_getschedparam
version		SUNWprivate_1.1
end

function	_posix_spawnattr_setschedpolicy
weak		posix_spawnattr_setschedpolicy
version		SUNWprivate_1.1
end

function	_posix_spawnattr_getschedpolicy
weak		posix_spawnattr_getschedpolicy
version		SUNWprivate_1.1
end

function	_posix_spawnattr_setsigdefault
weak		posix_spawnattr_setsigdefault
version		SUNWprivate_1.1
end

function	_posix_spawnattr_getsigdefault
weak		posix_spawnattr_getsigdefault
version		SUNWprivate_1.1
end

function	_posix_spawnattr_setsigmask
weak		posix_spawnattr_setsigmask
version		SUNWprivate_1.1
end

function	_posix_spawnattr_getsigmask
weak		posix_spawnattr_getsigmask
version		SUNWprivate_1.1
end