]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Get rid of some macros used only by the old aspacemgr, and tidy up
authorJulian Seward <jseward@acm.org>
Wed, 28 Sep 2005 01:36:01 +0000 (01:36 +0000)
committerJulian Seward <jseward@acm.org>
Wed, 28 Sep 2005 01:36:01 +0000 (01:36 +0000)
m_main even more.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@4802

coregrind/m_main.c
coregrind/pub_core_options.h
include/vki-linux.h

index 331e8bda64b2cfd95571d420b0fffc1a41b1e0f8..a0886059f939ffbde9429b607a7510f8c5b2afe2 100644 (file)
 #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;
index aeb80add5cc1ac3c9568c760c12e85bdac040674..a2e87fe430682a1fbb5c639eb6b1c87a6c2e1791 100644 (file)
@@ -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.
    } 
index 1cd05179394c063446a92c8233044b8f3df1bbc2..b7f6181f51e01c94cb30a30ce17fcdb0f6d02de7 100644 (file)
@@ -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
 //----------------------------------------------------------------------