>> > * bootstraptest/test_thread.rb: Skip 2 tests. The first one appears toang, the second crashes with a sigaltstack error.
>>
>> signalstack error seems because of the lack of OpenBSD specific setting.
>> see thread_pthread.c:506 and edit it.
>
> I don't think the problem is there, as reading the documentation the callhere (pthread_stackseg_np(pthread_self(), &stk)) appears to be correct.        >
> 39 newSS.ss_sp = th->altstack = malloc(ALT_STACK_SIZE);
> 40 if (newSS.ss_sp == NULL)
> 41 /* should handle error */
> 42 rb_bug("rb_register_sigaltstack. malloc error\n");
>
> If you change the rb_bug call to a return, the 2nd bootstrap test passes.A0I'm not sure if that's a valid fix, as it probably affects signal handling for the thread.             ɧ           Ĭ      Į

I wonder why OpenBSD can't allocate SIGSTKSZ size. Usually it's very small.
Can you please tell us openbsd has which value of SIGSTKSZ and MINSIGSTKSZ?

Also, can you please try following stack size reducing patch?

Index: signal.c
===================================================================
--- signal.c	(revision 32646)
+++ signal.c	(working copy)
@@ -423,10 +423,12 @@
 #ifdef POSIX_SIGNAL

 #ifdef USE_SIGALTSTACK
-#ifdef SIGSTKSZ
-#define ALT_STACK_SIZE (SIGSTKSZ*2)
-#else
-#define ALT_STACK_SIZE (4*1024)
+ #if defined(__OpenBSD__)
+  #define ALT_STACK_SIZE (4*1024)
+  //#define ALT_STACK_SIZE (MINSIGSTKSZ*2)
+ #elif defined(SIGSTKSZ)
+  #define ALT_STACK_SIZE (SIGSTKSZ*2)
+ #else
+  #define ALT_STACK_SIZE (4*1024)
 #endif
 /* alternate stack for SIGSEGV */
 void