Skip to content

Commit ba7cba6

Browse files
committed
Remove pthread_attr_getscope, which is optional
This is part of the "TPS" Thread Execution Scheduling functionality, and the corresponding set function is already not provided
1 parent 424e7eb commit ba7cba6

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

expected/wasm32-wasip1-threads/defined-symbols.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -987,7 +987,6 @@ pthread_attr_destroy
987987
pthread_attr_getdetachstate
988988
pthread_attr_getguardsize
989989
pthread_attr_getschedparam
990-
pthread_attr_getscope
991990
pthread_attr_getstack
992991
pthread_attr_getstacksize
993992
pthread_attr_init

libc-top-half/musl/src/thread/pthread_attr_get.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,12 @@ int pthread_attr_getschedpolicy(const pthread_attr_t *restrict a, int *restrict
2929
*policy = a->_a_policy;
3030
return 0;
3131
}
32+
33+
int pthread_attr_getscope(const pthread_attr_t *restrict a, int *restrict scope)
34+
{
35+
*scope = PTHREAD_SCOPE_SYSTEM;
36+
return 0;
37+
}
3238
#else
3339
int pthread_attr_getschedparam(const pthread_attr_t *restrict a, struct sched_param *restrict param)
3440
{
@@ -37,12 +43,6 @@ int pthread_attr_getschedparam(const pthread_attr_t *restrict a, struct sched_pa
3743
}
3844
#endif
3945

40-
int pthread_attr_getscope(const pthread_attr_t *restrict a, int *restrict scope)
41-
{
42-
*scope = PTHREAD_SCOPE_SYSTEM;
43-
return 0;
44-
}
45-
4646
int pthread_attr_getstack(const pthread_attr_t *restrict a, void **restrict addr, size_t *restrict size)
4747
{
4848
if (!a->_a_stackaddr)

0 commit comments

Comments
 (0)