Author: Manuel Jacob <m...@manueljacob.de> Branch: Changeset: r95852:1a274c144a73 Date: 2019-02-06 02:29 +0100 http://bitbucket.org/pypy/pypy/changeset/1a274c144a73/
Log: Raise ValueError in nonmoving_raw_ptr_for_resizable_list() if running on RevDB. On RevDB, raw and GC'ed memory must be separated. All callers are supposed to handle this ValueError and fall back to the unoptimized case. diff --git a/rpython/rlib/rgc.py b/rpython/rlib/rgc.py --- a/rpython/rlib/rgc.py +++ b/rpython/rlib/rgc.py @@ -1406,6 +1406,11 @@ return _ResizableListSupportingRawPtr(lst) def nonmoving_raw_ptr_for_resizable_list(lst): + if must_split_gc_address_space(): + raise ValueError + return _nonmoving_raw_ptr_for_resizable_list(lst) + +def _nonmoving_raw_ptr_for_resizable_list(lst): assert isinstance(lst, _ResizableListSupportingRawPtr) return lst._nonmoving_raw_ptr_for_resizable_list() @@ -1450,7 +1455,7 @@ return hop.inputarg(hop.args_r[0], 0) class Entry(ExtRegistryEntry): - _about_ = nonmoving_raw_ptr_for_resizable_list + _about_ = _nonmoving_raw_ptr_for_resizable_list def compute_result_annotation(self, s_list): from rpython.rtyper.lltypesystem import lltype, rffi _______________________________________________ pypy-commit mailing list pypy-commit@python.org https://mail.python.org/mailman/listinfo/pypy-commit