Skip to content

Commit

Permalink
mention Cython API in readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Stefan Behnel committed Jun 4, 2017
1 parent c43f446 commit 1009af5
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@ FastRLock
---------

This is a C-level implementation of a fast, re-entrant, optimistic lock for CPython.
It is written in `Cython <http://cython.org>`_.
It is a drop-in replacement for
`threading.RLock <https://docs.python.org/3/library/threading.html#threading.RLock>`_.
FastRLock is implemented in `Cython <http://cython.org>`_ and also provides a C-API
for direct use from Cython code via ``from fastrlock cimport rlock``.

Under normal conditions, it is about 10x faster than threading.RLock in Python 2.7
because it avoids all locking unless two or more threads try to acquire it at the
same time. Under congestion, it is still about 10% faster than RLock due to being
Expand Down

0 comments on commit 1009af5

Please sign in to comment.