2009-10-07 15:05:09 -04:00
|
|
|
namespace factor
|
|
|
|
{
|
|
|
|
|
2009-10-09 04:20:50 -04:00
|
|
|
static const cell card_starts_inside_object = 0xff;
|
2009-10-09 03:05:31 -04:00
|
|
|
|
2009-10-20 14:47:04 -04:00
|
|
|
struct object_start_map {
|
|
|
|
cell size, start;
|
2009-10-09 04:20:50 -04:00
|
|
|
card *object_start_offsets;
|
|
|
|
card *object_start_offsets_end;
|
2009-10-07 15:05:09 -04:00
|
|
|
|
2009-10-25 00:02:58 -04:00
|
|
|
explicit object_start_map(cell size_, cell start_);
|
2009-10-20 14:47:04 -04:00
|
|
|
~object_start_map();
|
2009-10-07 15:05:09 -04:00
|
|
|
|
2009-10-14 20:55:02 -04:00
|
|
|
cell first_object_in_card(cell card_index);
|
2009-10-13 22:16:04 -04:00
|
|
|
cell find_object_containing_card(cell card_index);
|
2009-10-09 04:20:50 -04:00
|
|
|
void record_object_start_offset(object *obj);
|
|
|
|
void clear_object_start_offsets();
|
2009-11-01 21:15:42 -05:00
|
|
|
void update_card_for_sweep(cell index, u16 mask);
|
|
|
|
void update_for_sweep(mark_bits<object> *state);
|
2009-10-07 15:05:09 -04:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|