scalus.uplc.eval
Members list
Type members
Classlikes
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
class CountingBudgetSpenderobject NoBudgetSpenderclass RestrictingBudgetSpenderclass TallyingBudgetSpender
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- class
- Supertypes
-
trait Producttrait Mirrorclass Objecttrait Matchableclass Any
- Self type
-
BuiltinCostModel.type
Attributes
- Supertypes
-
class StackTraceMachineErrorclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
- Known subtypes
-
class DeserializationErrorclass KnownTypeUnliftingError
Attributes
- Supertypes
-
class StackTraceMachineErrorclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
CEK machine implementation based on Cardano Plutus CEK machine.
CEK machine implementation based on Cardano Plutus CEK machine.
The CEK machine is a stack-based abstract machine that is used to evaluate UPLC terms.
Value parameters
- budgetSpender
-
The budget spender implementation
- logger
-
The logger implementation
- params
-
The machine parameters MachineParams
- platformSpecific
-
The platform specific implementation of certain functions used by builtins
Attributes
- See also
- Note
-
The machine is stateless and can be reused for multiple evaluations. All the state is expected to be in the
budgetSpender
andlogger
implementations. - Example
-
val term = LamAbs("x", Apply(Var(NamedDeBruijn("x", 0)), Var(NamedDeBruijn("x", 0)))) val cek = new CekMachine(MachineParams.defaultParams, NoBudgetSpender, NoLogger, JVMPlatformSpecific) val res = cek.runCek(term)
- Supertypes
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- class
- Supertypes
-
trait Producttrait Mirrorclass Objecttrait Matchableclass Any
- Self type
-
CekMachineCosts.type
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
Attributes
- Supertypes
-
trait Enumtrait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
trait FiveArgumentsclass ConstantCosttrait FourArgumentsclass ConstantCosttrait OneArgumentclass ConstantCostclass LinearInXtrait SixArgumentsclass ConstantCosttrait ThreeArgumentsclass ConstantCostclass LinearInMaxYZclass LinearInXclass LinearInYclass LinearInYAndZclass LinearInZclass LiteralInYOrLinearInZclass QuadraticInZtrait TwoArgumentsclass AddedSizesclass ConstAboveDiagonalclass ConstBelowDiagonalclass ConstOffDiagonalclass ConstantCostclass LinearInXclass LinearInXAndYclass LinearInYclass LinearOnDiagonalclass MaxSizeclass MinSizeclass MultipliedSizesclass QuadraticInXAndYclass QuadraticInYclass SubtractedSizesShow all
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
class DefaultCostingFun[M]
Attributes
- Supertypes
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait CostingFunclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class BuiltinExceptionclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class StackTraceMachineErrorclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
trait Enumtrait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
ExMemory.type
Attributes
- Companion
- object
- Supertypes
- Known subtypes
-
class ConstantCost
Attributes
- Companion
- trait
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
FiveArguments.type
Attributes
- Companion
- object
- Supertypes
- Known subtypes
-
class ConstantCost
Attributes
- Companion
- trait
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
FourArguments.type
When invoking integerToByteString
built-in function, its second argument is a built-in Integer but with a different size measure, specifying the width (in bytes) of the output bytestring (zero-padded to the desired size). The memory consumed by the function is given by w
, not the size of w
. Its MemoryUsage
is equal to the number of eight-byte words required to contain w
bytes, allowing its costing function to work properly.
When invoking integerToByteString
built-in function, its second argument is a built-in Integer but with a different size measure, specifying the width (in bytes) of the output bytestring (zero-padded to the desired size). The memory consumed by the function is given by w
, not the size of w
. Its MemoryUsage
is equal to the number of eight-byte words required to contain w
bytes, allowing its costing function to work properly.
Attributes
- See also
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait CostingFunclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class BuiltinExceptionclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
Attributes
- Supertypes
-
class RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
- Known subtypes
-
class BuiltinExceptionclass DeserializationErrorclass KnownTypeUnliftingErrorclass StackTraceMachineErrorclass BuiltinErrorclass EvaluationFailureclass MissingCaseBranchclass NonConstrScrutinizedclass OutOfExBudgetErrorclass UnknownBuiltinShow all
The Plutus CEK machine parameters.
The Plutus CEK machine parameters.
Value parameters
- builtinCostModel
-
The builtin cost model
- machineCosts
-
The machine costs
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- class
- Supertypes
-
trait Producttrait Mirrorclass Objecttrait Matchableclass Any
- Self type
-
MachineParams.type
Attributes
- Companion
- object
- Supertypes
-
class Objecttrait Matchableclass Any
Attributes
- Companion
- trait
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
MemoryUsage.type
Attributes
- Supertypes
-
class StackTraceMachineErrorclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
- Self type
-
NoBudgetSpender.type
Attributes
- Supertypes
-
class StackTraceMachineErrorclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class StackTraceMachineErrorclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class StackTraceMachineErrorclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- object
- Supertypes
- Known subtypes
-
class ConstantCostclass LinearInX
Attributes
- Companion
- trait
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
OneArgument.type
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class StackTraceMachineErrorclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class StackTraceMachineErrorclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
Plutus VM facade.
Plutus VM facade.
Value parameters
- platformSpecific
-
The platform specific implementation of certain functions used by VM builtins
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
object VM
Attributes
- Supertypes
Attributes
- Supertypes
-
trait Enumtrait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- object
- Supertypes
- Known subtypes
-
class ConstantCost
Attributes
- Companion
- trait
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
SixArguments.type
Attributes
- Supertypes
-
class MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
- Known subtypes
-
class BuiltinErrorclass EvaluationFailureclass MissingCaseBranchclass NonConstrScrutinizedclass OutOfExBudgetErrorclass UnknownBuiltinShow all
Attributes
- Supertypes
-
trait Enumtrait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
Attributes
- Supertypes
Attributes
- Companion
- object
- Supertypes
- Known subtypes
-
class ConstantCostclass LinearInMaxYZclass LinearInXclass LinearInYclass LinearInYAndZclass LinearInZclass LiteralInYOrLinearInZclass QuadraticInZShow all
Attributes
- Companion
- trait
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
ThreeArguments.type
Attributes
- Companion
- object
- Supertypes
- Known subtypes
-
class AddedSizesclass ConstAboveDiagonalclass ConstBelowDiagonalclass ConstOffDiagonalclass ConstantCostclass LinearInXclass LinearInXAndYclass LinearInYclass LinearOnDiagonalclass MaxSizeclass MinSizeclass MultipliedSizesclass QuadraticInXAndYclass QuadraticInYclass SubtractedSizesShow all
Attributes
- Companion
- trait
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
TwoArguments.type
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
c00 + c10x + c01y + c20x^2 + c11cy + c02y^2
c00 + c10x + c01y + c20x^2 + c11cy + c02y^2
Attributes
- Note
-
Minimum values for two-variable quadratic costing functions. Unlike most of our other costing functions our use cases for two-variable quadratic costing functions may require one or more negative coefficients, so there's a danger that we could return a negative cost. This is unlikely, but we make certain that it never happens by returning a result that is at never smaller than a minimum value that is stored along with the coefficients of the function.
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class StackTraceMachineErrorclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
class StackTraceMachineErrorclass MachineErrorclass RuntimeExceptionclass Exceptionclass Throwabletrait Serializableclass Objecttrait Matchableclass AnyShow all