def __init__(self, config, space_size=4096, min_next_collect_after=128, **kwds): import py py.test.skip("the 'markcompact' gc needs fixing for custom tracers") # MovingGCBase.__init__(self, config, **kwds) self.space_size = space_size self.min_next_collect_after = min_next_collect_after
def __init__(self, config, chunk_size=DEFAULT_CHUNK_SIZE, space_size=4096, max_space_size=sys.maxint // 2 + 1): self.param_space_size = space_size self.param_max_space_size = max_space_size MovingGCBase.__init__(self, config, chunk_size)
def __init__(self, config, space_size=4096, max_space_size=sys.maxint // 2 + 1, **kwds): self.param_space_size = space_size self.param_max_space_size = max_space_size MovingGCBase.__init__(self, config, **kwds)
def __init__(self, chunk_size=DEFAULT_CHUNK_SIZE, space_size=4096, max_space_size=sys.maxint//2+1): MovingGCBase.__init__(self) self.space_size = space_size self.max_space_size = max_space_size self.gcheaderbuilder = GCHeaderBuilder(self.HDR) self.AddressStack = get_address_stack(chunk_size) self.AddressDeque = get_address_deque(chunk_size) self.finalizer_lock_count = 0 self.red_zone = 0
def setup(self): if self.config.gcconfig.debugprint: self.program_start_time = time.time() self.space = llarena.arena_malloc(self.space_size, True) ll_assert(bool(self.space), "couldn't allocate arena") self.free = self.space self.top_of_space = self.space + self.next_collect_after MovingGCBase.setup(self) self.objects_with_finalizers = self.AddressDeque() self.objects_with_weakrefs = self.AddressStack() self.tid_backup = lltype.nullptr(self.TID_BACKUP)
def setup(self): if self.config.gcconfig.debugprint: self.program_start_time = time.time() self.tospace = llarena.arena_malloc(self.space_size, True) ll_assert(bool(self.tospace), "couldn't allocate tospace") self.top_of_space = self.tospace + self.space_size self.fromspace = llarena.arena_malloc(self.space_size, True) ll_assert(bool(self.fromspace), "couldn't allocate fromspace") self.free = self.tospace MovingGCBase.setup(self) self.objects_with_finalizers = self.AddressDeque() self.objects_with_weakrefs = self.AddressStack()
def setup(self): self.space_size = self.param_space_size self.next_collect_after = self.param_space_size / 2 # whatever... if self.config.gcconfig.debugprint: self.program_start_time = time.time() self.space = llarena.arena_malloc(self.space_size, True) ll_assert(bool(self.space), "couldn't allocate arena") self.free = self.space self.top_of_space = self.space + self.next_collect_after MovingGCBase.setup(self) self.objects_with_finalizers = self.AddressDeque() self.objects_with_weakrefs = self.AddressStack() self.tid_backup = lltype.nullptr(self.TID_BACKUP)
def setup(self): envsize = env.read_from_env("PYPY_MARKCOMPACTGC_MAX") if envsize >= 4096: self.space_size = envsize & ~4095 mincollect = env.read_from_env("PYPY_MARKCOMPACTGC_MIN") if mincollect >= 4096: self.min_next_collect_after = mincollect # self.program_start_time = time.time() self.space = llarena.arena_malloc(self.space_size, False) if not self.space: raise CannotAllocateGCArena self.free = self.space MovingGCBase.setup(self) self.objects_with_finalizers = self.AddressDeque() self.tid_backup = lltype.nullptr(TID_BACKUP) self.next_collect_after = self.next_collection(0, 0, 0)
def setup(self): envsize = env.read_from_env('PYPY_MARKCOMPACTGC_MAX') if envsize >= 4096: self.space_size = envsize & ~4095 mincollect = env.read_from_env('PYPY_MARKCOMPACTGC_MIN') if mincollect >= 4096: self.min_next_collect_after = mincollect #self.program_start_time = time.time() self.space = llarena.arena_malloc(self.space_size, False) if not self.space: raise CannotAllocateGCArena self.free = self.space MovingGCBase.setup(self) self.objects_with_finalizers = self.AddressDeque() self.tid_backup = lltype.nullptr(TID_BACKUP) self.next_collect_after = self.next_collection(0, 0, 0)
def setup(self): #self.total_collection_time = 0.0 self.total_collection_count = 0 self.space_size = self.param_space_size self.max_space_size = self.param_max_space_size self.red_zone = 0 #self.program_start_time = time.time() self.tospace = llarena.arena_malloc(self.space_size, True) ll_assert(bool(self.tospace), "couldn't allocate tospace") self.top_of_space = self.tospace + self.space_size self.fromspace = llarena.arena_malloc(self.space_size, True) ll_assert(bool(self.fromspace), "couldn't allocate fromspace") self.free = self.tospace MovingGCBase.setup(self) self.objects_with_finalizers = self.AddressDeque() self.objects_with_weakrefs = self.AddressStack()
def __init__(self, config, chunk_size=DEFAULT_CHUNK_SIZE, space_size=4096): import py; py.test.skip("Disabled for now, sorry") self.param_space_size = space_size MovingGCBase.__init__(self, config, chunk_size)
def __init__(self, config, chunk_size=DEFAULT_CHUNK_SIZE, space_size=4096, max_space_size=sys.maxint//2+1): MovingGCBase.__init__(self, config, chunk_size) self.space_size = space_size self.max_space_size = max_space_size self.red_zone = 0
def __init__(self, config, chunk_size=DEFAULT_CHUNK_SIZE, space_size=4096, max_space_size=sys.maxint//2+1): self.param_space_size = space_size self.param_max_space_size = max_space_size MovingGCBase.__init__(self, config, chunk_size)
def __init__(self, config, chunk_size=DEFAULT_CHUNK_SIZE, space_size=4096): MovingGCBase.__init__(self, config, chunk_size) self.space_size = space_size self.next_collect_after = space_size/2 # whatever...
def __init__(self, config, space_size=4096, min_next_collect_after=128, **kwds): MovingGCBase.__init__(self, config, **kwds) self.space_size = space_size self.min_next_collect_after = min_next_collect_after
def marked(self, obj): # should work both if tid contains a CombinedSymbolic (for dying # objects, at this point), or a plain integer. return MovingGCBase.header(self, obj).tid & GCFLAG_MARKBIT
def header_forwarded(self, addr): # like header(), but asserts that we have a forwarding header hdr = MovingGCBase.header(self, addr) if not we_are_translated(): assert is_valid_int(hdr.tid) return hdr
def header(self, addr): # like header(), but asserts that we have a normal header hdr = MovingGCBase.header(self, addr) if not we_are_translated(): assert isinstance(hdr.tid, llgroup.CombinedSymbolic) return hdr
def header_forwarded(self, addr): # like header(), but asserts that we have a forwarding header hdr = MovingGCBase.header(self, addr) if not we_are_translated(): assert isinstance(hdr.tid, int) return hdr
def __init__(self, config, space_size=4096, max_space_size=sys.maxint//2+1, **kwds): self.param_space_size = space_size self.param_max_space_size = max_space_size MovingGCBase.__init__(self, config, **kwds)
def __init__(self, config, chunk_size=DEFAULT_CHUNK_SIZE, space_size=4096): import py py.test.skip("Disabled for now, sorry") self.param_space_size = space_size MovingGCBase.__init__(self, config, chunk_size)