racket/pkgs/racket-test-core/tests/racket
Matthew Flatt 2661d46929 toward deterministic bytecode generation
Progress toward making the bytecode compiler deterministic, so that a
fresh `make base` always produces exactly the same bytecode from the
same sources. Most changes involve avoiding hash-table order
dependencies and adjusting scope identity. The namespace used to load
a reader extension is also better defined. Plus many other little
changes.

The identity of a scope that is unmarshaled from a bytecode file now
incorporates the hash of the file, and the relative order of scopes is
preserved in a bytecode file. This combination allows compilation to
start with modules that loaded and compiled in different orders
(including delayed loading of bytecode fragments within one file).

Formerly, a reader extension triggered by `#lang` or `#reader` was
loaded in whatever namespace happens to be current. That's
unpredictable and can pollute a module build at the level of bytecode.
To help make builds deterministic, reader extensions are now loaded in
a root namespace of the current namespace.

Deterministic compilation in general relies on deterministic macros.
The two most common ways for a macro to be non-deterministic are by
using `gensym` (use `generate-temporaries`, instead) and by using an
unsorted hash-table traversal (don't do that).

At this point, bytecode generation is unlikely to be completely
deterministic, since I uncovered non-determinism mostly by iterating
attempts over the base collections. For now, the intent is not to
provide guarantees outside of the compilation of the base collections
--- but "more deterministic" is likely to be useful in the short run,
and we can improve further in the long run.
2015-08-07 15:48:39 -06:00
..
lang Use racket instead of scheme. Fixes dependency issues. 2014-12-15 02:45:32 -05:00
.gitignore Ignore files here too. 2014-12-15 02:55:15 -05:00
all.rktl Move contents of unstable/hash to racket/hash. 2015-07-20 16:00:52 -05:00
async-channel.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
basic.rktl toward deterministic bytecode generation 2015-08-07 15:48:39 -06:00
boundmap-test.rktl switch to set-of-scopes expander 2015-07-16 14:20:00 -06:00
bytes.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
censor.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
chaperone.rktl fix impersonator-property:application-mark propagation 2015-08-07 05:30:25 -06:00
cm.rktl Another couple "racket-test-core" fixes. 2014-12-18 16:32:02 -05:00
cmdline.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
collects.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
contmark.rktl Reduce and fix dependencies for "racket-core-test". 2014-12-15 19:07:43 -05:00
control.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
core-tests.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
cstruct.rktl require a #:offset keyword before a field offset in define-cstruct 2015-02-14 18:40:20 -07:00
date.rktl do tests for f2bacdc6f properly 2015-01-21 10:05:09 -06:00
deep.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
dict.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
expand.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
extflonum.rktl fix extflonum-printing test when extflonums are disabled 2015-02-17 19:12:29 -07:00
ffi-lock.rkt fix memory-management problem with #:lock-name 2015-06-26 07:44:43 +08:00
file.rktl Windows: change delete-{file,directory} to attempt permission correction 2015-01-13 11:58:36 -07:00
filelib.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
fixnum.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
flonum.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
for-submod.rkt Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
for-util.rkt Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
for.rktl Make for raise better error message if binding clauses are bad. 2015-04-10 13:56:42 -06:00
foreign-test.c Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
foreign-test.rktl JIT: inline ptr-ref and ptr-set! 2015-07-02 15:59:35 -06:00
function.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
generator.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
has-submod.rkt Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
hash.rktl Move contents of unstable/hash to racket/hash. 2015-07-20 16:00:52 -05:00
id-set-test.rktl add free-id sets 2015-05-04 19:05:07 -04:00
id-table-test.rktl switch to set-of-scopes expander 2015-07-16 14:20:00 -06:00
info.rkt Increase timeout on core tests. 2015-07-21 15:40:09 -04:00
iostream.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
letrec.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
list.rktl check-duplicate -> check-duplicates 2015-07-20 16:00:53 -05:00
loadable.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
loadtest.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
logger.rktl Move part of unstable/logging to racket/logging. 2015-07-23 12:22:51 -05:00
macro.rktl fix expansion loop in a definition context 2015-07-20 13:20:03 -06:00
math.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
moddep.rktl Finish fixing dependencies of "racket-test-core". 2014-12-19 11:35:39 -05:00
modprot.rktl switch to set-of-scopes expander 2015-07-16 14:20:00 -06:00
module-reader.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
module.rktl fix test for module cache 2015-07-25 20:38:12 -06:00
name.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
namespac.rktl adjust transfer of compiled in one namespace and run in another 2015-07-22 10:54:31 -06:00
net-available.rkt Rename to avoid conflict since pkgs is slow. 2014-12-15 02:10:44 -05:00
number.rktl fix integer-length overflow (PR14986) improve performance on integer-length of negative bignums 2015-03-26 11:20:40 -06:00
numstrs.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
object.rktl switch to set-of-scopes expander 2015-07-16 14:20:00 -06:00
optimize.rktl define-inline: fix call with multiple keyword arguments 2015-08-06 14:44:30 -06:00
pack.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
parallel.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
param.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
path.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
pathlib.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
place-utils.rkt Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
place.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
port.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
portlib.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
pp-regression.rktd Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
pretty.rktl pretty-print: fix for a current inspector that sees through internals 2015-01-29 19:33:36 -07:00
print.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
procs.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
prompt-tests.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
prompt.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
quiet.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
read.rktl switch to set-of-scopes expander 2015-07-16 14:20:00 -06:00
readtable.rktl Adjust use of readtable argument in read/recursive 2015-04-15 13:01:58 -06:00
resource.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
rx.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
sandbox.rktl switch to set-of-scopes expander 2015-07-16 14:20:00 -06:00
scheme-tests.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
sequence.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
serialize.rktl Finish fixing dependencies of "racket-test-core". 2014-12-19 11:35:39 -05:00
set.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
setup.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
shared-tests.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
shared.rktl Finish fixing dependencies of "racket-test-core". 2014-12-19 11:35:39 -05:00
srcloc.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
stream.rktl Add stream* to complement stream 2015-06-20 21:43:27 +08:00
string.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
struct.rktl Add prop:object-name. 2015-03-18 09:55:27 -04:00
stx.rktl raise-syntax-error: fix srcloc reporting on #f as 3rd arg 2015-07-29 11:54:18 -06:00
stxparam.rktl switch to set-of-scopes expander 2015-07-16 14:20:00 -06:00
submodule.rktl switch to set-of-scopes expander 2015-07-16 14:20:00 -06:00
subprocess.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
sync.rktl fix interaction of nack-guard-evt and choice-evt 2015-02-12 15:24:45 -07:00
syntax.rktl repair for nexted splicing forms that define the same name 2015-07-29 06:11:13 -06:00
syntaxlibs.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
test.rkt Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
testing.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
thread.rktl Rename to avoid conflict since pkgs is slow. 2014-12-15 02:10:44 -05:00
thrport.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
trace.rktl fix a test 2014-12-19 20:23:49 -07:00
trait.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
udp.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
uni-norm.rktl Unicode 7.0 2015-02-09 11:33:13 -07:00
unicode.rktl Unicode 7.0 2015-02-09 11:33:13 -07:00
unsafe.rktl Split the core racket tests into the "racket-test-core" pkg. 2014-12-15 01:59:56 -05:00
vector.rktl Move tests for SRFIs to "racket-test". 2014-12-18 15:23:44 -05:00
version.rktl Add test for "base" version. 2015-03-20 11:56:05 -04:00
will.rktl compiler: never retain namespace for constantness-test argument 2015-01-19 21:29:54 -07:00