The Racket repository
Go to file
Matthew Flatt 290020c597 ffi/unsafe: add #:lock-name option to _fun and _cprocedure
While `#:in-original-place? #t` provides one way to serialize
foreign calls, it acts as a single lock and requires expensive
context switches. Using an explicit lock can be more efficient
for serializing calls across different places.

For example, running "plot.scrbl" takes 70 seconds on my machine
in the original place and using `#:lock-name` in any place,
while it took 162 seconds in a non-main place with Cairo+Pango
serialization via `#:in-original-place? #t`.

Internally, the named lock combines compare-and-swap with a
place channel. That strategy gives good performance in the case
of no contention, and it cooperates properly with the Racket
scheduler where there is contention.
2015-06-25 10:35:22 +08:00
pkgs ffi/unsafe: add #:lock-name option to _fun and _cprocedure 2015-06-25 10:35:22 +08:00
racket ffi/unsafe: add #:lock-name option to _fun and _cprocedure 2015-06-25 10:35:22 +08:00
.gitattributes Don't include git files in archives. 2010-05-12 01:46:05 -04:00
.gitignore Ignore extra-pkgs/ 2014-12-04 10:44:14 -05:00
.mailmap mailmap updates & fixes. 2013-04-03 18:10:22 -04:00
.travis.yml add mflatt to Travis notification email 2015-03-18 06:44:13 -06:00
appveyor.yml Improve AppVeyor configuration. 2014-12-15 19:56:50 -05:00
INSTALL.txt Makefile: make SRC_CATALOG work for in-place and unix-style 2015-05-03 21:41:46 -07:00
Makefile Makefile: make SRC_CATALOG work for in-place and unix-style 2015-05-03 21:41:46 -07:00
README.txt Professionalism 2014-11-03 06:06:04 -07:00

This is the source code for the main Racket distribution.  See
"INSTALL.txt" for information on building Racket.

License
-------

Racket
Copyright (c) 2010-2014 PLT Design Inc.

Racket is distributed under the GNU Lesser General Public License
(LGPL).  This implies that you may link Racket into proprietary
applications, provided you follow the rules stated in the LGPL.  You can
also modify Racket; if you distribute a modified version, you must
distribute it under the terms of the LGPL, which in particular states
that you must release the source code for the modified software.  

See racket/src/COPYING_LESSER.txt for more information.