summaryrefslogtreecommitdiff
path: root/gc.c
AgeCommit message (Collapse)Author
2003-10-20* gc.c (gc_sweep): loosen page free condition to avoid add_heap()matz
race condition. [ruby-dev:21633] * gc.c (gc_sweep): do not update malloc_limit when malloc_increase is smaller than malloc_limit. * ext/socket/socket.c (make_hostent): h_aliases may be NULL. (ruby-bugs PR#1195) * ext/socket/socket.c (sock_s_gethostbyaddr): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4808 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-06* parse.y (stmt): rhs of multiple assignment should not bematz
expanded using "to_a". [ruby-dev:21527] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4710 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-04* gc.c (Init_stack): the type of space is changed to unsigned inteban
from double. [ruby-dev:21483] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4673 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-01* gc.c (heaps): manage slots and limits together. [ruby-dev:21453]nobu
* gc.c (add_heap): should not clear heaps slot even if realloc() failed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4639 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-08-22* enum.c (inject_i): use rb_yield_values.matz
* enum.c (each_with_index_i): ditto. * eval.c (rb_yield_splat): new function to call "yield *values". * string.c (rb_str_scan): use rb_yield_splat(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4424 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-08-14* gc.c (id2ref): recycle check should be done by klass == 0.matz
[ruby-core:01408] * eval.c (Init_Thread): Continuation#[] added. [ruby-talk:79028] * parse.y (mlhs_node): should allow "::Foo" (colon3) as lhs. * parse.y (lhs): ditto. * parse.y (yylex): should return tCOLON3 right after kCLASS. [ruby-talk:78918] * error.c (exc_initialize): was converting argument to string too eagerly. Only check was needed. [ruby-talk:78958] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4390 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-08-14* gc.c (rb_data_object_alloc): check type of 1st argument.usa
[ruby-dev:21192] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4382 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-08-06* eval.c (rb_call0): update ruby_class as well as ruby_cref.matz
(ruby-bugs-ja PR#540) * eval.c (rb_yield_0): remove ruby_frame->cbase and unify to ruby_cref. [ruby-talk:78141] * eval.c: initialize /* OK */ variables by Qnil to stop warnings. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4346 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-08-06* gc.c: FreeBSD/ia64's mcontext_t is a bit different from that ofknu
Linux/ia64. This makes gc.c compile but miniruby coredumps for the moment. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4345 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-08-02* gc.c: add "#pragma weak" for __libc_ia64_register_backing_store_base.matz
[ruby-dev:21072] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4286 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-08-01* gc.c (rb_gc_mark_locations): no need to swap arguments.nobu
* gc.c (STACK_LENGTH): insufficient for growing up stack architectures. * gc.c (rb_gc, Init_stack) ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4272 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-08-01* gc.c (rb_gc): typo.matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4267 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-08-01* ext/syck/rubyext.c (syck_emitter_write_m): forgot to declarematz
"self", making it default to "int". * ext/syck/rubyext.c (syck_emitter_simple_write): ditto. * gc.c (rb_gc): should mark backing store region on IA64. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4266 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-07-31* gc.c (Init_stack): wrong magic number.matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4248 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-07-31* gc.c (Init_stack): IA64 requires STACK_LEVEL_MAX to be less thanmatz
magic number when optimizer turned on, regardless of rlimit values. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4247 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-07-25* ext/socket/socket.c (tcp_s_gethostbyname): was usingmatz
uninitialized size_t value. [ruby-talk:76946] * Minor cleanups. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4156 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-07-24* gcc -Wall clean-up.matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4151 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-07-24* gc.c (run_final): backout unnecessary modifies.matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4147 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-07-24* eval.c (thgroup_add): no warning for terminated threads.matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4142 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-07-17* eval.c (rb_clear_cache_by_class): check both klass and origin.matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4083 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-07-17* eval.c (ruby_init): set ruby_running to true aftermatz
initialization. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4080 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-07-07* eval.c (rb_call_super): k->super maybe NULL if klass is Kernel.matz
[ruby-dev:20519] * gc.c (obj_free): clear method cache when freeing class/module. * eval.c (rb_mod_remove_method): allow "remove_method" to accept multiple arguments. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4041 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-06-28* configure.in (rb_cv_stack_grow_dir): check stack growing direction.nobu
* eval.c (rb_thread_restore_context): prior configuration macro. * gc.c (ruby_stack_length): always return the address of lower edge. * gc.c (rb_gc_mark_locations): remove margin. [ruby-dev:20462] * gc.c (rb_gc, Init_stack): prior configuration macro. * gc.c (Init_stack): add safety margin. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4012 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-06-16* eval.c (proc_alloc): re-unification of Block and Proc. Blockmatz
class is no longer available. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3948 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-06-07* parse.y (value_expr0): class and module statements should not bematz
warned for "void value expression". [ruby-talk:72989] * gc.c (add_final): should determine type by respond_to? * gc.c (define_final): ditto. * io.c (rb_io_ctl): should not depend on respond_to? * range.c (range_step): rb_check_string_type(). * process.c (proc_setgroups): new functions. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3918 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-06-06* gc.c (define_final): eliminate rb_f_lambda() call.matz
* class.c (rb_scan_args): ditto. * signal.c (sig_trap): ditto. * hash.c (rb_hash_initialize): ditto. * variable.c (rb_f_trace_var): ditto. * ext/dl/dl.c (rb_dl_callback): ditto. * ext/win32ole/win32ole.c (ev_on_event): ditto. * eval.c (ruby_cleanup): $SAFE is turned off in the finalization. Each END proc should preserve its own $SAFE level. [ruby-core:01119] * marshal.c (marshal_load): remove unused variable "hash". [ruby-core:01120] * hash.c (env_str_new): freeze strings from ENV. [ruby-talk:72860] * array.c (rb_ary_first): optional argument to retrieve first n elements. * array.c (rb_ary_last): optional argument to retrieve last n elements. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3915 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-05-22* gc.c (run_final): use rb_thread_critical instead of DEFER_INTS.matz
[ruby-dev:20272] * marshal.c: try to make ArgumentError and TypeError consistent. [ruby-core:01068] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3853 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-05-21* error.c (syserr_initialize): prohibit specifying errno formatz
subclasses of SystemCallError. in addition, if initialize is called for SystenCallError instance, its class be changed. [ruby-dev:20257] * gc.c (run_final): to protect thread context switch, finalizers are wrapped in DEFER_INTS/ENABLE_INTS. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3839 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-05-08* gc.c (rb_gc): check odd alignment stack on m68k machines.matz
* numeric.c (num_step): better error treatment of float values. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3769 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-04-25* gc.c: STACK_LEVEL_MAX=65535 on mswince.uema2
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3732 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-04-21* gc.c (rb_gc): use rb_gc_mark_maybe() to mark registered Cmatz
addresses. C variables may not hold valid reference to Ruby objects. [ruby-core:00975] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3705 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-04-09* gc.c (rb_gc_mark_children): introduce this function again; thismatz
is required when stack was very tight. [ruby-talk:68916] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3657 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-04-09* bignum.c (BIGZEROP): macro to determine if x is a bignum zero.matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3653 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-03-26* eval.c (avalue_splat): new function to do unary * (splat)matz
operator. * eval.c (avalue_to_svalue,svalue_to_avalue,svalue_to_mrhs): do not use implicit "to_ary" conversion. * ext/curses/curses.c (GetWINDOW,GetMOUSE): add taint check. * ext/curses/curses.c (curses_init_screen): ditto. * ext/curses/curses.c (window_initialize): ditto. * gc.c (os_each_obj): prohibit ObjectSpace#each_object in safe mode ($SAFE >= 4). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3616 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-03-23* gc.c (rb_gc_call_finalizer_at_exit): use free() if dfree is -1.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3600 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-02-27* string.c (str_new): need no MEMZERO().matz
* numeric.c (fix_gt): use rb_num_coerce_cmp() instead of rb_num_coerce_bin. * numeric.c (fix_ge, fix_lt, fix_le): ditto. * numeric.c (flo_gt, flo_ge, flo_lt, flo_le): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3536 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-02-21* gc.c (rb_gc_mark): inline rb_gc_mark_children().matz
* gc.c (gc_sweep): new tactics to increase malloc_limit mildly. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3518 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-02-20* parse.y (clhs): allow "Foo::Bar = x".matz
* parse.y (primary): "self[n]=x" can be legal even when "[]=" is private. changes submitted in [ruby-talk:63982] * parse.y (aryset): ditto. * parse.y (attrset): "self.foo=x" can be legal even when "foo=" is private. * eval.c (is_defined): private "[]=" and "foo=" support. * eval.c (rb_eval): ditto. * eval.c (assign): ditto. * eval.c (rb_eval): "foo=" should not always be public. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3509 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-02-19* node.h (nd_cpath): nested class/module declaration.nobu
[EXPREIMENTAL] * eval.c (rb_eval): ditto. * gc.c (rb_gc_mark_children): ditto. * parse.y (cpath): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3506 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-01-31* variable.c (rb_obj_classname): new function.matz
* string.c (rb_str_dup): should preserve original's class (but not hidden singleton class). * string.c (rb_str_substr): ditto. * parse.y: backout EXPR_CMDARG removal. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3427 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-01-16-Wall cleanups (removed unused vars, no 'code has no effect' warnings)michal
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3346 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-01-16Updated Copyrights of Matz to 2003.michal
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3345 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-01-06* st.h, st.c: Introduce new conventional typedef's, st_data_t,knu
st_compare_func_t, st_hash_func_t and st_each_func_t. * st.h, st.c: Do explicit function declarations and do not rely on implicit declarations. On such platforms as IA64, int argument values are NOT automatically promoted to long (64bit) values, so explicit declarations are mandatory for those functions that take long values or pointers. This fixes miniruby's coredump on FreeBSD/IA64. * class.c, eval.c, gc.c, hash.c, marshal.c, parse.y, variable.c: Add proper casts to avoid warnings. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3303 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-01-04* defines.h (FLUSH_REGISTER_WINDOWS): Make the flushw call anknu
inline function instead so it can be used as an expression. * eval.c (EXEC_TAG, THREAD_SAVE_CONTEXT): Consistently call FLUSH_REGISTER_WINDOWS before calling setjmp(). (I suspect that every setjmp() implementation should take care of register windows, though) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3285 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-12-31* gc.c (rb_gc_mark_frame): should mark frame->node.matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3256 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-12-29* gc.c (gc_sweep): adjust GC trigger.nobu
* dln.c (init_funcname_len): get rid of gcc-3 -O3 warning. * eval.c (copy_node_scope): ditto. * hash.c (rb_hash_foreach, delete_if_i, select_i, each_value_i, each_key_i, each_pair_i, envix): ditto. * range.c (range_each_func): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3238 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-12-04* object.c (copy_object): copy finalizers as well if any.matz
* gc.c (rb_gc_copy_finalizer): new function to copy finalizers. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3114 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-29* eval.c, file.c, gc.c, io.c, object.c, ruby.c, ruby.h, struct.c,knu
ext/socket/socket.c: differentiate long and int; use proper printf type specifiers and do casts where appropriate. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3014 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-25* eval.c, gc.c: adopt a common set of alloca() #ifdef's. Thisknu
fixes the build with Intel C Compiler for Linux. * eval.c (rb_f_require): declare old_func with a real type, not just type modifiers. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2995 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-17* object.c (rb_str_to_dbl): RString ptr might be NULL.matz
* object.c (rb_cstr_to_dbl): p pointer might be NULL. * bignum.c (rb_str_to_inum): RString ptr might be NULL. * bignum.c (rb_cstr_to_inum): str pointer might be NULL. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2965 b2dd03c8-39d4-4d8f-98ff-823fe69b080e