mirror of
https://github.com/Zenithsiz/ftmemsim-valgrind.git
synced 2026-02-04 02:18:37 +00:00
Get rid of some macros used only by the old aspacemgr, and tidy up
m_main even more. git-svn-id: svn://svn.valgrind.org/valgrind/trunk@4802
This commit is contained in:
parent
f75575351e
commit
68ccd98f62
@ -61,35 +61,6 @@
|
||||
#include "pub_core_ume.h"
|
||||
|
||||
|
||||
#ifndef AT_DCACHEBSIZE
|
||||
#define AT_DCACHEBSIZE 19
|
||||
#endif /* AT_DCACHEBSIZE */
|
||||
|
||||
#ifndef AT_ICACHEBSIZE
|
||||
#define AT_ICACHEBSIZE 20
|
||||
#endif /* AT_ICACHEBSIZE */
|
||||
|
||||
#ifndef AT_UCACHEBSIZE
|
||||
#define AT_UCACHEBSIZE 21
|
||||
#endif /* AT_UCACHEBSIZE */
|
||||
|
||||
#ifndef AT_SYSINFO
|
||||
#define AT_SYSINFO 32
|
||||
#endif /* AT_SYSINFO */
|
||||
|
||||
#ifndef AT_SYSINFO_EHDR
|
||||
#define AT_SYSINFO_EHDR 33
|
||||
#endif /* AT_SYSINFO_EHDR */
|
||||
|
||||
#ifndef AT_SECURE
|
||||
#define AT_SECURE 23 /* secure mode boolean */
|
||||
#endif /* AT_SECURE */
|
||||
|
||||
/* Number of file descriptors that Valgrind tries to reserve for
|
||||
it's own use - just a small constant. */
|
||||
#define N_RESERVED_FDS (10)
|
||||
|
||||
|
||||
/*====================================================================*/
|
||||
/*=== Counters, for profiling purposes only ===*/
|
||||
/*====================================================================*/
|
||||
@ -114,7 +85,7 @@ static void print_all_stats ( void )
|
||||
|
||||
|
||||
/*====================================================================*/
|
||||
/*=== Environment and stack setup ===*/
|
||||
/*=== Setting up the client's environment ===*/
|
||||
/*====================================================================*/
|
||||
|
||||
/* Prepare the client's environment. This is basically a copy of our
|
||||
@ -236,6 +207,34 @@ static HChar** setup_client_env ( HChar** origenv, const HChar* toolname)
|
||||
}
|
||||
|
||||
|
||||
/*====================================================================*/
|
||||
/*=== Setting up the client's stack ===*/
|
||||
/*====================================================================*/
|
||||
|
||||
#ifndef AT_DCACHEBSIZE
|
||||
#define AT_DCACHEBSIZE 19
|
||||
#endif /* AT_DCACHEBSIZE */
|
||||
|
||||
#ifndef AT_ICACHEBSIZE
|
||||
#define AT_ICACHEBSIZE 20
|
||||
#endif /* AT_ICACHEBSIZE */
|
||||
|
||||
#ifndef AT_UCACHEBSIZE
|
||||
#define AT_UCACHEBSIZE 21
|
||||
#endif /* AT_UCACHEBSIZE */
|
||||
|
||||
#ifndef AT_SYSINFO
|
||||
#define AT_SYSINFO 32
|
||||
#endif /* AT_SYSINFO */
|
||||
|
||||
#ifndef AT_SYSINFO_EHDR
|
||||
#define AT_SYSINFO_EHDR 33
|
||||
#endif /* AT_SYSINFO_EHDR */
|
||||
|
||||
#ifndef AT_SECURE
|
||||
#define AT_SECURE 23 /* secure mode boolean */
|
||||
#endif /* AT_SECURE */
|
||||
|
||||
/* Add a string onto the string table, and return its address */
|
||||
static char *copy_str(char **tab, const char *str)
|
||||
{
|
||||
@ -254,7 +253,9 @@ static char *copy_str(char **tab, const char *str)
|
||||
return orig;
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
/* ----------------------------------------------------------------
|
||||
|
||||
This sets up the client's initial stack, containing the args,
|
||||
environment and aux vector.
|
||||
|
||||
@ -292,7 +293,8 @@ static char *copy_str(char **tab, const char *str)
|
||||
|
||||
VG_(cache_line_size_ppc32) // ppc32 only -- cache line size
|
||||
VG_(have_altivec_ppc32) // ppc32 only -- is Altivec supported?
|
||||
*/
|
||||
|
||||
---------------------------------------------------------------- */
|
||||
|
||||
static
|
||||
Addr setup_client_stack( void* init_sp,
|
||||
@ -1621,6 +1623,10 @@ static void print_preamble(Bool logging_to_fd, const char* toolname)
|
||||
/*=== File descriptor setup ===*/
|
||||
/*====================================================================*/
|
||||
|
||||
/* Number of file descriptors that Valgrind tries to reserve for
|
||||
it's own use - just a small constant. */
|
||||
#define N_RESERVED_FDS (10)
|
||||
|
||||
static void setup_file_descriptors(void)
|
||||
{
|
||||
struct vki_rlimit rl;
|
||||
|
||||
@ -158,7 +158,6 @@ typedef
|
||||
enum {
|
||||
Vg_SmcNone, // never generate self-checking translations
|
||||
Vg_SmcStack, // generate s-c-t's for code found in stacks
|
||||
// (segments with SF_GROWDOWN, to be precise)
|
||||
// (this is the default)
|
||||
Vg_SmcAll // make all translations self-checking.
|
||||
}
|
||||
|
||||
@ -33,8 +33,6 @@
|
||||
|
||||
All code is copied verbatim from kernel source files, except that:
|
||||
- VKI_/vki_ prefixes are added
|
||||
- a few extra constants are defined (eg. VKI_MAP_NOSYMS); these are
|
||||
marked 'internal'
|
||||
- some extra explanatory comments are included; they are all within
|
||||
"[[ ]]"
|
||||
- for some types, we only care about the size; for a few of them (big
|
||||
@ -477,10 +475,6 @@ typedef struct vki_sigevent {
|
||||
#define VKI_SEEK_CUR 1
|
||||
#define VKI_SEEK_END 2
|
||||
|
||||
// [[Our own additional mmap flags]]
|
||||
#define VKI_MAP_NOSYMS 0x40000000 // internal: disable symbol loading
|
||||
#define VKI_MAP_CLIENT 0x80000000 // internal: distinguish client mappings
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
// From linux-2.6.8.1/include/linux/net.h
|
||||
//----------------------------------------------------------------------
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user