High level summary
We made significant improves to Plinth (formerly Plutus Tx) in the past few weeks:
- Plinth compiler improvements
- Added compiler flag
inline-callsite-growth
, for setting the inlining threshold for callsites. 0 disables inlining a binding at a callsite if it increases the AST size;n
allows inlining if the AST size grows by no more thann
. Keep in mind that oing so does not mean the final program will be bigger, since inlining can often unlock further optimizations. - PlutusTx.Lift.liftCode and related functions now apply the default PIR and UPLC optimizations during code lifting. This could lead to significantly more efficient scripts when using lifting.
- Added compiler flag
- Plinth library improvements
- Added module
PlutusTx.BuiltinList
, containing functions for operating onBuiltinList
. - Augmented module
PlutusTx.Data.List
, adding more functions for operating on Data encodedList
. This includes, among others,PlutusTx.Data.List.destructList
, which takes a list along with a list of desired indices, and generates variables bound to the elements at those indices, as well asPlutusTx.Data.List.caseList
andcaseList'
, for matching onList
s. - Augmented module
PlutusTx.Data.AssocMap
, adding more functions for operating on Data encodedMap
.
- Added module
Additionally, we added two new pages to the Plinth user guide:
On the Plutus Core side, we made progress on features targeting the next Hard Fork. This includes
- costing, conformance testing and metatheory for the
dropList
primitive - costing and metatheory of builtin arrays
- costing for the modular exponentiation primitive
- reviewing the CIP on builtin
Value
- investigating approaches for enabling casing on builtin types
Regarding certified compilation, we worked on adding more tests to the certifier and resolving the issues it uncovered
Low level summary
Key Pull Requests Merged
- Add PlutusTx.BuiltinList module
- Metatheory for dropList
- Proper purity check for unsaturated builtins
- Introduce the inline-callsite-growth flag for setting inliner aggressiveness
- Add PlutusTx.Data.List.caseList and caseList'
- Add nil and singleton to PlutusTx.Data.List
- Run default PIR/UPLC optimizations during code lifting
- Add PlutusTx.Data.List.destructList
Issues In Progress
- Caseing on values of built-in types
- Costing for modular exponentiation (in plutus-private)
- Costing of builtin functions operating on builtin arrays (in plutus-private)
- Add negative certifier tests (in plutus-private)