doc/guide/src/Polyvariance.adoc
raw| 1 | = Polyvariance |
| 2 | |
| 3 | Polyvariance is an optimization pass for the <<SXML#>> |
| 4 | <<IntermediateLanguage#>>, invoked from <<SXMLSimplify#>>. |
| 5 | |
| 6 | == Description |
| 7 | |
| 8 | This pass duplicates a higher-order, `let` bound function at each |
| 9 | variable reference, if the cost is smaller than some threshold. |
| 10 | |
| 11 | == Implementation |
| 12 | |
| 13 | * https://github.com/MLton/mlton/blob/master/mlton/xml/polyvariance.fun[`polyvariance.fun`] |
| 14 | |
| 15 | == Details and Notes |
| 16 | |
| 17 | {empty} |