|
From: <sv...@va...> - 2006-10-17 12:49:40
|
Author: sewardj
Date: 2006-10-17 13:49:31 +0100 (Tue, 17 Oct 2006)
New Revision: 6308
Log:
AIX build fixes.
Modified:
trunk/coregrind/m_libcfile.c
trunk/perf/ffbench.c
Modified: trunk/coregrind/m_libcfile.c
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- trunk/coregrind/m_libcfile.c 2006-10-17 11:33:23 UTC (rev 6307)
+++ trunk/coregrind/m_libcfile.c 2006-10-17 12:49:31 UTC (rev 6308)
@@ -31,6 +31,7 @@
#include "pub_core_basics.h"
#include "pub_core_vki.h"
#include "pub_core_vkiscnums.h"
+#include "pub_core_debuglog.h"
#include "pub_core_libcbase.h"
#include "pub_core_libcassert.h"
#include "pub_core_libcfile.h"
@@ -291,13 +292,17 @@
/* returns: 0 =3D success, non-0 is failure */
Int VG_(check_executable)(HChar* f)
{
-#ifdef __NR_stat64
+ /* This is something of a kludge. Really we should fix VG_(stat) to
+ do this itself, but not clear how to do it as it depends on
+ having a 'struct vki_stat64' which is different from 'struct
+ vki_stat'. */
+# if defined(VGO_linux) && defined(__NR_stat64)
struct vki_stat64 st;
SysRes res =3D VG_(do_syscall2)(__NR_stat64, (UWord)f, (UWord)&st);
-#else
+# else
struct vki_stat st;
- SysRes res =3D VG_(do_syscall2)(__NR_stat, (UWord)f, (UWord)&st);
-#endif
+ SysRes res =3D VG_(stat)(f, &st);
+# endif
=20
if (res.isError) {
return res.err;
Modified: trunk/perf/ffbench.c
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- trunk/perf/ffbench.c 2006-10-17 11:33:23 UTC (rev 6307)
+++ trunk/perf/ffbench.c 2006-10-17 12:49:31 UTC (rev 6308)
@@ -155,16 +155,6 @@
#define max(a,b) ((a)>(b)?(a):(b))
#define min(a,b) ((a)<=3D(b)?(a):(b))
=20
-#ifndef unix
-#ifndef WIN32
-extern char *farmalloc(long s);
-#define malloc(x) farmalloc(x)
-#endif
-#define FWMODE "wb"
-#else
-#define FWMODE "w"
-#endif
-
/*
=20
Multi-dimensional fast Fourier transform
|