This is the mail archive of the
mailing list for the newlib project.
[patch, libgloss, mips] Add unlink, lseek, stat functions.
- From: "Steve Ellcey " <sellcey at mips dot com>
- To: <newlib at sourceware dot org>
- Date: Tue, 9 Jul 2013 16:13:39 -0700
- Subject: [patch, libgloss, mips] Add unlink, lseek, stat functions.
A while back I sent some email about adding ftruncate and chsize to libgloss
in order to fix some Fortran test failures I was getting when running the
GCC Fortran testsuite under the MIPS GNU simulator. I have since realized that
while I may need those functions my more immediate problem was that some of
the system calls already defined in libgloss/syscall.h were not implemented
in the MIPS GNU simulator. Specifically many tests failed due to a lack of
unlink, lseek, and stat. This patch adds specially defined function
definitions for these entry points to the MIPS libgloss so that they can be
intercepted by the GNU simulator. I have a second patch that I will submit
to gdb that actually implements the functionality in the simulator. This
patch just makes sure that they are seen by the simulator so that it can
intercept and implement them. Note that the numbers used in the definitions
do not match syscall.h and do not need to, they just need to match the
case statement in the GNU simulator that implements each of the calls.
OK for checkin?
2013-07-09 Steve Ellcey <firstname.lastname@example.org>
* mips/idtmon.S (unlink, lseek, stat): Add new functions.
diff --git a/libgloss/mips/idtmon.S b/libgloss/mips/idtmon.S
index bb15388..304aaa4 100644
@@ -39,6 +39,9 @@ INDIRECT(write,8)
INDIRECT(get_mem_info,55) /* expects pointer to three word vector */