The Racket repository
Go to file
Sam Tobin-Hochstadt 50a2cb32cb Initial implementation of 3x3 and 4x4 Toom-Cook multiplication.
This speeds up `(factorial 1000000)` (using factorial from math/number-theory)
by about 3x, and the conversion of the result to a string by about 2x.

Benchmark:

    #lang racket
    (require math/number-theory)
    (define n (time (factorial 1000000)))
    (define s (time (number->string n)))
    (string-length s)

Current Racket CS:
cpu time: 19135 real time: 19137 gc time: 372
cpu time: 33416 real time: 33418 gc time: 463

Current Racket BC (GMP is really fast):
cpu time: 1465 real time: 1465 gc time: 51
cpu time: 3661 real time: 3659 gc time: 3

This PR:
cpu time: 6173 real time: 6172 gc time: 168
cpu time: 17846 real time: 17847 gc time: 377

Cutoff between Karatsuba and Toom3 estimated by mflatt.
Cutoff between Toom3 & Toom4 guessed.
2021-05-07 10:27:09 -04:00
.github Run workflow directly in VM (#3731) 2021-03-19 18:23:29 +01:00
pkgs fix typo in base64.scrbl 2021-05-07 11:24:56 -03:00
racket Initial implementation of 3x3 and 4x4 Toom-Cook multiplication. 2021-05-07 10:27:09 -04:00
.gitattributes Don't include git files in archives. 2010-05-12 01:46:05 -04:00
.gitignore Fix typo. 2019-06-21 12:32:37 -05:00
.lgtm.yml Fetch PB to start LGTM build 2020-08-07 12:17:17 +02:00
.mailmap Minor metadata changes. 2019-10-15 08:09:32 -04:00
.makefile makefile: fix pb-fetch after starting with --single-branch mode 2021-05-03 16:42:01 -06:00
build.md build guide: Chez Scheme for Racket is no longer in a separate repo 2021-04-07 06:50:42 -06:00
LICENSE update LICENSE to use "CS" and "BC" 2021-01-15 09:32:59 -07:00
Makefile makefile: fix pb-fetch after starting with --single-branch mode 2021-05-03 16:42:01 -06:00
README.md Fix README 2020-09-06 09:03:42 -04:00

Racket is a general-purpose programming language and an ecosystem for language-oriented programming.

This repository holds the source code for the core of Racket plus some related packages. The rest of the Racket distribution source code is in other repositories, mostly under the Racket GitHub organization.

Quick Start

Pre-built versions of Racket for a variety of operating systems and architectures, as well as convenient source distributions are available at

https://download.racket-lang.org

Racket comes with extensive documentation, including several tutorials. You can read all of this documentation, as well as documentation for third-party packages at

https://docs.racket-lang.org

Building from Source

For information on building Racket from this repository, see the Build Guide.

Contributing

Contribute to Racket by submitting a pull request, joining the development mailing list, or visiting the IRC or Slack channels.

By making a contribution, you are agreeing that your contribution is licensed under the LGPLv3, Apache 2.0, and MIT licenses. Those licenses are available in this repository in the files racket/src/LICENSE-LGPL.txt, racket/src/LICENSE-APACHE.txt, and racket/src/LICENSE-MIT.txt.

See the Racket Build Guide for more guidance on contributing.

The Friendly Environment Policy contains guidelines on expected behavior within the Racket community.

License

Racket is free software; see LICENSE for more details.