Comment 7 for bug 688404

Revision history for this message
Vladimir Kolesnikov (vkolesnikov) wrote :

Vladislav,

thanks for your patch, however may I ask you to try something else (I don't have a 64-bit windows setup, so I cannot try it myself).

The idea is to force alignment of the jump buffer. Paul suggested that if we put jmp_buf into a union with an integer that should force the whole union to be aligned. Here;s the patch:

=== modified file 'src/thread_xt.h'
--- src/thread_xt.h 2010-02-02 10:06:03 +0000
+++ src/thread_xt.h 2010-12-13 09:01:57 +0000
@@ -153,7 +153,10 @@
 typedef struct XTJumpBuf {
        XTResourcePtr jb_res_top;
        int jb_call_top;
- jmp_buf jb_buffer;
+ union {
+ int jb_aligner;
+ jmp_buf jb_buffer;
+ };
 } XTJumpBufRec, *XTJumpBufPtr;

 typedef struct XTCallStack {

Can you try it please?