about summary refs log tree commit diff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2004-11-25 06:25:42 +0000
committerUlrich Drepper <drepper@redhat.com>2004-11-25 06:25:42 +0000
commitbca2d208314bdb10486d165c4ac1c19edcf594ce (patch)
tree596074daa66dbbc5b0d9ea7c6a1a828b6163e142
parentf1f2cafcd4c23ac4f4077b78fbddff1ffea8b951 (diff)
downloadglibc-bca2d208314bdb10486d165c4ac1c19edcf594ce.tar.gz
glibc-bca2d208314bdb10486d165c4ac1c19edcf594ce.tar.xz
glibc-bca2d208314bdb10486d165c4ac1c19edcf594ce.zip
Update.
	* sysdeps/x86_64/Makefile [nptl]: Define CFLAGS-pthread_create.c.
-rw-r--r--nptl/ChangeLog2
-rw-r--r--nptl/allocatestack.c2
-rw-r--r--nptl/sysdeps/x86_64/Makefile9
3 files changed, 11 insertions, 2 deletions
diff --git a/nptl/ChangeLog b/nptl/ChangeLog
index 5957f616b4..efe1235107 100644
--- a/nptl/ChangeLog
+++ b/nptl/ChangeLog
@@ -1,5 +1,7 @@
 2004-11-24  Ulrich Drepper  <drepper@redhat.com>
 
+	* sysdeps/x86_64/Makefile [nptl]: Define CFLAGS-pthread_create.c.
+
 	* Makefile (libpthread-routines): Add pthread_setschedprio.
 	* Versions [libpthread, GLIBC_2.3.4]: Add pthread_setschedprio.
 	* sysdeps/pthread/pthread.h: Declare pthread_setschedprio.
diff --git a/nptl/allocatestack.c b/nptl/allocatestack.c
index 89a034e0ec..8875209a11 100644
--- a/nptl/allocatestack.c
+++ b/nptl/allocatestack.c
@@ -417,7 +417,7 @@ allocate_stack (const struct pthread_attr *attr, struct pthread **pdp,
       pd = get_cached_stack (&size, &mem);
       if (pd == NULL)
 	{
-	  /* To avoid aliasing effects on a larger scale then pages we
+	  /* To avoid aliasing effects on a larger scale than pages we
 	     adjust the allocated stack size if necessary.  This way
 	     allocations directly following each other will not have
 	     aliasing problems.  */
diff --git a/nptl/sysdeps/x86_64/Makefile b/nptl/sysdeps/x86_64/Makefile
index 24990a2b7e..6e24a26cde 100644
--- a/nptl/sysdeps/x86_64/Makefile
+++ b/nptl/sysdeps/x86_64/Makefile
@@ -1,4 +1,4 @@
-# Copyright (C) 2002, 2003 Free Software Foundation, Inc.
+# Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc.
 # This file is part of the GNU C Library.
 
 # The GNU C Library is free software; you can redistribute it and/or
@@ -19,3 +19,10 @@
 ifeq ($(subdir),csu)
 gen-as-const-headers += tcb-offsets.sym
 endif
+
+ifeq ($(subdir),nptl)
+# P4s have problems with 4M aliasing.  We disturb the allocation of stacks
+# just enough so the subsequent allocations do not use stack address
+# (mod 4M) == 0.
+CFLAGS-pthread_create.c += -DMULTI_PAGE_ALIASING=65536
+endif