[MIPS] Fix setjmp signals
Include full 16-byte Mips sigset_t signal mask within jump buffer.
Call sigprocmask instead of sigblockmask/sigsetmask to get/set full signal mask.
Include sigsetjmp's savesigs arg inside jmp_buf, instead of following it.
Reserve room for future extensions.
Preserve historically-large mips32 _JBLEN size.
Eliminate redundancy: code setjmp and _setjmp as tail calls into sigsetjmp,
and make longjmp and _longjmp aliases of siglongjmp.
Change-Id: Ie79137cf059228c1a51344ebb20d3a9a40b4a252
diff --git a/libc/arch-mips/include/machine/setjmp.h b/libc/arch-mips/include/machine/setjmp.h
index a9707dc..4067d51 100644
--- a/libc/arch-mips/include/machine/setjmp.h
+++ b/libc/arch-mips/include/machine/setjmp.h
@@ -6,9 +6,10 @@
#define _MIPS_SETJMP_H_
#ifdef __LP64__
-#define _JBLEN 22 /* size, in 8-byte longs, of a mips64 jmp_buf */
+#define _JBLEN 25 /* size, in 8-byte longs, of a mips64 jmp_buf/sigjmp_buf */
#else
-#define _JBLEN 29 /* size, in 4-byte longs, of a mips32 jmp_buf */
+#define _JBLEN 157 /* historical size, in 4-byte longs, of a mips32 jmp_buf */
+ /* actual used size is 34 */
#endif
#endif /* !_MIPS_SETJMP_H_ */