Julien Fischer 853622ad87 Shift most of the STM runtime into the Mercury runtime.
Estimated hours taken: 12
Branches: main

Shift most of the STM runtime into the Mercury runtime.
Rename a lot of the types and functions used by the STM runtime.
Various other fixes and improvements to the STM runtime.

library/exception.m:
	Add a new version of try_stm/4 that is intended for use within
	atomic blocks by user code.  This version filters out and rethrows
	rollback exceptions.

	Rename the existing try_stm/4 to unsafe_try_stm/4.

library/stm_builtin.m:
	Move all the STM runtime support from this module into the
	Mercury runtime.  The foreign_procs in this module now just
	forward their work to the appropriate function or macro there.

	Rename most of the types and functions associated with STM
	so that they better conform to our coding standards.

	Add a unit dummy type for use with atomic blocks that have no
	outputs, for example atomically swapping the values of two
	transaction variables.  This is needed because the call to
	unsafe_try_stm introduced by the source-to-source transformation
	still has to return a value if it succeeds.

runtime/mercury_stm.h:
runtime/mercury_stm.c:
	New files containing the runtime support for STM that was in
	library/stm_builtin.m

	Define thread identity for the low-level C grades.  In such
	grades it just the context address.

	Add a macro that returns the identity of the (Mercury) thread that
	is currently executing.  (The implementation of wait queues will
	need this information.)

runtime/mercury_context.c:
	At program startup initialise the STM lock.

runtime/mercury_conf_param.h:
	Document the macro MR_STM_DEBUG which will be used to
	enable low-level debugging of the STM runtime.

runtime/Mmakefile:
	Add the new files.
2007-09-13 04:40:52 +00:00
2007-09-13 03:35:05 +00:00
2007-02-18 08:01:56 +00:00
2007-07-16 11:45:23 +00:00
2006-12-18 13:00:07 +00:00

Mercury 0.13 may not work on Solaris 10 (SunOS 5.10) due to incompatibilities
with the version of Boehm GC shipped with that version of Mercury.

(The above problem has been fixed in post-0.13 versions of Mercury.)

Also, note that `--linkage static' is not supported on Solaris.  Executables
produced using this option will cause a segmentation fault.
Description
No description provided
Readme MIT 248 MiB
Languages
Mercury 85.3%
C 8.7%
Shell 1.4%
Makefile 1%
JavaScript 1%
Other 2.1%