simplify pthread_attr_t stack/guard size representation
authorRich Felker <dalias@aerifal.cx>
Tue, 8 Nov 2016 01:47:24 +0000 (20:47 -0500)
committerRich Felker <dalias@aerifal.cx>
Tue, 8 Nov 2016 01:47:24 +0000 (20:47 -0500)
commit33ce920857405d4f4b342c85b74588a15e2702e5
tree54c7c840b40b68aa52f68a0a69c9e61b9ac4c388
parent7442442ccc665641a8827177e8e7ed45bbbd6584
simplify pthread_attr_t stack/guard size representation

previously, the pthread_attr_t object was always initialized all-zero,
and stack/guard size were represented as differences versus their
defaults. this required lots of confusing offset arithmetic everywhere
they were used. instead, have pthread_attr_init fill in the default
values, and work with absolute sizes everywhere.
src/thread/pthread_attr_get.c
src/thread/pthread_attr_init.c
src/thread/pthread_attr_setguardsize.c
src/thread/pthread_attr_setstack.c
src/thread/pthread_attr_setstacksize.c
src/thread/pthread_create.c
src/thread/pthread_getattr_np.c