[PATCH 2/2] jmpbuf: Add paddings for target specific usage
Florian Weimer
fweimer@redhat.com
Mon Nov 13 13:09:00 GMT 2017
On 11/08/2017 07:27 PM, H.J. Lu wrote:
> +/* The biggest signal number + 1 */
> +#define _JUMP_BUF_SIGSET_NSIG 257
> +/* Number of longs to hold all signals. */
> +#define _JUMP_BUF_SIGSET_NWORDS \
> + ((_JUMP_BUF_SIGSET_NSIG - 1 + 7) / (8 * sizeof (unsigned long int)))
Where does 257 come from? 65 or 129 I would understand considering the
kernel sources, but 257 is odd.
I think it would be clearer to hard-code the array sizes and explain why
the values where chosen in that way.
We also need a test that setprocmask does not read from the previously
unused part. I can move the existing next_to_fault bits to support/ if
that would help.
Thanks,
Florian
More information about the Libc-alpha
mailing list