23 Apr 05 (memcheck-on-amd64 notes)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+* If a thread is given an initial stack with address range [lo .. hi],
+ we need to tell memcheck that the area [lo - VGA_STACK_REDZONE_SIZE
+ .. hi] is valid, rather than just [lo .. hi] as has been the case on
+ x86-only systems. However, am not sure where to look for the call
+ into memcheck that states the new stack area.
+
+* vg_replace_malloc.c: need to create intercepts for
+ 64-bit versions of
+ operator new(unsigned, std::nothrow_t const&)
+ and
+ operator new[](unsigned, std::nothrow_t const&)
-If a thread is given an initial stack with address range [lo .. hi],
-we need to tell memcheck that the area [lo - VGA_STACK_REDZONE_SIZE
-.. hi] is valid, rather than just [lo .. hi] as has been the case on
-x86-only systems. However, am not sure where to look for the
-call into memcheck that states the new stack area.
9 Apr 05 (starting work on memcheck for 32/64-bit and big/little endian)
ALLOC_or_NULL(m_libc_dot_so_dot_6, malloc, malloc);
//ALLOC_or_NULL(m_libpgc_dot_so, malloc, malloc);
-// operator new(unsigned int), GNU mangling
+// operator new(unsigned int), GNU mangling, 32-bit platforms
ALLOC_or_BOMB(m_libstc_plus_plus_star, builtin_new, __builtin_new);
ALLOC_or_BOMB(m_libc_dot_so_dot_6, builtin_new, __builtin_new);
ALLOC_or_BOMB(m_libstc_plus_plus_star, __builtin_new, __builtin_new);
ALLOC_or_BOMB(m_libc_dot_so_dot_6, __builtin_new, __builtin_new);
+// TODO: these should only exist on 32-bit platforms
ALLOC_or_BOMB(m_libstc_plus_plus_star, _Znwj, __builtin_new);
ALLOC_or_BOMB(m_libc_dot_so_dot_6, _Znwj, __builtin_new);
+// TODO: these should only exist on 64-bit platforms
+// operator new(unsigned long), GNU mangling, 64-bit platforms
+ALLOC_or_BOMB(m_libstc_plus_plus_star, _Znwm, __builtin_new);
+ALLOC_or_BOMB(m_libc_dot_so_dot_6, _Znwm, __builtin_new);
+
+
// operator new(unsigned int), ARM/cfront mangling
//ALLOC_or_BOMB(m_libpgc_dot_so, __nw__FUi, __builtin_new);
+// TODO: create 64-bit version
// operator new(unsigned, std::nothrow_t const&), GNU mangling
ALLOC_or_NULL(m_libstc_plus_plus_star, _ZnwjRKSt9nothrow_t, __builtin_new);
ALLOC_or_NULL(m_libc_dot_so_dot_6, _ZnwjRKSt9nothrow_t, __builtin_new);
// operator new[](unsigned int), GNU mangling
ALLOC_or_BOMB(m_libstc_plus_plus_star, __builtin_vec_new, __builtin_vec_new );
ALLOC_or_BOMB(m_libc_dot_so_dot_6, __builtin_vec_new, __builtin_vec_new );
+
+// TODO: these should only exist on 32-bit platforms
ALLOC_or_BOMB(m_libstc_plus_plus_star, _Znaj, __builtin_vec_new );
ALLOC_or_BOMB(m_libc_dot_so_dot_6, _Znaj, __builtin_vec_new );
+// TODO: these should only exist on 64-bit platforms
+// operator new[](unsigned long), GNU mangling, 64-bit platforms
+ALLOC_or_BOMB(m_libstc_plus_plus_star, _Znam, __builtin_vec_new );
+ALLOC_or_BOMB(m_libc_dot_so_dot_6, _Znam, __builtin_vec_new );
+
+// TODO: create 64-bit version
// operator new[](unsigned, std::nothrow_t const&), GNU mangling
ALLOC_or_NULL(m_libstc_plus_plus_star, _ZnajRKSt9nothrow_t, __builtin_vec_new );
ALLOC_or_NULL(m_libc_dot_so_dot_6, _ZnajRKSt9nothrow_t, __builtin_vec_new );