- Plinth 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 doing so does not mean the final program will be bigger, since inlining can often unlock further optimizations.
-
Changed the default value of compiler flag
PlutusTx.Plugin:preserve-logging
to true. -
The Plinth compiler now inlines fixed point operators by default. This can be turned off by using
no-inline-fix
orconservative-optimisation
. -
The Plinth inliner now inlines local bindings (in addition to top-level bindings) with
INLINE
pragmas. -
AsData
now avoids creating strict dead bindings (which were previously created for unused fields).
instance IsString TokenName
as it wasn't compilable by the plutus-tx-plugin anyway.instance IsString CurrencySymbol
as it wasn't compilable by the plutus-tx-plugin anyway.
-
instance IsString BuiltinByteStringUtf8
allows using string literals to construct UTF8-encodedBuiltinByteString
values. -
instance IsString BuiltinByteStringHex
allows using string literals to construct Base16-encoded (aka HEX)BuiltinByteString
values.
BuiltinByteString
literals changed to avoid UTF8 encoding and now can represent bytes in the range 0-255 directly, e.g."\x00\x01\x02" :: BuiltinByteString
orstringToBuiltinByteString "\0\42\255"
.
- A compiler flag
simplifier-evaluate-builtins
that controls whether to run the simplifier pass that evaluates fully saturated builtins at compile time.
- Enabled the draft modularExponentation builtin.
- Added two Plutus Tx compiler options,
preserve-logging
andinline-constants
. Optionconservative-optimisation
implies (or negates)relaxed-float-in
,inline-constants
andpreserve-logging
, but previously onlyrelaxed-float-in
is a plugin option by itself.
- Compiler flag
simplifier-remove-dead-bindings
does what it should now.
- (&&) and (||) now short-circuit regardless of the GHC optimisations.
-
Added
ByteStringToInteger
andIntegerToByteString
builtins to the pluugin. -
added constant inlining to inlining optimisation passes
- 'conservative-mode' now also turns off constant inlining
- The group elements
bls12_381_G1_zero
andbls12_381_G1_generator
have been replaced with bytestrings calledbls12_381_G1_compressed_zero
andbls12_381_G1_compressed generator
, and similarly forbls12_381_G2_zero
andbls12_381_G2_generator
. PlutusTx scripts should applybls12_381_G2_uncompress
orbls12_381_G2_uncompress
to the compressed versions to recover the group elements.
- A more informative error message when the plugin encounters a literal range.
- Updated the Plutus Tx compiler to make the "Unsupported feature: Cannot case on a value on type" error happen less often (if not eliminating it entirely).
- Better support for
RuntimeRep
-polymorphic code. In particular, this means we can now handle the code that GHC generates for pattern synonyms.
- Add a new PlutusTx compiler option,
dump-compilation-trace
. It can be used to dump the full trace of compiling GHCCoreExpr
s into PIRTerm
s for debugging.
- The plugin could generate exponentially large code from nested pattern matches with many default cases. This could happen when using pattern synonyms. This no longer happens.
- New built-in types and functions for BLS12-381 operations.
- GHC 9.6 support
target-version
option that allows you to choose the target PLC version for the generated code.
INLINE
pragmas from Haskell source are now propagated to Plutus IR, so they are guaranteed to be inlined.