PRE_MEM_RASCIIZ( "quotactl(special)", arg2 );
}
-// XXX: this is only suitable for 32-bit platforms
+// XXX: this wrapper is only suitable for 32-bit platforms
PREx(sys_lookup_dcookie, 0)
{
PRINT("sys_lookup_dcookie (0x%llx, %p, %d)", LOHI64(arg1,arg2), arg3, arg4);
POST_MEM_WRITE( arg3, res);
}
-PRE(truncate64)
-{
- PRINT("truncate64 ( %p, %lld )", arg1, LOHI64(arg2, arg3));
- PRE_MEM_RASCIIZ( "truncate64(path)", arg1 );
-}
-
PRE(fdatasync)
{
/* int fdatasync(int fd); */
PRINT("fsync ( %d )", arg1);
}
-PRE(ftruncate)
+PREx(sys_ftruncate, MayBlock)
+{
+ PRINT("sys_ftruncate ( %d, %lld )", arg1,(ULong)arg2);
+ PRE_REG_READ2(long, "ftruncate", unsigned int, fd, unsigned long, length);
+}
+
+PREx(sys_truncate, MayBlock)
+{
+ PRINT("sys_truncate ( %p(%s), %d )", arg1,arg1,arg2);
+ PRE_REG_READ2(long, "truncate",
+ const char *, path, unsigned long, length);
+ PRE_MEM_RASCIIZ( "truncate(path)", arg1 );
+}
+
+// XXX: this wrapper is only suitable for 32-bit platforms
+PREx(sys_ftruncate64, MayBlock)
{
- /* int ftruncate(int fd, size_t length); */
- PRINT("ftruncate ( %d, %lld )", arg1,(ULong)arg2);
+ PRINT("sys_ftruncate64 ( %d, %lld )", arg1, LOHI64(arg2,arg3));
+ PRE_REG_READ3(long, "ftruncate64",
+ unsigned int, fd,
+ vki_u32, length_low32, vki_u32, length_high32);
}
-PRE(ftruncate64)
+// XXX: this wrapper is only suitable for 32-bit platforms
+PREx(sys_truncate64, MayBlock)
{
- /* int ftruncate64(int fd, off64_t length); */
- PRINT("ftruncate64 ( %d, %lld )", arg1, LOHI64(arg2,arg3));
+ PRINT("sys_truncate64 ( %p, %lld )", arg1, LOHI64(arg2, arg3));
+ PRE_REG_READ3(long, "truncate64",
+ const char *, path,
+ vki_u32, length_low32, vki_u32, length_high32);
+ PRE_MEM_RASCIIZ( "truncate64(path)", arg1 );
}
+
PRE(getdents)
{
/* int getdents(unsigned int fd, struct dirent *dirp,
POST_MEM_WRITE( arg2, sizeof(struct epoll_event)*res ) ;
}
-PRE(readlink)
+PREx(sys_readlink, 0)
{
- /* int readlink(const char *path, char *buf, size_t bufsiz); */
- PRINT("readlink ( %p, %p, %llu )", arg1,arg2,(ULong)arg3);
+ PRINT("sys_readlink ( %p, %p, %llu )", arg1,arg2,(ULong)arg3);
+ PRE_REG_READ3(long, "readlink",
+ const char *, path, char *, buf, int, bufsiz);
PRE_MEM_RASCIIZ( "readlink(path)", arg1 );
PRE_MEM_WRITE( "readlink(buf)", arg2,arg3 );
}
-POST(readlink)
+POSTx(sys_readlink)
{
POST_MEM_WRITE( arg2, res );
}
POST_MEM_WRITE( arg3, arg2 );
}
-PRE(symlink)
+PREx(sys_symlink, MayBlock)
{
- /* int symlink(const char *oldpath, const char *newpath); */
- PRINT("symlink ( %p, %p )",arg1,arg2);
+ PRINT("sys_symlink ( %p, %p )",arg1,arg2);
+ PRE_REG_READ2(long, "symlink", const char *, oldpath, const char *, newpath);
PRE_MEM_RASCIIZ( "symlink(oldpath)", arg1 );
PRE_MEM_RASCIIZ( "symlink(newpath)", arg2 );
}
}
}
-PRE(truncate)
-{
- /* int truncate(const char *path, off_t length); */
- PRINT("truncate ( %p(%s), %d )", arg1,arg1,arg2);
- PRE_MEM_RASCIIZ( "truncate(path)", arg1 );
-}
-
PREx(sys_umask, 0)
{
PRINT("sys_umask ( %d )", arg1);
SYSXY(__NR_getgroups, sys_getgroups16), // 80 ## P
SYSX_(__NR_setgroups, sys_setgroups16), // 81 ## almost-P
SYSX_(__NR_select, old_select), // 82 (x86) (4.4BSD)
- SYSB_(__NR_symlink, sys_symlink, MayBlock), // 83 *
+ SYSX_(__NR_symlink, sys_symlink), // 83 * P
// (__NR_oldlstat, sys_lstat), // 84 * L -- obsolete
- SYSBA(__NR_readlink, sys_readlink, 0), // 85 *
+ SYSXY(__NR_readlink, sys_readlink), // 85 * (X/OPEN,4.4BSD)
// (__NR_uselib, sys_uselib), // 86 * L
// (__NR_swapon, sys_swapon), // 87 * L
// (__NR_reboot, sys_reboot), // 88 * L
SYSB_(__NR_mmap, old_mmap, Special), // 90 old_mmap
SYSBA(__NR_munmap, sys_munmap, 0), // 91 *
- SYSB_(__NR_truncate, sys_truncate, MayBlock), // 92 *
- SYSB_(__NR_ftruncate, sys_ftruncate, MayBlock), // 93 *
+ SYSX_(__NR_truncate, sys_truncate), // 92 * P
+ SYSX_(__NR_ftruncate, sys_ftruncate), // 93 * P
SYSB_(__NR_fchmod, sys_fchmod, 0), // 94 *
SYSX_(__NR_fchown, sys_fchown16), // 95 ## (SVr4,BSD4.3)
// (__NR_vfork, sys_vfork), // 190 -- Valgrind avoids
SYSXY(__NR_ugetrlimit, sys_getrlimit), // 191 * (?)
SYSBA(__NR_mmap2, sys_mmap2, 0), // 192
- SYSB_(__NR_truncate64, sys_truncate64, MayBlock), // 193 %%
- SYSB_(__NR_ftruncate64, sys_ftruncate64, MayBlock), // 194 %%
+ SYSX_(__NR_truncate64, sys_truncate64), // 193 %% (P?)
+ SYSX_(__NR_ftruncate64, sys_ftruncate64), // 194 %% (P?)
SYSXY(__NR_stat64, sys_stat64), // 195 %% (?)
SYSXY(__NR_lstat64, sys_lstat64), // 196 %% (?)
SY(__NR_select, args+x0);
}
- // __NR_symlink 83
- //GO(__NR_symlink, ".s .m");
- //SY(__NR_symlink);
+ // __NR_symlink 83 --> sys_symlink()
+ GO(__NR_symlink, "2s 2m");
+ SY(__NR_symlink, x0, x0);
// __NR_oldlstat 84
// (obsolete, not handled by Valgrind)
// __NR_readlink 85
- //GO(__NR_readlink, ".s .m");
- //SY(__NR_readlink);
+ GO(__NR_readlink, "3s 2m");
+ SY(__NR_readlink);
// __NR_uselib 86
// (Not yet handled by Valgrind)
//GO(__NR_munmap, ".s .m");
//SY(__NR_munmap);
- // __NR_truncate 92
- //GO(__NR_truncate, ".s .m");
- //SY(__NR_truncate);
+ // __NR_truncate 92 --> sys_truncate()
+ GO(__NR_truncate, "2s 1m");
+ SY(__NR_truncate, x0, x0);
- // __NR_ftruncate 93
- //GO(__NR_ftruncate, ".s .m");
- //SY(__NR_ftruncate);
+ // __NR_ftruncate 93 --> sys_ftruncate()
+ GO(__NR_ftruncate, "2s 0m");
+ SY(__NR_ftruncate, x0, x0);
// __NR_fchmod 94
//GO(__NR_fchmod, ".s .m");
//GO(__NR_mmap2, ".s .m");
//SY(__NR_mmap2);
- // __NR_truncate64 193
- //GO(__NR_truncate64, ".s .m");
- //SY(__NR_truncate64);
+ // __NR_truncate64 193 --> sys_truncate64()
+ GO(__NR_truncate64, "3s 1m");
+ SY(__NR_truncate64, x0, x0, x0);
- // __NR_ftruncate64 194
- //GO(__NR_ftruncate64, ".s .m");
- //SY(__NR_ftruncate64);
+ // __NR_ftruncate64 194 --> sys_ftruncate64()
+ GO(__NR_ftruncate64, "3s 0m");
+ SY(__NR_ftruncate64, x0, x0, x0);
// __NR_stat64 195
GO(__NR_stat64, "2s 2m");
by 0x........: __libc_start_main (...libc...)
by 0x........: ...
Address 0x........ is not stack'd, malloc'd or (recently) free'd
+-----------------------------------------------------
+ 83: __NR_symlink 2s 2m
+-----------------------------------------------------
+
+Syscall param symlink(oldpath) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param symlink(newpath) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param symlink(oldpath) points to unaddressable byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+ Address 0x........ is not stack'd, malloc'd or (recently) free'd
+
+Syscall param symlink(newpath) points to unaddressable byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+ Address 0x........ is not stack'd, malloc'd or (recently) free'd
+-----------------------------------------------------
+ 85: __NR_readlink 3s 2m
+-----------------------------------------------------
+
+Syscall param readlink(path) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param readlink(buf) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param readlink(bufsiz) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param readlink(path) points to unaddressable byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+ Address 0x........ is not stack'd, malloc'd or (recently) free'd
+
+Syscall param readlink(buf) points to unaddressable byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+ Address 0x........ is not stack'd, malloc'd or (recently) free'd
+-----------------------------------------------------
+ 92: __NR_truncate 2s 1m
+-----------------------------------------------------
+
+Syscall param truncate(path) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param truncate(length) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param truncate(path) points to unaddressable byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+ Address 0x........ is not stack'd, malloc'd or (recently) free'd
+-----------------------------------------------------
+ 93: __NR_ftruncate 2s 0m
+-----------------------------------------------------
+
+Syscall param ftruncate(fd) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param ftruncate(length) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
-----------------------------------------------------
95: __NR_fchown 3s 0m
-----------------------------------------------------
by 0x........: ...
Address 0x........ is not stack'd, malloc'd or (recently) free'd
-----------------------------------------------------
+193: __NR_truncate64 3s 1m
+-----------------------------------------------------
+
+Syscall param truncate64(path) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param truncate64(length_low32) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param truncate64(length_high32) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param truncate64(path) points to unaddressable byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+ Address 0x........ is not stack'd, malloc'd or (recently) free'd
+-----------------------------------------------------
+194: __NR_ftruncate64 3s 0m
+-----------------------------------------------------
+
+Syscall param ftruncate64(fd) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param ftruncate64(length_low32) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+
+Syscall param ftruncate64(length_high32) contains uninitialised byte(s)
+ at 0x........: syscall (in /...libc...)
+ by 0x........: __libc_start_main (...libc...)
+ by 0x........: ...
+-----------------------------------------------------
195: __NR_stat64 2s 2m
-----------------------------------------------------