|
From: Nicholas N. <nj...@ca...> - 2004-11-18 13:34:03
|
CVS commit by nethercote: Added missing .cvsignore file. A .cvsignore 1.1 |
|
From: Jeremy F. <je...@go...> - 2005-01-15 02:08:55
|
CVS commit by fitzhardinge:
Add a missing thread-creation track.
M +9 -7 core_os.c 1.5
--- valgrind/coregrind/linux/core_os.c #1.4:1.5
@@ -40,4 +40,6 @@ void VGA_(thread_wrapper)(ThreadId tid)
}
+ VG_TRACK ( post_thread_create, tst->os_state.parent, tid );
+
tst->os_state.lwpid = VG_(gettid)();
tst->os_state.threadgroup = VG_(getpid)();
|
|
From: Jeremy F. <je...@go...> - 2005-01-19 09:42:09
|
CVS commit by fitzhardinge:
Close the old semaphore pipe before creating a new one.
BUG: 97407
M +4 -0 sema.c 1.2
--- valgrind/coregrind/linux/sema.c #1.1:1.2
@@ -58,4 +58,8 @@ void VG_(sema_init)(vg_sema_t *sema)
void VG_(sema_init)(vg_sema_t *sema)
{
+ if (sema->pipe[0] >= VG_(fd_hard_limit)) {
+ VG_(close)(sema->pipe[0]);
+ VG_(close)(sema->pipe[1]);
+ }
VG_(pipe)(sema->pipe);
sema->pipe[0] = VG_(safe_fd)(sema->pipe[0]);
|
|
From: Jeremy F. <je...@go...> - 2005-03-15 01:25:01
|
CVS commit by fitzhardinge:
sys_futex's FUTEX_(CMP_)REQUEUE requests use the futex2 pointer (not
timeout); FUTEX_CMP_REQUEUE also uses the timespec pointer as an integer.
Also, more clearly document the argument usages, and make the per-operation
special cases clearer.
M +33 -5 syscalls.c 1.9
--- valgrind/coregrind/linux/syscalls.c #1.8:1.9
@@ -413,13 +413,41 @@ POST(sys_sendfile64)
PRE(sys_futex, MayBlock)
{
+ /*
+ arg param used by ops
+
+ arg1 - u32 *futex all
+ arg2 - int op
+ arg3 - int val WAIT,WAKE,FD,REQUEUE,CMP_REQUEUE
+ arg4 - struct timespec *utime WAIT:time* REQUEUE,CMP_REQUEUE:val2
+ arg5 - u32 *uaddr2 REQUEUE,CMP_REQUEUE
+ arg6 - int val3 CMP_REQUEUE
+ */
PRINT("sys_futex ( %p, %d, %d, %p, %p )", arg1,arg2,arg3,arg4,arg5);
PRE_REG_READ6(long, "futex",
vki_u32 *, futex, int, op, int, val,
struct timespec *, utime, vki_u32 *, uaddr2, int, val3);
- SYS_PRE_MEM_READ( "futex(futex)", arg1, sizeof(int) );
- if (arg2 == VKI_FUTEX_WAIT && arg4 != 0)
+
+ SYS_PRE_MEM_READ( "futex(futex)", arg1, sizeof(Int) );
+
+ switch(arg2) {
+ case VKI_FUTEX_WAIT:
+ if (arg4 != 0)
SYS_PRE_MEM_READ( "futex(timeout)", arg4, sizeof(struct vki_timespec) );
- if (arg2 == VKI_FUTEX_REQUEUE)
- SYS_PRE_MEM_READ( "futex(futex2)", arg4, sizeof(int) );
+ break;
+
+ case VKI_FUTEX_REQUEUE:
+ case VKI_FUTEX_CMP_REQUEUE:
+ SYS_PRE_MEM_READ( "futex(futex2)", arg5, sizeof(Int) );
+ break;
+
+ case VKI_FUTEX_WAKE:
+ case VKI_FUTEX_FD:
+ /* no additional pointers */
+ break;
+
+ default:
+ set_result(-VKI_ENOSYS); // some futex function we don't understand
+ break;
+ }
}
|
|
From: Dirk M. <mu...@kd...> - 2005-07-28 20:20:12
|
SVN commit 439751 by mueller:
fix fadvise64 syscalls, backport from 3.0
M +12 -6 syscalls.c =20
--- trunk/valgrind/coregrind/linux/syscalls.c #439750:439751
@@ -55,6 +55,8 @@
#define VG_ROUNDDN( p, a ) ( ( Addr )( p ) & ~( ( Addr )( a )-1 ) )
#define VG_ROUNDUP( p, a ) VG_ROUNDDN( ( p )+( a )-1, ( a ) )
=20
+#define LOHI64( lo,hi ) ( ( lo ) | ( ( ULong )( hi ) << 32 ) )
+
#define PRINT(format, args...) \
if (VG_(clo_trace_syscalls)) \
VG_(printf)(format, ## args)
@@ -516,16 +518,20 @@
=20
PRE(sys_fadvise64, 0)
{
- PRINT("sys_fadvise64 ( %d, %lld, %lu, %d )", arg1,arg2,arg3);
- PRE_REG_READ4(long, "fadvise64",
- int, fd, vki_loff_t, offset, vki_size_t, len, int, advi=
ce)
+ PRINT("sys_fadvise64 ( %d, %lld, %lu, %d )",
+ arg1, LOHI64(arg2,arg3), arg4, arg5);
+ PRE_REG_READ5(long, "fadvise64",
+ int, fd, vki_u32, offset_low, vki_u32, offset_high,
+ vki_size_t, len, int, advice);
}
=20
PRE(sys_fadvise64_64, 0)
{
- PRINT("sys_fadvise64_64 ( %d, %lld, %lld, %d )", arg1,arg2,arg3);
- PRE_REG_READ4(long, "fadvise64_64",
- int, fd, vki_loff_t, offset, vki_loff_t, len, int, advi=
ce)
+ PRINT("sys_fadvise64_64 ( %d, %lld, %lld, %d )",
+ arg1, LOHI64(arg2,arg3), LOHI64(arg4,arg5), arg6);
+ PRE_REG_READ6(long, "fadvise64_64",
+ int, fd, vki_u32, offset_low, vki_u32, offset_high,
+ vki_u32, len_low, vki_u32, len_high, int, advice);
}
=20
PRE(sys_set_mempolicy, 0)
|