From 63fd7f747915e38a5553bbcb55939d5e483445c7 Mon Sep 17 00:00:00 2001 From: deischen Date: Wed, 30 Apr 2003 15:05:17 +0000 Subject: Move the mailbox to the beginning of the thread and align the thread so that the context (SSE FPU state) is also aligned. --- lib/libkse/thread/thr_create.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'lib/libkse/thread/thr_create.c') diff --git a/lib/libkse/thread/thr_create.c b/lib/libkse/thread/thr_create.c index 4c65d3c..0c9edbd 100644 --- a/lib/libkse/thread/thr_create.c +++ b/lib/libkse/thread/thr_create.c @@ -97,6 +97,7 @@ _pthread_create(pthread_t * thread, const pthread_attr_t * attr, struct pthread *curthread, *new_thread; struct kse *kse = NULL; struct kse_group *kseg = NULL; + void *p; kse_critical_t crit; int i; int ret = 0; @@ -123,7 +124,9 @@ _pthread_create(pthread_t * thread, const pthread_attr_t * attr, ret = EAGAIN; } else { /* Initialize the thread structure: */ + p = new_thread->alloc_addr; memset(new_thread, 0, sizeof(struct pthread)); + new_thread->alloc_addr = p; /* Check if default thread attributes are required: */ if (attr == NULL || *attr == NULL) -- cgit v1.1