File tree Expand file tree Collapse file tree 2 files changed +3
-18
lines changed Expand file tree Collapse file tree 2 files changed +3
-18
lines changed Original file line number Diff line number Diff line change 1
1
---
2
- refs/heads/master: 00be34608914681e9a0a14611fc5ced6cffa32ec
2
+ refs/heads/master: fe683dfb80498fa3336c6f5f96b6b82917ac08b3
Original file line number Diff line number Diff line change 15
15
16
16
#include " globals.h"
17
17
18
- // Each stack gets some guard bytes that valgrind will verify we don't touch
19
- #ifndef NVALGRIND
20
- #define STACK_NOACCESS_SIZE 16
21
- #else
22
- #define STACK_NOACCESS_SIZE 0
23
- #endif
24
-
25
18
// The amount of extra space at the end of each stack segment, available
26
19
// to the rt, compiler and dynamic linker for running small functions
27
20
// FIXME: We want this to be 128 but need to slim the red zone calls down
28
21
#ifdef __i386__
29
- #define RED_ZONE_SIZE ( 65536 + STACK_NOACCESS_SIZE)
22
+ #define RED_ZONE_SIZE 65536
30
23
#endif
31
24
32
25
#ifdef __x86_64__
33
- #define RED_ZONE_SIZE ( 65536 + STACK_NOACCESS_SIZE)
26
+ #define RED_ZONE_SIZE 65536
34
27
#endif
35
28
36
29
// Stack size
@@ -80,19 +73,11 @@ config_valgrind_stack(stk_seg *stk) {
80
73
// caused valgrind to consider the whole thing inaccessible.
81
74
size_t sz = stk->end - (uintptr_t )&stk->data [0 ];
82
75
VALGRIND_MAKE_MEM_UNDEFINED (stk->data , sz);
83
-
84
- // Establish some guard bytes so valgrind will tell
85
- // us if we run off the end of the stack
86
- VALGRIND_MAKE_MEM_NOACCESS (stk->data , STACK_NOACCESS_SIZE);
87
76
#endif
88
77
}
89
78
90
79
static void
91
80
unconfig_valgrind_stack (stk_seg *stk) {
92
- #ifndef NVALGRIND
93
- // Make the guard bytes accessible again, but undefined
94
- VALGRIND_MAKE_MEM_UNDEFINED (stk->data , STACK_NOACCESS_SIZE);
95
- #endif
96
81
VALGRIND_STACK_DEREGISTER (stk->valgrind_id );
97
82
}
98
83
You can’t perform that action at this time.
0 commit comments