Yukihiro "Matz" Matsumoto
e92d4e2680
modified to use irep->reps to reference child ireps. preparation for
...
removing irep array from mrb_state. note that instructions OP_LAMBDA,
OP_EXEC and OP_EPUSH are incompatible, and dumped mrb format has changed.
2013-11-07 03:54:22 +09:00
Yukihiro "Matz" Matsumoto
e386760cc7
add Fiber.current
2013-11-04 23:58:32 +09:00
Daniel Bovensiepen
302e20333b
Improve Grammar of Documentation
2013-10-02 00:50:55 +08:00
Yukihiro "Matz" Matsumoto
f8454e53ba
check d->type before accessing d->type->dfree; #1474 #858
2013-08-14 16:51:50 +09:00
fleuria
b3b4f2dbdb
clean up the warnings when GC_PROFILE is on
2013-08-09 17:38:09 +08:00
Yukihiro "Matz" Matsumoto
3d3ca985b0
remove duplicated incremental_gc_until() in generational GC; #1449
2013-08-09 18:11:16 +09:00
fleuria
7e7943322b
add comments for major GC
2013-08-09 15:43:06 +08:00
Yukihiro "Matz" Matsumoto
30f86069de
finish half-baked GC cycle before starting full GC; #1447
2013-08-08 22:08:12 +09:00
Yukihiro "Matz" Matsumoto
1e87bf6d2f
allow turning off GC generational mode by default by MRB_GC_TURN_OFF_GENERATIONAL; #1447
2013-08-08 21:42:20 +09:00
fleuria
22ac62a4f1
fix #1442
...
in the marking root phase, we only marked the root context, but leaving
the current context unmarked. when we execute a fiber, the current
context would be changed and trigger this issue.
2013-08-07 19:42:56 +08:00
fleuria
107906e3cb
revise the comment in mrb_full_gc()
...
the old comment "clean all the black object as old" looks confusing,
it looks like "transform black object to old object", but indeed black
is old,
2013-08-01 17:50:13 +08:00
fleuria
c1469a57a2
add comment for clear_all_old()
2013-08-01 17:30:57 +08:00
fleuria
bbbe996e0d
replace gc_assert with mrb_assert
2013-07-25 02:55:51 +08:00
Yukihiro "Matz" Matsumoto
8a298605e6
remove an unused local variable
2013-07-24 23:58:10 +09:00
Yukihiro "Matz" Matsumoto
5146219cbd
revise gc_mark_gray_list() not to cause SEGV on Ubuntu 32bit
2013-07-24 23:47:52 +09:00
Yukihiro "Matz" Matsumoto
4ad4ce6caf
restore once removed mrb_garbage_collect()
2013-07-24 23:31:46 +09:00
Yukihiro "Matz" Matsumoto
e1706e65f9
Merge pull request #1407 from Fleurer/gc-introduce-incremental-gc-step
...
separate out `incremental_gc_step()` from `mrb_incremental_gc()`, and misc minor rename
2013-07-24 07:18:50 -07:00
fleuria
7bfdcace52
fix warning
2013-07-24 18:27:23 +08:00
fleuria
2591922ec2
rename variable_gray_list to atomic_gray_list
2013-07-24 18:22:53 +08:00
fleuria
88eb0f54e9
introduce gc_mark_gray_list(), and cleanup redaunt code with it
2013-07-24 18:22:53 +08:00
fleuria
0c0efc16b0
gc: replace comment "a round of GC" to "a GC cycle"
2013-07-24 16:22:38 +08:00
fleuria
c852626ea7
rename mrb_garbage_collect() to mrb_full_gc()
2013-07-24 16:17:53 +08:00
fleuria
9cc43a970c
introduce incremental_gc_step()
2013-07-24 16:17:53 +08:00
fleuria
9bce2eb8b3
gc: add comments for Generational Mode
2013-07-23 17:04:54 +08:00
fleuria
6a1cb4465b
revise the Two White Parts comments in gc.c
2013-07-22 16:26:59 +08:00
Yukihiro "Matz" Matsumoto
84991d6388
Merge pull request #1392 from Fleurer/gc-rename-advance-phase
...
rename advance_phace() to incremental_gc_until(), and cleanup some redundant codes with it.
2013-07-21 17:58:57 -07:00
Yukihiro "Matz" Matsumoto
2daf39ddc8
change else formatting
2013-07-22 09:52:06 +09:00
fleuria
c49e2d766e
cleanup redundant codes with incremental_gc_until()
2013-07-19 12:16:27 +08:00
fleuria
d4f375b48b
rename advance_phase to incremental_gc_until
...
in fact advance_phace() is not really a "phase", but can be used
as an utility function.
2013-07-19 12:01:34 +08:00
Jun Hiroe
16031af1e7
Replace 0 with NULL because set NULL in sturct pointer.
2013-07-14 05:27:39 +09:00
Yukihiro "Matz" Matsumoto
ea4080e9f2
mark stacks in final_marking; close #1359 ; close #1362
2013-07-12 00:23:37 +09:00
Yukihiro "Matz" Matsumoto
8b29f10ba9
factor out context stack marking
2013-07-12 00:15:50 +09:00
Yukihiro "Matz" Matsumoto
b119330158
Merge pull request #1330 from suzukaze/refactor-gc-c
...
Refactor mrb_realloc() func in gc.c.
2013-07-02 04:11:04 -07:00
Jun Hiroe
3c197f6ab1
Refactor mrb_realloc() func in gc.c.
2013-07-01 22:00:08 +09:00
Carson McDonald
d8c4ce8f49
Fix unsigned/signed warning.
2013-07-01 07:03:21 -04:00
fleuria
68f31e94f5
refactor mrb_realloc()
...
remove the redundant codes with mrb_malloc_simple()
2013-06-28 23:15:31 +08:00
Yukihiro "Matz" Matsumoto
3ceeb0be95
add mrb_malloc_simple() that returns NULL on error
2013-06-25 15:38:28 +09:00
kyab
cb05763928
Fix compile warning for abort
2013-06-20 18:00:10 +09:00
Masaki Muranaka
97b9caf892
Check parameters strictly.
...
calloc in C99 is expected to return NULL when nelem * len == 0.
2013-06-11 16:09:12 +09:00
kimu_shu
e720782f81
Add MRB_WORD_BOXING mode (represent mrb_value as a word)
2013-05-26 10:09:17 +09:00
Yukihiro "Matz" Matsumoto
d78f23d28b
fix fiber GC problem
2013-05-26 00:37:44 +09:00
Yukihiro "Matz" Matsumoto
2045a35292
garbage collect context (fiber) properly
2013-05-22 11:05:22 +09:00
Yukihiro "Matz" Matsumoto
5c0b9b703c
primary mruby fiber implementation
2013-05-20 17:54:07 +09:00
Ryan Scott
4acfadfee1
Fixed the each object callback to be more consistent with other callbacks.
2013-05-18 10:55:41 +10:00
Ryan Scott
40d63f7740
Changed the each_object callback so that a pointer is passed for the object, instead of the struct.
2013-05-17 08:02:24 +10:00
Ryan Scott
f62cc5b1ee
Changed the object_count so that it only iterates over the RBasic object, not the full RVALUE known by the GC
2013-05-17 07:41:13 +10:00
Ryan Scott
222918deae
First implementation of ObjectSpace moved outside of gc.c
2013-05-17 07:21:33 +10:00
Ryan Scott
a71bf5e3df
Change in formatting for os_count_objects to be consistent with other functions.
2013-05-12 19:51:51 +10:00
Ryan Scott
279fce05ae
ObjectSpace.count_objects was incorrectly checking if an object was already freed. Amended the count_objects test to ensure the correct distinction
2013-05-12 19:49:56 +10:00
Ryan Scott
0d4227ac04
Implemented ObjectSpace.count_objects to count the number of allocated objects for each type
2013-05-12 18:42:21 +10:00