mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* gc.h (rb_objspace_each_objects): used in objspace.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28979 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
a33fdc4ec0
commit
23b1a3d3fa
3 changed files with 19 additions and 7 deletions
|
@ -1,4 +1,6 @@
|
|||
Sat Aug 14 14:58:13 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
Sat Aug 14 15:11:01 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* gc.h (rb_objspace_each_objects): used in objspace.
|
||||
|
||||
* vm_core.h (rb_{get,set,reset}_coverages): used in coverage.
|
||||
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
#include <ruby/io.h>
|
||||
#include <ruby/re.h>
|
||||
#include <../../node.h>
|
||||
#include <../../gc.h>
|
||||
|
||||
size_t rb_str_memsize(VALUE);
|
||||
size_t rb_ary_memsize(VALUE);
|
||||
|
@ -36,10 +37,6 @@ size_t onig_memsize(regex_t *);
|
|||
size_t rb_generic_ivar_memsize(VALUE);
|
||||
size_t rb_objspace_data_type_memsize(VALUE obj);
|
||||
|
||||
void rb_objspace_each_objects(
|
||||
int (*callback)(void *start, void *end, size_t stride, void *data),
|
||||
void *data);
|
||||
|
||||
static size_t
|
||||
memsize_of(VALUE obj)
|
||||
{
|
||||
|
|
17
gc.h
17
gc.h
|
@ -21,13 +21,13 @@ NOINLINE(void rb_gc_set_stack_end(VALUE **stack_end_p));
|
|||
#if RUBY_MARK_FREE_DEBUG
|
||||
extern int ruby_gc_debug_indent;
|
||||
|
||||
static void
|
||||
static inline void
|
||||
rb_gc_debug_indent(void)
|
||||
{
|
||||
printf("%*s", ruby_gc_debug_indent, "");
|
||||
}
|
||||
|
||||
static void
|
||||
static inline void
|
||||
rb_gc_debug_body(const char *mode, const char *msg, int st, void *ptr)
|
||||
{
|
||||
if (st == 0) {
|
||||
|
@ -82,4 +82,17 @@ int ruby_get_stack_grow_direction(volatile VALUE *addr);
|
|||
#define STACK_DIR_UPPER(a,b) STACK_UPPER(&stack_grow_dir_detection, a, b)
|
||||
#endif
|
||||
|
||||
#if defined __GNUC__ && __GNUC__ >= 4
|
||||
#pragma GCC visibility push(default)
|
||||
#endif
|
||||
|
||||
size_t rb_objspace_data_type_memsize(VALUE obj);
|
||||
void rb_objspace_each_objects(
|
||||
int (*callback)(void *start, void *end, size_t stride, void *data),
|
||||
void *data);
|
||||
|
||||
#if defined __GNUC__ && __GNUC__ >= 4
|
||||
#pragma GCC visibility pop
|
||||
#endif
|
||||
|
||||
#endif /* RUBY_GC_H */
|
||||
|
|
Loading…
Reference in a new issue