mirror of
https://github.com/polysemy-research/polysemy.git
synced 2024-12-02 11:54:06 +03:00
Add performance instructions to README (#185)
This commit is contained in:
parent
011530bba1
commit
c53357ca92
17
README.md
17
README.md
@ -214,3 +214,20 @@ You're going to want to stick all of this into your `package.yaml` file.
|
|||||||
- TypeOperators
|
- TypeOperators
|
||||||
- TypeFamilies
|
- TypeFamilies
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Stellar Engineering - Aligning the stars to optimize `polysemy` away
|
||||||
|
|
||||||
|
Several things need to be in place to fully realize our performance goals:
|
||||||
|
|
||||||
|
- GHC Version
|
||||||
|
- GHC 8.9+
|
||||||
|
- Your code
|
||||||
|
- The module you want to be optimized needs to import `Polysemy.Internal` somewhere in its dependency tree (sufficient to `import Polysemy`)
|
||||||
|
- GHC Flags
|
||||||
|
- `-O` or `-O2`
|
||||||
|
- `-flate-specialise` (this should be automatically turned on by the plugin, but it's worth mentioning)
|
||||||
|
- Plugin
|
||||||
|
- `-fplugin=Polysemy.Plugin`
|
||||||
|
- Additional concerns:
|
||||||
|
- additional core passes (turned on by the plugin)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user