Move "racket/src/cs/bootstrap" from the Racket source repository to
this one, because the bootstrapping implementation needs to track the
Chez Scheme source much more closely than the Racket implementation.
Currently, any Racket v7.1 or later works.
Also update "README.md" and "BUILDING" to get all the information
consistent and in sync with revised build options.
original commit: a9e6e99ea414b4625fe9705e4f3cfd62bbf38ae2
For example, if the number of floating-point registers in "x86_64.ss"
changes, now only one ".def" file has to change instead of 14 ".def"
files.
original commit: c79524cc3eb516d9bee1708c06b80e3688fdd2ff
Makefile and configure improvements turn on more checking with MinGW,
so fix the resulting warnings-as-errors.
original commit: df2ff94b2b878924b5ca925c48253d147f668e79
This commit does four things:
* Adds "pb.ss" and "pb.c", which implement a portable bytecode
backend and interpreter that is intended for bootstrapping. A
single set of pb bootfiles can support bootstrapping on all
platforms --- as long as the C compiler supports a 64-bit integer
type. The pb machine supports foreign calls for only a small set of
recognized prototypes, and it does not support foriegn callables.
Use `./configure --pb` to build the pb variant.
* Changes the kernel's casts between `ptr` and `void*` types. In a pb
build, the `ptr` type can be a 64-bit integer type while `void*` is
a 32-bit pointer type, so casts must go through an intermediate
integer type.
* Adjusts the compiler to accomodate run-time-determined endianness.
Making the compiler agnostic to word size is not practical, but
only a few pieces depend on the target machine's endianness, and
those can generally be deferred to a run-time choice of byte-based
operations. The one exception is that ftype bit fields are not
allowed unless accompanied by an explicit endianness declaration.
* Start reducing duplication among platform-specific makefiles. For
example, `Mf-ta6osx` chains to `Mf-a6osx` to avoid repeating most
of it. A lot more can be done here.
original commit: 97533fa9d8b8400b0dc1a890768c7d30c91257e0
All back ends had essentially the same `define-instruction`, just with
slightly more functionality, checking, or abstraction each case. The
newly shared version better sorts out some inherent run-time checks
versus safe-mode assertions related to fp and non-fp arguments.
original commit: c70836fa04eb33442fd3ca273ce9ca08ce877fec
"Externals" supports fasling with some values lifted out an provided
separately.
Lifting the restriction on source file descriptor paths, formerly to
strings, means that paths can be represented in a different way, and
they can be fasled through a different means than the built-in
encodings.
original commit: b6b0ae67b08f2e9bc8b7fafe5ebad0375b6ce9db
Perform slightly less work on every fasl or unfasl of compiled code
that does not need to support `concatenate-object-files`.
original commit: 410985b062a3e2a4cc48da583167254d4adad2d2
Merge changes in the way that fasl streams are compressed. The new
approach makes compression explicit in the fasl representation, which
means that tricks like uzing zcat on a fasl file will no longer work
(at least not efficiently).
original commit: 167ac7294a2dc400821e4336f0cfc4de621efe97
This first cut is heavy on describing how backends work, because
that's fresh in mind and relevant to ongoing effort.
original commit: 964ce95dc910e6c1825b341bf05492af5903cc82
Commit 88d57da163 incorrectly merged, because the syntax of `mref` has
changed to support unboxed floating-point arithmetic.
original commit: a8eeb536aecc0e0a363aa68d43edafa7d6c9df52
Especially fix problems with `__collect_safe`, but also deallocate
stack space for `&` returns.
original commit: b593b0f14e7a803d8e089f49e266194245504197
Besides adding supportt for `__collect-safe` and other repairs,
introduce a write-write fence with the write barrier, which is
intended to avoid one thread using an object created in another thread
before the object's initializing writes are visible.
original commit: 543bd16739c08e5a8f88c470b52db0f23a27d260
Maintain 16-byte stack alignment (if incoming frames are 16-byte
aligned), because newer versions of gcc count on 16-bit alignment for
some generated SSE instructions.
[This patch is extracted from cisco/ChezScheme#518.
Merging the rest of that change will take longer.]
original commit: 88d57da163ca287ab37534fd858361a035ce7e4a
Besides updating for unboxed floating point, the ppc32 build uses a
return register, and the continuation-attachments implementation was
not right for that mode.
original commit: dd2d01fb26ace819c73f258b9b53739f9dda1d34
Flonum operations like `fltruncate` and `flsin` are implemented by
calling functions from the C library. Unboxing these involves a
generalazation the `foreign-call` intermediate form to handle unboxing
and to work in a non-tail position (especially by telling the register
allocator that caller-saved registers will be trashed). An internal
'atomic convention on a foreign call indicates that no callback into
Scheme is possible, so some setup/teardown (including stashing
callee-saved registers) can be skipped.
original commit: fd89919634d0d5272e046b47bb81bcc66e22a741
Shift addition of boxing as needed into the main loop, infer unboxed
variables and `mref`s, and centralize lifting of the `unboxed-fp`
declaration.
original commit: ed8ca4b6c77bdd436b0dee467a8350a450a44fb3
The comparison was off for 32-bit plaforms, because it didn't allow
fractional increments, The comparison was off for 64-bit platforms,
bbecause it didn't account for round-trip failure when starting from
the largest fixnum.
original commit: 74eb0583ae1b6212fbde459d7486c3d4a0498401
Simplify and normalize backend elements for loading, storing, and
converting floating-point numbers, taking better advantage of
new support for floating-pointer registers.
original commit: 4066af9cf3799392ef785a77da69f7cfff74d2fe
This is a follow-up to 276f8da076, where `(%tc-ref cp)` was supposed
to be preserved by moving it into %cp, but intrinisics for bytevector
arguments can kill %cp. Use a temporary to expose things properly to
the register allocator.
original commit: 3a29db06a452e46e69ebcde524b3b9acb435dec3
This reverts commit aa230ac79bed1efa02779bb7bbcde5c009818b74, so it
can be replaced with a solution that is less clumsy and less fragile.
original commit: 533940fdc6905d810deabb457d7004a031a3ac05