- 07 Apr, 2016 8 commits
-
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
Mostly, what happens if class-creation fails.
-
Kevin Modzelewski authored
add refcounting annotation to some set function
-
Boxiang Sun authored
-
Kevin Modzelewski authored
-
- 06 Apr, 2016 12 commits
-
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
ie something like "print C().__dict__" The attrwrapper objects don't (arnd probably shouldn't) keep their underlying objects alive. Previous to this commit they would just try to access their freed underlying object and crash. With this commit, object deallocation will check if there is an attrwrapper, and if so convert it to be privately-backed.
-
Kevin Modzelewski authored
-
Marius Wachtler authored
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
First, our implementation of slot_tp_del (what calls Python-level __del__ methods) was pretty bad -- it didn't re-incref the object to keep it alive. Then we had some issues around running destructors at shutdown. I made this section look a bit more like CPython's, but there are still differences.
-
Kevin Modzelewski authored
int positive function refcounting fixing
-
Kevin Modzelewski authored
add refcouting annotation to zip builtin function
-
- 05 Apr, 2016 12 commits
-
-
Boxiang Sun authored
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
ie relax an assertion that doesn't quite check enough anyway.
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
-
Boxiang Sun authored
-
Kevin Modzelewski authored
Represent decref/xdecref operations as opaque functions calls. I think the ideal solution would be to add a custom llvm intrinsic, but I spent a small amount of time looking into that and had trouble figuring out how to do that. So instead, just emit them as patchpoints, and then patch them afterwards with a fixed code sequence. This commit only does this for decref/xdecref because: - they occur much more frequently - they are much more expensive to jit since they involve control flow - forcing the op to fit a C-calling-convention isn't that much overhead, since the register allocator probably would have done that anyway due to the (potential) dealloc call.
-
Kevin Modzelewski authored
I copied subtype_traverse and subtype_clear from cpython but didn't update them to support our hcattrs
-
Marius Wachtler authored
-
Marius Wachtler authored
- fix instruction encoding of: add imm, mem - fix Py_REF_DEBUG when increfing multiple times at once - add missing bjit annotations
-
Kevin Modzelewski authored
small refcounting fixing in tuple
-
- 04 Apr, 2016 8 commits
-
-
Kevin Modzelewski authored
I think they were timing out before
-
Kevin Modzelewski authored
For use on the exception path. Rather than emitting the instructions for a bunch of decrefs, instead just emit a single call to xdecrefAll() Improves performance quite a lot: sre_parse_parse llvm instructions goes from 360k to 80k, and it's 60k if I manually disable cxx fixups. Overall time [which is entirely compile time] goes from 12.5s to 4.4s, though master does it in 1.3s so there's still some work to do. But even if I turn off cxx fixups entirely it still takes 2.9s.
-
Kevin Modzelewski authored
fixups aka the stubs that decref whatever's needed when an exception is thrown I looked into this because most (75%?) of the refcounting overhead comes from the cxx fixups. Previously we would always generate them in the IRGenerator, regardless of whether they were needed. Now they are generated in the refcounter, which knows whether they are needed or not. Unfortunately it looks like they are usually needed, so the gains here aren't that great (saves about 10% llvm instructions whereas cxx fixups in general added about 400% more llvm instructions). I think this is still a good change because it's also necessary in order to use Marius's EH stuff. I think the cost of the fixups is mostly related to the cost of the decrefs that it adds, so even though most of the refcounting overhead seems to be due to adding the cxx fixups, reducing general decref overhead might reduce cxx fixup overhead
-
Boxiang Sun authored
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
Any existing work on top of the unformatted branch might have a hard time merging -- it should work ok to do a format on top of your changes and then merge with this commit.
-
Kevin Modzelewski authored
-
Kevin Modzelewski authored
-