14 karma · joined Oct 27, 2012 (14y ago) · 4 submissions
comment 12y ago · link · parent
comment 12y ago · link · parent
Two details. First, cloning a complete page and calling remap_file_pages() only occurs once on a given page, so if a number of transactions repeatedly modify the same objects, they will already be in un-shared pages (the page are tentatively shared again during major collection only).
And second, about the exact time at which "read-write" conflicts are found: when we commit, we know which objects we modified, so we can check if someone else has read them and abort that other thread instead. We never need to walk the list of all read objects: it is enough to check if some (smaller number of) objects were read or not by another thread. So the "list" of all read objects is implemented as a byte mask over all objects.
comment 14y ago · link · parent
The HTM buffer is big enough if the goal is "only" to remove the GIL. It's going to be a 10-lines patch to CPython or PyPy (yes, really!). The GIL is often made into a big issue, but in my opinion removing it isn't the final solution to all multicore troubles in Python: that's just the first step.