gc.c: GC.latest_gc_info reports most interesting major_by flag

* gc.c (gc_info_decode): Use :major_by=>:nofree as fallback reason
	  when other trigger conditions are present.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44171 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
tmm1 2013-12-13 07:30:33 +00:00
parent 0aed7c6874
commit 3ba2006aa4
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
Fri Dec 13 16:27:17 2013 Aman Gupta <ruby@tmm1.net>
* gc.c (gc_info_decode): Use :major_by=>:nofree as fallback reason
when other trigger conditions are present.
Fri Dec 13 13:25:30 2013 Koichi Sasada <ko1@atdot.net>
* error.c: add Exception#backtrace_locations.

2
gc.c
View File

@ -5213,7 +5213,6 @@ gc_info_decode(int flags, VALUE hash_or_key)
rb_hash_aset(hash, sym_##name, (attr));
major_by =
(flags & GPR_FLAG_MAJOR_BY_NOFREE) ? sym_nofree :
(flags & GPR_FLAG_MAJOR_BY_OLDGEN) ? sym_oldgen :
(flags & GPR_FLAG_MAJOR_BY_SHADY) ? sym_shady :
(flags & GPR_FLAG_MAJOR_BY_RESCAN) ? sym_rescan :
@ -5221,6 +5220,7 @@ gc_info_decode(int flags, VALUE hash_or_key)
#if RGENGC_ESTIMATE_OLDMALLOC
(flags & GPR_FLAG_MAJOR_BY_OLDMALLOC) ? sym_oldmalloc :
#endif
(flags & GPR_FLAG_MAJOR_BY_NOFREE) ? sym_nofree :
Qnil;
SET(major_by, major_by);