|
From: Dirk M. <mu...@kd...> - 2005-02-27 14:03:29
|
CVS commit by mueller:
revert my last commits
M +16 -17 coregrind/x86/core_arch.h 1.26
M +107 -108 include/x86-linux/vki_arch.h 1.15
M +4 -4 include/x86-linux/vki_arch_posixtypes.h 1.5
--- valgrind/coregrind/x86/core_arch.h #1.25:1.26
@@ -32,6 +32,6 @@
#define __X86_CORE_ARCH_H
-#include "core_arch_asm.h"
-#include "tool_arch.h"
+#include "core_arch_asm.h" // arch-specific asm stuff
+#include "tool_arch.h" // arch-specific tool stuff
/* ---------------------------------------------------------------------
@@ -39,5 +39,5 @@
------------------------------------------------------------------ */
-/* Accessors for the arch_thread_t */
+// Accessors for the arch_thread_t
#define ARCH_INSTR_PTR(regs) ((regs).m_eip)
#define ARCH_STACK_PTR(regs) ((regs).m_esp)
@@ -65,19 +65,19 @@
#define ARCH_CLREQ_RET(regs) ((regs).m_edx)
-/* Accessors for the ThreadState */
+// Accessors for the ThreadState
#define R_CLREQ_RET R_EDX
#define R_PTHREQ_RET R_EDX
-/* Stack frame layout and linkage */
+// Stack frame layout and linkage
#define FIRST_STACK_FRAME(ebp) (ebp)
#define STACK_FRAME_RET(ebp) (((UWord*)ebp)[1])
#define STACK_FRAME_NEXT(ebp) (((UWord*)ebp)[0])
-/* Offsets of interesting registers */
+// Offsets of interesting registers
#define VGOFF_INSTR_PTR VGOFF_(m_eip)
#define VGOFF_STACK_PTR VGOFF_(m_esp)
#define VGOFF_FRAME_PTR VGOFF_(m_ebp)
-/* Get stack pointer and frame pointer */
+// Get stack pointer and frame pointer
#define ARCH_GET_REAL_STACK_PTR(esp) do { \
asm("movl %%esp, %0" : "=r" (esp)); \
@@ -164,5 +164,5 @@ extern const Char VG_(helper_cmpxchg8b)[
------------------------------------------------------------------ */
-/* XXX: eventually this will be x86-private, not seen by the core(?) */
+// XXX: eventually this will be x86-private, not seen by the core(?)
/* This is the hardware-format for a segment descriptor, ie what the
@@ -197,11 +197,11 @@ typedef struct _LDT_ENTRY {
------------------------------------------------------------------ */
-/* Total number of spill slots available for register allocation. */
+// Total number of spill slots available for register allocation.
#define VG_MAX_SPILLSLOTS 24
-/* Valgrind's stack size, in words. */
+// Valgrind's stack size, in words.
#define VG_STACK_SIZE_W 16384
-/* Base address of client address space. */
+// Base address of client address space.
#define CLIENT_BASE 0x00000000ul
@@ -255,9 +255,8 @@ struct i387_fxsave_struct {
-/* Architecture-specific part of a ThreadState
- XXX: eventually this should be made abstract, ie. the fields not visible
- to the core... then VgLdtEntry can be made non-visible to the core
- also.
-*/
+// Architecture-specific part of a ThreadState
+// XXX: eventually this should be made abstract, ie. the fields not visible
+// to the core... then VgLdtEntry can be made non-visible to the core
+// also.
typedef struct {
/* Saved machine context. Note the FPU state, %EIP and segment
@@ -333,5 +332,5 @@ arch_thread_t;
void VGA_(signal_return)(ThreadId tid, Bool isRT);
-#endif /* __X86_CORE_ARCH_H */
+#endif // __X86_CORE_ARCH_H
/*--------------------------------------------------------------------*/
--- valgrind/include/x86-linux/vki_arch.h #1.14:1.15
@@ -32,10 +32,10 @@
#define __X86_LINUX_VKI_ARCH_H
-/* x86 is little-endian. */
+// x86 is little-endian.
#define VKI_LITTLE_ENDIAN 1
-/*----------------------------------------------------------------------*/
-/* From linux-2.6.8.1/include/asm-i386/types.h */
-/*----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/types.h
+//----------------------------------------------------------------------
typedef unsigned char __vki_u8;
@@ -53,7 +53,7 @@ typedef unsigned short vki_u16;
typedef unsigned int vki_u32;
-/*----------------------------------------------------------------------*/
-/* From linux-2.6.8.1/include/asm-i386/page.h */
-/*----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/page.h
+//----------------------------------------------------------------------
/* PAGE_SHIFT determines the page size */
@@ -61,7 +61,7 @@ typedef unsigned int vki_u32;
#define VKI_PAGE_SIZE (1UL << VKI_PAGE_SHIFT)
-/*----------------------------------------------------------------------*/
-/* From linux-2.6.8.1/include/asm-i386/signal.h */
-/*----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/signal.h
+//----------------------------------------------------------------------
#define VKI_MINSIGSTKSZ 2048
@@ -81,5 +81,5 @@ typedef __vki_restorefn_t __user *__vki_
#define VKI_SIG_IGN ((__vki_sighandler_t)1) /* ignore signal */
-/*#ifdef __KERNEL__*/
+//#ifdef __KERNEL__
/* Most things should be clean enough to redefine this at will, if care
is taken to make libc match. */
@@ -94,5 +94,5 @@ typedef struct {
unsigned long sig[_VKI_NSIG_WORDS];
} vki_sigset_t;
-/*#endif*/
+//#endif
#define VKI_SIGHUP 1
@@ -102,5 +102,5 @@ typedef struct {
#define VKI_SIGTRAP 5
#define VKI_SIGABRT 6
-/*#define VKI_SIGIOT 6*/
+//#define VKI_SIGIOT 6
#define VKI_SIGBUS 7
#define VKI_SIGFPE 8
@@ -132,11 +132,11 @@ typedef struct {
/* These should not be considered constants from userland. */
#define VKI_SIGRTMIN 32
-/* [[This was (_NSIG-1) in 2.4.X... not sure if it matters.]] */
+// [[This was (_NSIG-1) in 2.4.X... not sure if it matters.]]
#define VKI_SIGRTMAX _VKI_NSIG
/* Use high signals because native pthreads wants to use low */
-#define VKI_SIGVGKILL (VG_(max_signal)-0) /* [[internal: kill]] */
-#define VKI_SIGVGCHLD (VG_(max_signal)-1) /* [[internal: thread death]] */
-#define VKI_SIGVGRTUSERMAX (VG_(max_signal)-2) /* [[internal: last user-usable RT signal]] */
+#define VKI_SIGVGKILL (VG_(max_signal)-0) // [[internal: kill]]
+#define VKI_SIGVGCHLD (VG_(max_signal)-1) // [[internal: thread death]]
+#define VKI_SIGVGRTUSERMAX (VG_(max_signal)-2) // [[internal: last user-usable RT signal]]
#define VKI_SA_NOCLDSTOP 0x00000001u
@@ -150,5 +150,5 @@ typedef struct {
#define VKI_SA_NOMASK VKI_SA_NODEFER
#define VKI_SA_ONESHOT VKI_SA_RESETHAND
-/*#define VKI_SA_INTERRUPT 0x20000000 dummy -- ignored */
+//#define VKI_SA_INTERRUPT 0x20000000 /* dummy -- ignored */
#define VKI_SA_RESTORER 0x04000000
@@ -158,9 +158,8 @@ typedef struct {
struct vki_old_sigaction {
- /* [[Nb: a 'k' prefix is added to "sa_handler" because
- bits/sigaction.h (which gets dragged in somehow via signal.h)
- #defines it as something else. Since that is done for glibc's
- purposes, which we don't care about here, we use our own name.]]
- */
+ // [[Nb: a 'k' prefix is added to "sa_handler" because
+ // bits/sigaction.h (which gets dragged in somehow via signal.h)
+ // #defines it as something else. Since that is done for glibc's
+ // purposes, which we don't care about here, we use our own name.]]
__vki_sighandler_t ksa_handler;
vki_old_sigset_t sa_mask;
@@ -170,5 +169,5 @@ struct vki_old_sigaction {
struct vki_sigaction {
- /* [[See comment about extra 'k' above]] */
+ // [[See comment about extra 'k' above]]
__vki_sighandler_t ksa_handler;
unsigned long sa_flags;
@@ -183,7 +182,7 @@ typedef struct vki_sigaltstack {
} vki_stack_t;
-/*----------------------------------------------------------------------*/
-/* From linux-2.6.8.1/include/asm-i386/sigcontext.h */
-/*----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/sigcontext.h
+//----------------------------------------------------------------------
struct _vki_fpreg {
@@ -249,7 +248,7 @@ struct vki_sigcontext {
};
-/*----------------------------------------------------------------------*/
-/* From linux-2.6.8.1/include/asm-i386/mman.h */
-/*----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/mman.h
+//----------------------------------------------------------------------
#define VKI_PROT_NONE 0x0 /* No page permissions */
@@ -260,12 +259,12 @@ struct vki_sigcontext {
#define VKI_MAP_SHARED 0x01 /* Share changes */
#define VKI_MAP_PRIVATE 0x02 /* Changes are private */
-/*#define VKI_MAP_TYPE 0x0f */ /* Mask for type of mapping */
+//#define VKI_MAP_TYPE 0x0f /* Mask for type of mapping */
#define VKI_MAP_FIXED 0x10 /* Interpret addr exactly */
#define VKI_MAP_ANONYMOUS 0x20 /* don't use a file */
#define VKI_MAP_NORESERVE 0x4000 /* don't check for reservations */
-/*----------------------------------------------------------------------*/
-/* From linux-2.6.8.1/include/asm-i386/fcntl.h */
-/*----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/fcntl.h
+//----------------------------------------------------------------------
#define VKI_O_RDONLY 00
@@ -279,5 +278,5 @@ struct vki_sigcontext {
#define VKI_F_DUPFD 0 /* dup */
-/*#define VKI_F_GETFD 1*/ /* get close_on_exec */
+//#define VKI_F_GETFD 1 /* get close_on_exec */
#define VKI_F_SETFD 2 /* set/clear close_on_exec */
#define VKI_F_GETFL 3 /* get file->f_flags */
@@ -296,7 +295,7 @@ struct vki_sigcontext {
-/*----------------------------------------------------------------------*/
-/* From linux-2.6.8.1/include/asm-i386/resource.h */
-/*----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/resource.h
+//----------------------------------------------------------------------
#define VKI_RLIMIT_DATA 2 /* max data size */
@@ -305,7 +304,7 @@ struct vki_sigcontext {
#define VKI_RLIMIT_NOFILE 7 /* max number of open files */
-/*----------------------------------------------------------------------*/
-/* From linux-2.6.8.1/include/asm-i386/socket.h */
-/*----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/socket.h
+//----------------------------------------------------------------------
#define VKI_SOL_SOCKET 1
@@ -315,7 +314,7 @@ struct vki_sigcontext {
#define VKI_SOCK_STREAM 1 /* stream (connection) socket */
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/sockios.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/sockios.h
+//----------------------------------------------------------------------
#define VKI_SIOCSPGRP 0x8902
@@ -323,7 +322,7 @@ struct vki_sigcontext {
#define VKI_SIOCGSTAMP 0x8906 /* Get stamp */
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/stat.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/stat.h
+//----------------------------------------------------------------------
#define VKI_S_IFMT 00170000
@@ -402,7 +401,7 @@ struct vki_stat64 {
};
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/statfs.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/statfs.h
+//----------------------------------------------------------------------
struct vki_statfs {
@@ -420,7 +419,7 @@ struct vki_statfs {
};
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/termios.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/termios.h
+//----------------------------------------------------------------------
struct vki_winsize {
@@ -442,7 +441,7 @@ struct vki_termio {
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/termbits.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/termbits.h
+//----------------------------------------------------------------------
typedef unsigned char vki_cc_t;
@@ -459,7 +458,7 @@ struct vki_termios {
};
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/ioctl.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/ioctl.h
+//----------------------------------------------------------------------
#define _VKI_IOC_NRBITS 8
@@ -507,7 +506,7 @@ extern unsigned int __vki_invalid_size_a
#define _VKI_IOC_SIZE(nr) (((nr) >> _VKI_IOC_SIZESHIFT) & _VKI_IOC_SIZEMASK)
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/ioctls.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/ioctls.h
+//----------------------------------------------------------------------
#define VKI_TCGETS 0x5401
@@ -540,7 +539,7 @@ extern unsigned int __vki_invalid_size_a
#define VKI_FIOASYNC 0x5452
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/poll.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/poll.h
+//----------------------------------------------------------------------
/* These are specified by iBCS2 */
@@ -553,7 +552,7 @@ struct vki_pollfd {
};
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/user.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/user.h
+//----------------------------------------------------------------------
struct vki_user_i387_struct {
@@ -600,7 +599,7 @@ struct vki_user_regs_struct {
};
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/elf.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/elf.h
+//----------------------------------------------------------------------
typedef unsigned long vki_elf_greg_t;
@@ -614,7 +613,7 @@ typedef struct vki_user_fxsr_struct vki_
#define VKI_AT_SYSINFO 32
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/ucontext.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/ucontext.h
+//----------------------------------------------------------------------
struct vki_ucontext {
@@ -626,7 +625,7 @@ struct vki_ucontext {
};
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/segment.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/segment.h
+//----------------------------------------------------------------------
#define VKI_GDT_ENTRY_TLS_ENTRIES 3
@@ -634,7 +633,7 @@ struct vki_ucontext {
#define VKI_GDT_ENTRY_TLS_MAX (VKI_GDT_ENTRY_TLS_MIN + VKI_GDT_ENTRY_TLS_ENTRIES - 1)
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/ldt.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/ldt.h
+//----------------------------------------------------------------------
/* [[Nb: This is the structure passed to the modify_ldt syscall. Just so as
@@ -652,18 +651,18 @@ struct vki_user_desc {
unsigned int seg_not_present:1;
unsigned int useable:1;
- /* [[Nb: this field is not in the kernel sources, but it has always
- been in the Valgrind sources so I will keep it there in case it's
- important... this is an x86-defined data structure so who
- knows; maybe it's important to set this field to zero at some
- point. --njn]] */
+ // [[Nb: this field is not in the kernel sources, but it has always
+ // been in the Valgrind sources so I will keep it there in case it's
+ // important... this is an x86-defined data structure so who
+ // knows; maybe it's important to set this field to zero at some
+ // point. --njn]]
unsigned int reserved:25;
};
-/* [[Nb: for our convenience within Valgrind, use a more specific name]] */
+// [[Nb: for our convenience within Valgrind, use a more specific name]]
typedef struct vki_user_desc vki_modify_ldt_t;
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/ipcbuf.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/ipcbuf.h
+//----------------------------------------------------------------------
struct vki_ipc64_perm
@@ -682,7 +681,7 @@ struct vki_ipc64_perm
};
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/sembuf.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/sembuf.h
+//----------------------------------------------------------------------
struct vki_semid64_ds {
@@ -697,7 +696,7 @@ struct vki_semid64_ds {
};
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/msgbuf.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/msgbuf.h
+//----------------------------------------------------------------------
struct vki_msqid64_ds {
@@ -718,7 +717,7 @@ struct vki_msqid64_ds {
};
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/ipc.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/ipc.h
+//----------------------------------------------------------------------
struct vki_ipc_kludge {
@@ -727,7 +726,7 @@ struct vki_ipc_kludge {
};
-/*----------------------------------------------------------------------
- From linux-2.6.8.1/include/asm-i386/shmbuf.h
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/shmbuf.h
+//----------------------------------------------------------------------
struct vki_shmid64_ds {
@@ -759,7 +758,7 @@ struct vki_shminfo64 {
};
-/*----------------------------------------------------------------------
- DRM ioctls
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// DRM ioctls
+//----------------------------------------------------------------------
struct vki_drm_buf_pub {
Int idx; /**< Index into the master buffer list */
@@ -779,9 +778,9 @@ struct vki_drm_buf_map {
-/*----------------------------------------------------------------------
- And that's it!
- ----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// And that's it!
+//----------------------------------------------------------------------
-#endif /* __X86_LINUX_VKI_ARCH_H */
+#endif // __X86_LINUX_VKI_ARCH_H
/*--------------------------------------------------------------------*/
--- valgrind/include/x86-linux/vki_arch_posixtypes.h #1.4:1.5
@@ -33,7 +33,7 @@
#define __X86_LINUX_VKI_ARCH_POSIXTYPES_H
-/*----------------------------------------------------------------------*/
-/* From linux-2.6.8.1/include/asm-i386/posix_types.h */
-/*----------------------------------------------------------------------*/
+//----------------------------------------------------------------------
+// From linux-2.6.8.1/include/asm-i386/posix_types.h
+//----------------------------------------------------------------------
typedef unsigned short __vki_kernel_mode_t;
@@ -62,5 +62,5 @@ typedef struct {
} __vki_kernel_fsid_t;
-#endif /* __X86_LINUX_VKI_ARCH_POSIXTYPES_H */
+#endif // __X86_LINUX_VKI_ARCH_POSIXTYPES_H
/*--------------------------------------------------------------------*/
|