projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[project @ 2003-08-20 15:06:23 by simonmar]
[ghc-hetmet.git]
/
ghc
/
rts
/
RtsUtils.c
diff --git
a/ghc/rts/RtsUtils.c
b/ghc/rts/RtsUtils.c
index
b31b87e
..
8f6579c
100644
(file)
--- a/
ghc/rts/RtsUtils.c
+++ b/
ghc/rts/RtsUtils.c
@@
-1,5
+1,5
@@
/* -----------------------------------------------------------------------------
/* -----------------------------------------------------------------------------
- * $Id: RtsUtils.c,v 1.31 2003/03/25 17:24:30 sof Exp $
+ * $Id: RtsUtils.c,v 1.34 2003/04/01 15:40:27 sof Exp $
*
* (c) The GHC Team, 1998-2002
*
*
* (c) The GHC Team, 1998-2002
*
@@
-109,18
+109,6
@@
stgReallocBytes (void *p, int n, char *msg)
}
void *
}
void *
-stgMallocWords (int n, char *msg)
-{
- return(stgMallocBytes(n * sizeof(W_), msg));
-}
-
-void *
-stgReallocWords (void *p, int n, char *msg)
-{
- return(stgReallocBytes(p, n * sizeof(W_), msg));
-}
-
-void *
stgCallocBytes (int n, int m, char *msg)
{
int i;
stgCallocBytes (int n, int m, char *msg)
{
int i;
@@
-130,6
+118,15
@@
stgCallocBytes (int n, int m, char *msg)
return p;
}
return p;
}
+/* To simplify changing the underlying allocator used
+ * by stgMallocBytes(), provide stgFree() as well.
+ */
+void
+stgFree(void* p)
+{
+ free(p);
+}
+
void
_stgAssert (char *filename, unsigned int linenum)
{
void
_stgAssert (char *filename, unsigned int linenum)
{
@@
-255,7
+252,9
@@
setNonBlockingFd(int fd)
fcntl(fd, F_SETFL, fd_flags | O_NONBLOCK);
}
#else
fcntl(fd, F_SETFL, fd_flags | O_NONBLOCK);
}
#else
-/* Don't support non-blocking FDs (yet) on mingw */
+/* Stub defns -- async / non-blocking IO is not done
+ * via O_NONBLOCK and select() under Win32.
+ */
void resetNonBlockingFd(int fd STG_UNUSED) {}
void setNonBlockingFd(int fd STG_UNUSED) {}
#endif
void resetNonBlockingFd(int fd STG_UNUSED) {}
void setNonBlockingFd(int fd STG_UNUSED) {}
#endif