]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
* sysdeps/s390/fpu/fegetenv.c (fegetenv): Remove PTRACE_PEEKUSER
authorUlrich Drepper <drepper@redhat.com>
Mon, 24 Mar 2008 20:01:15 +0000 (20:01 +0000)
committerUlrich Drepper <drepper@redhat.com>
Mon, 24 Mar 2008 20:01:15 +0000 (20:01 +0000)
ptrace call to get the ieee_instruction_pointer from the kernel.
* sysdeps/s390/fpu/fesetenv.c (fesetenv): Remove PTRACE_POKEUSER
ptrace call to set the ieee_instructtion_pointer.
* sysdeps/unix/sysv/linux/s390/sys/user.h (struct _user_regs_struct):
Add comment that ieee_instruction_pointer is always 0.

ChangeLog
sysdeps/s390/fpu/fegetenv.c
sysdeps/s390/fpu/fesetenv.c
sysdeps/unix/sysv/linux/s390/sys/user.h

index 80ee942ef7844cdd51ce3a4c544738ebc2dd8440..185955fe19b0b370d7a4b5e5eb54341f4e5717e2 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2008-03-07  Martin Schwidefsky  <schwidefsky@de.ibm.com>
+
+       * sysdeps/s390/fpu/fegetenv.c (fegetenv): Remove PTRACE_PEEKUSER
+       ptrace call to get the ieee_instruction_pointer from the kernel.
+       * sysdeps/s390/fpu/fesetenv.c (fesetenv): Remove PTRACE_POKEUSER
+       ptrace call to set the ieee_instructtion_pointer.
+       * sysdeps/unix/sysv/linux/s390/sys/user.h (struct _user_regs_struct):
+       Add comment that ieee_instruction_pointer is always 0.
+
 2008-03-09  Andreas Jaeger  <aj@suse.de>
 
        [BZ #5857]
index b35a76a4e8278383062e897027af980bc8e1db46..a244f2ca8b1431130250770491a72538fa622faf 100644 (file)
@@ -1,5 +1,5 @@
 /* Store current floating-point environment.
-   Copyright (C) 2000, 2003 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2008 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Denis Joseph Barrow (djbarrow@de.ibm.com).
 
 int
 fegetenv (fenv_t *envp)
 {
-  /* The S/390 IEEE fpu doesn't keep track of the ieee instruction pointer.
-     To get around that the kernel will store the address of the last
-     fpu fault to the process structure. This ptrace call reads this value
-     from the kernel space. That means the ieee_instruction_pointer is
-     only correct after a fpu fault. That's the best we can do, there is
-     no way to find out the ieee instruction pointer if there was no fault.  */
   _FPU_GETCW (envp->fpc);
-  envp->ieee_instruction_pointer =
-    (void *) ptrace (PTRACE_PEEKUSER, getpid (), PT_IEEE_IP);
 
   /* Success.  */
   return 0;
index bb71c95a1effd9eaf9fc7c088375416c708cb91c..82555c49484334cca957d38309b6a46dc9bb8dba 100644 (file)
@@ -1,5 +1,5 @@
 /* Install given floating-point environment.
-   Copyright (C) 2000, 2002 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2008 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Denis Joseph Barrow (djbarrow@de.ibm.com).
 
@@ -43,13 +43,7 @@ fesetenv (const fenv_t *envp)
   else
     env = (*envp);
 
-  /* The S/390 IEEE fpu doesn't have a register for the ieee
-     instruction pointer. The operating system is required to keep an
-     instruction pointer on a per process base. We read and write this
-     value with the ptrace interface.  */
   _FPU_SETCW (env.fpc);
-  ptrace (PTRACE_POKEUSER, getpid (), PT_IEEE_IP,
-         env.ieee_instruction_pointer);
 
   /* Success.  */
   return 0;
index f00caea84dc0fab4b665f46a4dd10884fee487f9..cd3e60cf0db3160d4536d6ba0044df6216868095 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2000,2005 Free Software Foundation, Inc.
+/* Copyright (C) 2000,2008 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
@@ -56,7 +56,7 @@ struct _user_regs_struct
   unsigned long orig_gpr2;             /* Original gpr2.  */
   struct _user_fpregs_struct fp_regs;  /* Floating point registers.  */
   struct _user_per_struct per_info;    /* Hardware tracing registers.  */
-  unsigned long ieee_instruction_pointer; 
+  unsigned long ieee_instruction_pointer;      /* Always 0.  */
 };
 
 struct user {