Skip to content

Commit

Permalink
Document generating the site and serving it in the README
Browse files Browse the repository at this point in the history
  • Loading branch information
rwstauner committed May 8, 2024
1 parent 6c5d0fa commit 9b44918
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ For that reason, where we-the-authors provide official numbers they will usually

## How to Use this Repo

### Benchmark data

You can run `./basic_benchmark.rb` to clone appropriate other repositories (yjit, yjit-bench) and run the benchmarks. You can also specify one or more benchmark names on the command line to run only those benchmarks: `./basic_benchmark.rb activerecord`

`basic_benchmark.rb` also accepts many other parameters, such as a `--skip-git-updates` parameter for runs after the first to not "git pull" its repos and rebuild Ruby.
Expand All @@ -39,6 +41,24 @@ Use `basic_report.rb --help` to get started. There are several different reports

You can find older examples of data-gathering scripts using `git log -- runners` (to see files that used to be in the "runners" directory) and post-processing scripts in the "formatters" directory.


### speed.yjit.org site

After collecting some data with `basic_benchmark.rb` you can generate the html
site (hosted at speed.yjit.org) with a simple command:

`site/exe serve`

This will move files from `./data/` into a `build` directory,
generate all the html files, and start a web server where you can view the site at `localhost:8000`.

Some of the reports are built using `lib/yjit-metrics` and have templates in
`lib/yjit-metrics/report_templates`.
The rest of the files that build the site are found beneath `site`.
There are `erb` files to generate additional pages
and the script that does all the file rendering in `site/_framework/`.


## TruffleRuby

Our experience has been that the JVM (non-default) version gets better results than the native/SubstrateVM version, so if you are going to install a release we recommend the truffleruby+graalvm variant (with ruby-build) or truffleruby-graalvm (with ruby-install).
Expand Down

0 comments on commit 9b44918

Please sign in to comment.