Skip to content

Commit

Permalink
Add documentation on building, testing, benchmarking (haskell-unorder…
Browse files Browse the repository at this point in the history
  • Loading branch information
sjakobi authored Mar 1, 2022
1 parent c482379 commit 58c455e
Show file tree
Hide file tree
Showing 2 changed files with 64 additions and 2 deletions.
60 changes: 60 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# Contributing

## Building, testing, benchmarking

Building the library:

```
cabal build
```

Running the testsuite:

```
cabal test
```

Viewing the test options:

```
cabal run tests -- --help
```

Running a specific property test with an increased number of test cases
(default: 100 cases):

```
cabal run tests -- -p '/All.Properties.Data.HashSet.basic interface.member/' --quickcheck-tests 100_000
```

Running the benchmarks:

```
cabal bench
```

Viewing the benchmark options:

```
cabal run benches -- --help
```

Running a specific benchmark with a reduced target standard deviation (default:
5%):

```
cabal run benches -- -p /All.HashMap.lookup-miss.ByteString/ --stdev 1
```

To include comparison benchmarks for `containers` and `hashmap` uncomment the
`cpp-options` in the benchmark section of `unordered-containers.cabal`:

```
cpp-options: -DBENCH_containers_Map -DBENCH_containers_IntMap -DBENCH_hashmap_Map
```

### References

* [Documentation for `cabal`](https://cabal.readthedocs.io/en/latest/)
* [Documentation for our testing framework, `tasty`](https://github.com/UnkindPartition/tasty#readme)
* [Documentation for our benchmark framework, `tasty-bench`](https://github.com/Bodigrim/tasty-bench#readme)
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ performance critical use, both in terms of large data quantities and high speed.

The declared cost of each operation is either worst-case or amortized, but
remains valid even if structures are shared.
For developer and contributor documentation see the

For background information and design considerations on this package see the
[Developer Guide](docs/developer-guide.md).

For practical advice for contributors see [`CONTRIBUTING.md`](CONTRIBUTING.md).

0 comments on commit 58c455e

Please sign in to comment.