|
From: <sv...@va...> - 2009-05-08 06:51:51
|
Author: njn
Date: 2009-05-08 07:51:39 +0100 (Fri, 08 May 2009)
New Revision: 9800
Log:
Add "GrP" or "DDD" to all the Darwin-specific "fixme" comments, so they're
easy to find.
Modified:
branches/DARWIN/coregrind/m_replacemalloc/vg_replace_malloc.c
branches/DARWIN/coregrind/m_syswrap/syscall-amd64-darwin.S
branches/DARWIN/coregrind/m_syswrap/syscall-x86-darwin.S
branches/DARWIN/coregrind/m_syswrap/syswrap-amd64-darwin.c
branches/DARWIN/coregrind/m_syswrap/syswrap-darwin.c
branches/DARWIN/coregrind/m_syswrap/syswrap-main.c
branches/DARWIN/coregrind/m_syswrap/syswrap-x86-darwin.c
branches/DARWIN/coregrind/m_ume/macho.c
branches/DARWIN/coregrind/pub_core_threadstate.h
branches/DARWIN/coregrind/vg_preloaded.c
Modified: branches/DARWIN/coregrind/m_replacemalloc/vg_replace_malloc.c
===================================================================
--- branches/DARWIN/coregrind/m_replacemalloc/vg_replace_malloc.c 2009-05-08 06:40:58 UTC (rev 9799)
+++ branches/DARWIN/coregrind/m_replacemalloc/vg_replace_malloc.c 2009-05-08 06:51:39 UTC (rev 9800)
@@ -745,18 +745,18 @@
static vki_malloc_zone_t vg_default_zone = {
NULL, // reserved
NULL, // reserved
- NULL, // fixme malloc_size
+ NULL, // GrP fixme malloc_size
(void*)VG_REPLACE_FUNCTION_ZU(VG_Z_LIBC_SONAME, malloc_zone_malloc),
(void*)VG_REPLACE_FUNCTION_ZU(VG_Z_LIBC_SONAME, malloc_zone_calloc),
(void*)VG_REPLACE_FUNCTION_ZU(VG_Z_LIBC_SONAME, malloc_zone_valloc),
(void*)VG_REPLACE_FUNCTION_ZU(VG_Z_LIBC_SONAME, malloc_zone_free),
(void*)VG_REPLACE_FUNCTION_ZU(VG_Z_LIBC_SONAME, malloc_zone_realloc),
- NULL, // fixme destroy
+ NULL, // GrP fixme destroy
"ValgrindMallocZone",
NULL, // batch_malloc
NULL, // batch_free
- NULL, // fixme introspect
- 2, // version (fixme 3?)
+ NULL, // GrP fixme introspect
+ 2, // version (GrP fixme 3?)
// DDD: this field exists in Mac OS 10.6, but not 10.5.
#if 0
(void*)VG_REPLACE_FUNCTION_ZU(VG_Z_LIBC_SONAME, malloc_zone_memalign)
Modified: branches/DARWIN/coregrind/m_syswrap/syscall-amd64-darwin.S
===================================================================
--- branches/DARWIN/coregrind/m_syswrap/syscall-amd64-darwin.S 2009-05-08 06:40:58 UTC (rev 9799)
+++ branches/DARWIN/coregrind/m_syswrap/syscall-amd64-darwin.S 2009-05-08 06:51:39 UTC (rev 9800)
@@ -97,13 +97,13 @@
/* Set the signal mask which should be current during the syscall. */
/* GrP fixme signals
- JRS fixme: use __NR___pthread_sigmask, not __NR_rt_sigprocmask
+ DDD: JRS fixme: use __NR___pthread_sigmask, not __NR_rt_sigprocmask
movq $__NR_rt_sigprocmask, %rax // syscall #
movq $VKI_SIG_SETMASK, %rdi // how
movq -24(%rbp), %rsi // sysmask
movq -32(%rbp), %rdx // postmask
movq -40(%rbp), %r10 // sigsetSzB in r10 not rcx
- fixme return address
+ DDD: fixme return address
syscall
jnc 7f // sigprocmask failed
@@ -160,7 +160,7 @@
L_$0_4: /* Re-block signals. If eip is in [4,5), then the syscall
is complete and we needn't worry about it. */
/* GrP fixme signals
- JRS fixme: use __NR___pthread_sigmask, not __NR_rt_sigprocmask
+ DDD: JRS fixme: use __NR___pthread_sigmask, not __NR_rt_sigprocmask
PUSH_di_si_dx_cx_8
movq $__NR_rt_sigprocmask, %rax // syscall #
@@ -168,7 +168,7 @@
movq %rcx, %rsi // postmask
xorq %rdx, %rdx // NULL
movq %r8, %r10 // sigsetSzB
- fixme return address
+ DDD: fixme return address
syscall
POP_di_si_dx_cx_8
@@ -183,7 +183,7 @@
/* GrP fixme signals
L_$0_7: // failure: return 0x8000 | error code
- fixme return value
+ DDD: fixme return value
movq %rbp, %rsp
popq %rbp
ret
Modified: branches/DARWIN/coregrind/m_syswrap/syscall-x86-darwin.S
===================================================================
--- branches/DARWIN/coregrind/m_syswrap/syscall-x86-darwin.S 2009-05-08 06:40:58 UTC (rev 9799)
+++ branches/DARWIN/coregrind/m_syswrap/syscall-x86-darwin.S 2009-05-08 06:51:39 UTC (rev 9800)
@@ -133,7 +133,7 @@
or was interrupted and the kernel was restarting it. */
L_$0_2:
.if $0 == UNIX
- int $$0x80 /* UNIX (fixme should be sysenter?) */
+ int $$0x80 /* UNIX (GrP fixme should be sysenter?) */
.elseif $0 == MACH
int $$0x81
.elseif $0 == MDEP
Modified: branches/DARWIN/coregrind/m_syswrap/syswrap-amd64-darwin.c
===================================================================
--- branches/DARWIN/coregrind/m_syswrap/syswrap-amd64-darwin.c 2009-05-08 06:40:58 UTC (rev 9799)
+++ branches/DARWIN/coregrind/m_syswrap/syswrap-amd64-darwin.c 2009-05-08 06:51:39 UTC (rev 9800)
@@ -81,7 +81,7 @@
mach->__r13 = vex->guest_R13;
mach->__r14 = vex->guest_R14;
mach->__r15 = vex->guest_R15;
- /* fixme
+ /* GrP fixme
mach->__cs = vex->guest_CS;
mach->__fs = vex->guest_FS;
mach->__gs = vex->guest_GS;
@@ -144,7 +144,7 @@
vex->guest_R13 = mach->__r13;
vex->guest_R14 = mach->__r14;
vex->guest_R15 = mach->__r15;
- /* fixme
+ /* GrP fixme
vex->guest_CS = mach->__cs;
vex->guest_FS = mach->__fs;
vex->guest_GS = mach->__gs;
@@ -430,19 +430,19 @@
tst->client_stack_highest_word = stack+stacksize;
tst->client_stack_szB = stacksize;
- // fixme scheduler lock?!
+ // GrP fixme scheduler lock?!
// pthread structure
ML_(notify_aspacem_and_tool_of_mmap)
(stack+stacksize, pthread_structsize,
VKI_PROT_READ|VKI_PROT_WRITE, VKI_MAP_PRIVATE, -1, 0);
// stack contents
- // fixme uninitialized!
+ // GrP fixme uninitialized!
ML_(notify_aspacem_and_tool_of_mmap)
(stack, stacksize,
VKI_PROT_READ|VKI_PROT_WRITE, VKI_MAP_PRIVATE, -1, 0);
// guard page
- // fixme ban_mem_stack!
+ // GrP fixme ban_mem_stack!
ML_(notify_aspacem_and_tool_of_mmap)
(stack-VKI_PAGE_SIZE, VKI_PAGE_SIZE,
0, VKI_MAP_PRIVATE, -1, 0);
Modified: branches/DARWIN/coregrind/m_syswrap/syswrap-darwin.c
===================================================================
--- branches/DARWIN/coregrind/m_syswrap/syswrap-darwin.c 2009-05-08 06:40:58 UTC (rev 9799)
+++ branches/DARWIN/coregrind/m_syswrap/syswrap-darwin.c 2009-05-08 06:51:39 UTC (rev 9800)
@@ -256,7 +256,7 @@
tst->status = VgTs_Empty;
// GrP fixme race here! new thread may claim this V thread stack
// before we get out here!
- // fixme use bsdthread_terminate for safe cleanup?
+ // GrP fixme use bsdthread_terminate for safe cleanup?
mach_msg(&msg, MACH_SEND_MSG|MACH_MSG_OPTION_NONE,
sizeof(msg), 0, 0, MACH_MSG_TIMEOUT_NONE, 0);
@@ -1466,8 +1466,8 @@
switch (ARG1) {
case VKI_WQOPS_QUEUE_ADD:
case VKI_WQOPS_QUEUE_REMOVE:
- // fixme need anything here?
- // fixme may block?
+ // GrP fixme need anything here?
+ // GrP fixme may block?
break;
case VKI_WQOPS_THREAD_RETURN: {
@@ -1483,7 +1483,7 @@
// to a strange address.
ThreadState *tst = VG_(get_ThreadState)(tid);
tst->os_state.wq_jmpbuf_valid = True;
- *flags |= SfMayBlock; // fixme true?
+ *flags |= SfMayBlock; // GrP fixme true?
break;
}
@@ -1893,12 +1893,12 @@
PRE(sys_accessx)
{
- // fixme difficult
+ // GrP fixme difficult
}
POST(sys_accessx)
{
- // fixme
+ // GrP fixme
}
PRE(sys_chflags)
@@ -1907,7 +1907,7 @@
PRE_REG_READ2(int, "chflags", const char *,path, unsigned int,flags);
PRE_MEM_RASCIIZ("chflags(path)", ARG1);
- // fixme sanity-check flags value?
+ // GrP fixme sanity-check flags value?
}
PRE(sys_fchflags)
@@ -1915,7 +1915,7 @@
PRINT("sys_fchflags ( %ld, %lu )", ARG1, ARG2);
PRE_REG_READ2(int, "fchflags", int,fd, unsigned int,flags);
- // fixme sanity-check flags value?
+ // GrP fixme sanity-check flags value?
}
POST(sys_stat64)
@@ -2997,7 +2997,7 @@
case VKI_A_GETFSIZE:
case VKI_A_GETCOND:
// kernel writes data..data+length
- // fixme be precise about what gets written
+ // GrP fixme be precise about what gets written
PRE_MEM_WRITE("auditon(data)", ARG2, ARG3);
break;
@@ -3006,7 +3006,7 @@
case VKI_A_GETPINFO:
case VKI_A_GETPINFO_ADDR:
// kernel reads and writes data..data+length
- // fixme be precise about what gets read and written
+ // GrP fixme be precise about what gets read and written
PRE_MEM_READ("auditon(data)", ARG2, ARG3);
PRE_MEM_WRITE("auditon(data)", ARG2, ARG3);
break;
@@ -3048,7 +3048,7 @@
case VKI_A_GETFSIZE:
case VKI_A_GETCOND:
// kernel writes data..data+length
- // fixme be precise about what gets written
+ // GrP fixme be precise about what gets written
POST_MEM_WRITE(ARG2, ARG3);
break;
@@ -3057,7 +3057,7 @@
case VKI_A_GETPINFO:
case VKI_A_GETPINFO_ADDR:
// kernel reads and writes data..data+length
- // fixme be precise about what gets read and written
+ // GrP fixme be precise about what gets read and written
POST_MEM_WRITE(ARG2, ARG3);
break;
@@ -3149,7 +3149,7 @@
VG_(printf)("]");
}
- // fixme intercept KERN_PROCARGS and KERN_PROC_PID for our pid
+ // GrP fixme intercept KERN_PROCARGS and KERN_PROC_PID for our pid
// (executable path and arguments and environment
{
@@ -3701,7 +3701,7 @@
name_for_port(req->notify_port.name));
}
- // fixme only do this on success
+ // GrP fixme only do this on success
assign_port_name(req->notify_port.name, "host_notify-%p");
}
@@ -4087,7 +4087,7 @@
POST(mach_port_request_notification)
{
- // fixme port tracker? not sure
+ // GrP fixme port tracker? not sure
}
@@ -4114,14 +4114,14 @@
AFTER = POST_FN(mach_port_insert_right);
if (MACH_REMOTE == mach_task_self()) {
- // fixme import_complex_message handles everything?
+ // GrP fixme import_complex_message handles everything?
// what about export_complex_message for MOVE variants?
} else {
VG_(printf)("UNKNOWN mach_port_insert_right into remote task!\n");
- // fixme also may remove rights from this task?
+ // GrP fixme also may remove rights from this task?
}
- // fixme port tracker?
+ // GrP fixme port tracker?
}
POST(mach_port_insert_right)
@@ -4200,7 +4200,7 @@
AFTER = POST_FN(mach_port_insert_member);
- // fixme port tracker?
+ // GrP fixme port tracker?
}
POST(mach_port_insert_member)
@@ -5106,7 +5106,7 @@
name_for_port(MACH_REMOTE),
req->address, req->control, req->state);
- // fixme verify address?
+ // GrP fixme verify address?
AFTER = POST_FN(vm_purgable_control);
}
@@ -5149,7 +5149,7 @@
name_for_port(MACH_REMOTE),
(unsigned long long)req->address, req->control, req->state);
- // fixme verify address?
+ // GrP fixme verify address?
AFTER = POST_FN(mach_vm_purgable_control);
}
@@ -5382,7 +5382,7 @@
if (!reply->RetCode) {
// no V-visible side effects
- // fixme except maybe fork/exec
+ // GrP fixme except maybe fork/exec
} else {
PRINT("mig return %d", reply->RetCode);
}
@@ -5547,7 +5547,7 @@
PRINT("got region at 0x%llx, size %llu, depth %u, count %u",
reply->address, reply->size,
reply->nesting_depth, reply->infoCnt);
- // fixme mark info contents beyond infoCnt as bogus
+ // GrP fixme mark info contents beyond infoCnt as bogus
} else {
PRINT("mig return %d", reply->RetCode);
}
@@ -5715,8 +5715,8 @@
semaphore_destroy(mach_task_self(), tst->os_state.child_go);
semaphore_destroy(mach_task_self(), tst->os_state.child_done);
- // fixme semaphore destroy needed when thread creation fails
- // fixme probably other cleanup too
+ // GrP fixme semaphore destroy needed when thread creation fails
+ // GrP fixme probably other cleanup too
// DDD: I'm not at all sure this is the right spot for this. It probably
// should be in pthread_hijack instead, just before the call to
@@ -5737,7 +5737,7 @@
mach_port_t,"kport", mach_port_t,"joinsem");
// Free memory and signal semaphore.
- // fixme errors?
+ // GrP fixme errors?
if (ARG4) semaphore_signal((semaphore_t)ARG4);
if (ARG1 && ARG2) {
ML_(notify_aspacem_and_tool_of_munmap)(ARG1, ARG2);
@@ -5866,7 +5866,7 @@
POST(thread_info)
{
- // fixme mark unused parts of thread_info_out as uninitialized?
+ // GrP fixme mark unused parts of thread_info_out as uninitialized?
}
Modified: branches/DARWIN/coregrind/m_syswrap/syswrap-main.c
===================================================================
--- branches/DARWIN/coregrind/m_syswrap/syswrap-main.c 2009-05-08 06:40:58 UTC (rev 9799)
+++ branches/DARWIN/coregrind/m_syswrap/syswrap-main.c 2009-05-08 06:51:39 UTC (rev 9800)
@@ -537,7 +537,7 @@
// syscall = Unix, 32-bit result
// OR Mach, 32-bit result
if (canonical->sysno >= 0) {
- // fixme hack I386_SYSCALL_NUMBER_MASK
+ // GrP fixme hack I386_SYSCALL_NUMBER_MASK
canonical->sysno = VG_DARWIN_SYSCALL_CONSTRUCT_UNIX(canonical->sysno
& 0xffff);
} else {
@@ -935,7 +935,7 @@
OFFSET_x86_EDX, sizeof(UInt) );
LibVEX_GuestX86_put_eflag_c( sres._mode==SysRes_UNIX_ERR ? 1 : 0,
gst );
- // fixme sets defined for entire eflags, not just bit c
+ // GrP fixme sets defined for entire eflags, not just bit c
// DDD: this breaks exp-ptrcheck.
VG_TRACK( post_reg_write, Vg_CoreSysCall, tid,
offsetof(VexGuestX86State, guest_CC_DEP1), sizeof(UInt) );
@@ -968,7 +968,7 @@
OFFSET_amd64_RDX, sizeof(ULong) );
LibVEX_GuestAMD64_put_rflag_c( sres._mode==SysRes_UNIX_ERR ? 1 : 0,
gst );
- // fixme sets defined for entire rflags, not just bit c
+ // GrP fixme sets defined for entire rflags, not just bit c
// DDD: this breaks exp-ptrcheck.
VG_TRACK( post_reg_write, Vg_CoreSysCall, tid,
offsetof(VexGuestAMD64State, guest_CC_DEP1), sizeof(ULong) );
Modified: branches/DARWIN/coregrind/m_syswrap/syswrap-x86-darwin.c
===================================================================
--- branches/DARWIN/coregrind/m_syswrap/syswrap-x86-darwin.c 2009-05-08 06:40:58 UTC (rev 9799)
+++ branches/DARWIN/coregrind/m_syswrap/syswrap-x86-darwin.c 2009-05-08 06:51:39 UTC (rev 9800)
@@ -459,19 +459,19 @@
tst->client_stack_highest_word = stack+stacksize;
tst->client_stack_szB = stacksize;
- // fixme scheduler lock?!
+ // GrP fixme scheduler lock?!
// pthread structure
ML_(notify_aspacem_and_tool_of_mmap)
(stack+stacksize, pthread_structsize,
VKI_PROT_READ|VKI_PROT_WRITE, VKI_MAP_PRIVATE, -1, 0);
// stack contents
- // fixme uninitialized!
+ // GrP fixme uninitialized!
ML_(notify_aspacem_and_tool_of_mmap)
(stack, stacksize,
VKI_PROT_READ|VKI_PROT_WRITE, VKI_MAP_PRIVATE, -1, 0);
// guard page
- // fixme ban_mem_stack!
+ // GrP fixme ban_mem_stack!
ML_(notify_aspacem_and_tool_of_mmap)
(stack-VKI_PAGE_SIZE, VKI_PAGE_SIZE,
0, VKI_MAP_PRIVATE, -1, 0);
Modified: branches/DARWIN/coregrind/m_ume/macho.c
===================================================================
--- branches/DARWIN/coregrind/m_ume/macho.c 2009-05-08 06:40:58 UTC (rev 9799)
+++ branches/DARWIN/coregrind/m_ume/macho.c 2009-05-08 06:51:39 UTC (rev 9800)
@@ -204,7 +204,7 @@
}
// Get desired memory protection
- // fixme need maxprot too
+ // GrP fixme need maxprot too
prot = (((segcmd->initprot & VM_PROT_READ) ? VKI_PROT_READ : 0) |
((segcmd->initprot & VM_PROT_WRITE) ? VKI_PROT_WRITE : 0) |
((segcmd->initprot & VM_PROT_EXECUTE) ? VKI_PROT_EXEC : 0));
Modified: branches/DARWIN/coregrind/pub_core_threadstate.h
===================================================================
--- branches/DARWIN/coregrind/pub_core_threadstate.h 2009-05-08 06:40:58 UTC (rev 9799)
+++ branches/DARWIN/coregrind/pub_core_threadstate.h 2009-05-08 06:51:39 UTC (rev 9800)
@@ -167,7 +167,7 @@
// Workqueue re-entry
// (setjmp in PRE(workq_ops), longjmp in wqthread_hijack)
- // JRS fixme: this comment is no longer correct; wq_jmpbuf is
+ // DDD: JRS fixme: this comment is no longer correct; wq_jmpbuf is
// never used, and there is no such setjmp or longjmp pair.
// I guess we could leave wq_jmpbuf_valid in place though, since
// it does allow for an assertion in ML_(wqthread_continue_NORETURN).
Modified: branches/DARWIN/coregrind/vg_preloaded.c
===================================================================
--- branches/DARWIN/coregrind/vg_preloaded.c 2009-05-08 06:40:58 UTC (rev 9799)
+++ branches/DARWIN/coregrind/vg_preloaded.c 2009-05-08 06:51:39 UTC (rev 9800)
@@ -52,7 +52,7 @@
------------------------------------------------------------------ */
#if !defined(VGO_darwin)
-// GrP fixme
+// GrP GrP fixme
void VG_NOTIFY_ON_LOAD(freeres)( void );
void VG_NOTIFY_ON_LOAD(freeres)( void )
@@ -94,7 +94,7 @@
#include <string.h>
#include <crt_externs.h>
-// fixme copied from m_libcproc
+// GrP fixme copied from m_libcproc
static void env_unsetenv ( Char **env, const Char *varname )
{
Char **from;
@@ -151,7 +151,7 @@
void VG_REPLACE_FUNCTION_ZU(libSystemZdZaZddylib, arc4random_addrandom)(unsigned char *dat, int datlen)
{
// do nothing
- // fixme ought to check [dat..dat+datlen) is defined
+ // GrP fixme ought to check [dat..dat+datlen) is defined
// but don't care if it's initialized
}
|