# Heap

### Related Docs: object Heap | package theories

#### class Heap extends Theory

Linear Supertypes
Theory, AnyRef, Any
Ordering
1. Alphabetic
2. By inheritance
Inherited
1. Heap
2. Theory
3. AnyRef
4. Any
1. Hide All
2. Show all
Visibility
1. Public
2. All

### Value Members

1. #### final def !=(arg0: Any): Boolean

Definition Classes
AnyRef → Any
2. #### final def ##(): Int

Definition Classes
AnyRef → Any
3. #### final def ==(arg0: Any): Boolean

Definition Classes
AnyRef → Any

14. #### val alloc: MonoSortedIFunction

Functions and predicates of the theory Assuming Address as address sort name, Heap as heap sort name, and Obj as the selected object sort.

Functions and predicates of the theory Assuming Address as address sort name, Heap as heap sort name, and Obj as the selected object sort. Some function / predicate names incorporate the defined / selected names. *************************************************************************** Public functions and predicates *************************************************************************** emptyHeap : () --> Heap alloc : Heap x Obj --> Heap x Address (allocResHeap) read : Heap x Address --> Obj write : Heap x Address x Obj --> Heap valid (isAlloc) : Heap x Address --> Bool deAlloc : Heap --> Heap nthAddress : Nat --> Address

batchAlloc : Heap x Obj x Nat --> Heap x AddressRange (batchAllocResHeap) batchWrite : Heap x AddressRange x Obj --> Heap nth : AddressRange x Nat --> Address within : AddressRange x Address --> Bool

0 1 writeADT : Obj x Obj --> Heap * Updates the ADT's field (described by a read to 0) using value (1) *************************************************************************** Private functions and predicates *************************************************************************** counter : Heap --> Nat

* Below two functions are shorthand functions to get rid of allocRes ADT. * They return a single value instead of the pair <Heap x Addr>. * This also removes some quantifiers related to the ADT in the generated * interpolants. alloc<heapSortName> : Heap x Obj --> Heap alloc<addressSortName> : Heap x Obj --> Address

* Below two functions are shorthand functions to get rid of batchAllocRes ADT. * They return a single value instead of the pair <Heap x AddressRange>. * This also removes some quantifiers related to the ADT in the generated * interpolants. batchAlloc<heapSortName> : Heap x Obj x Nat --> Heap batchAlloc<addressSortName>Range : Heap x Obj x Nat --> AddressRange * ***************************************************************************

19. #### final def asInstanceOf[T0]: T0

Definition Classes
Any
20. #### val axioms: Conjunction

Axioms defining the theory; such axioms are simply added as formulae to the problem to be proven, and thus handled using the standard reasoning techniques (including e-matching).

Axioms defining the theory; such axioms are simply added as formulae to the problem to be proven, and thus handled using the standard reasoning techniques (including e-matching).

Definition Classes
HeapTheory

29. #### def clone(): AnyRef

Attributes
protected[java.lang]
Definition Classes
AnyRef
Annotations
@throws( ... )
30. #### def containsADTSort(sort: Sort): Boolean

Returns whether (an ADT) sort is declared as part of this theory.

33. #### val dependencies: Iterable[Theory]

Optionally, other theories that this theory depends on.

Optionally, other theories that this theory depends on.

Definition Classes
HeapTheory

35. #### final def eq(arg0: AnyRef): Boolean

Definition Classes
AnyRef
36. #### def equals(arg0: Any): Boolean

Definition Classes
AnyRef → Any
37. #### def evalFun(f: IFunApp): Option[ITerm]

Optionally, a function evaluating theory functions applied to concrete arguments, represented as constructor terms.

Optionally, a function evaluating theory functions applied to concrete arguments, represented as constructor terms.

Definition Classes
Theory
38. #### def evalPred(p: IAtom): Option[Boolean]

Optionally, a function evaluating theory predicates applied to concrete arguments, represented as constructor terms.

Optionally, a function evaluating theory predicates applied to concrete arguments, represented as constructor terms.

Definition Classes
Theory
39. #### def extend(order: TermOrder): TermOrder

Add the symbols defined by this theory to the `order`

Add the symbols defined by this theory to the `order`

Definition Classes
Theory
40. #### def finalize(): Unit

Attributes
protected[java.lang]
Definition Classes
AnyRef
Annotations
@throws( classOf[java.lang.Throwable] )

42. #### val functionPredicateMapping: List[(MonoSortedIFunction, Predicate)]

Mapping of interpreted functions to interpreted predicates, used translating input ASTs to internal ASTs (the latter only containing predicates).

Mapping of interpreted functions to interpreted predicates, used translating input ASTs to internal ASTs (the latter only containing predicates).

Definition Classes
HeapTheory

44. #### val functionalPredicates: Set[Predicate]

Information which of the predicates satisfy the functionality axiom; at some internal points, such predicates can be handled more efficiently

Information which of the predicates satisfy the functionality axiom; at some internal points, such predicates can be handled more efficiently

Definition Classes
HeapTheory
45. #### val functions: List[MonoSortedIFunction]

Interpreted functions of the theory

Interpreted functions of the theory

Definition Classes
HeapTheory
46. #### def generateDecoderData(model: Conjunction): Option[TheoryDecoderData]

If this theory defines any `Theory.Decoder`, which can translate model data into some theory-specific representation, this function can be overridden to pre-compute required data from a model.

If this theory defines any `Theory.Decoder`, which can translate model data into some theory-specific representation, this function can be overridden to pre-compute required data from a model.

Definition Classes
Theory
47. #### final def getClass(): Class[_]

Definition Classes
AnyRef → Any
48. #### def hashCode(): Int

Definition Classes
AnyRef → Any

51. #### def iPostprocess(f: IFormula, signature: Signature): IFormula

Optionally, a post-processor that is applied to formulas output by the prover, for instance to interpolants or the result of quantifier elimination.

Optionally, a post-processor that is applied to formulas output by the prover, for instance to interpolants or the result of quantifier elimination. This method will be applied to the formula after calling `Internal2Inputabsy`.

Definition Classes
Theory
52. #### def iPreprocess(f: IFormula, signature: Signature): (IFormula, Signature)

Optionally, a pre-processor that is applied to formulas over this theory, prior to sending the formula to a prover.

Optionally, a pre-processor that is applied to formulas over this theory, prior to sending the formula to a prover. This method will be applied very early in the translation process.

Definition Classes
HeapTheory

55. #### final def isInstanceOf[T0]: Boolean

Definition Classes
Any
56. #### def isSoundForSat(theories: Seq[Theory], config: Theory.SatSoundnessConfig.Value): Boolean

Check whether we can tell that the given combination of theories is sound for checking satisfiability of a problem, i.e., if proof construction ends up in a dead end, can it be concluded that a problem is satisfiable.

Check whether we can tell that the given combination of theories is sound for checking satisfiability of a problem, i.e., if proof construction ends up in a dead end, can it be concluded that a problem is satisfiable.

Definition Classes
HeapTheory
57. #### val modelGenPredicates: Set[Predicate]

Optionally, a set of predicates used by the theory to tell the `PresburgerModelFinder` about terms that will be handled exclusively by this theory.

Optionally, a set of predicates used by the theory to tell the `PresburgerModelFinder` about terms that will be handled exclusively by this theory. If a proof goal in model generation mode contains an atom `p(x)`, for `p` in this set, then the `PresburgerModelFinder` will ignore `x` when assigning concrete values to symbols.

Definition Classes
Theory
58. #### final def ne(arg0: AnyRef): Boolean

Definition Classes
AnyRef

63. #### final def notify(): Unit

Definition Classes
AnyRef
64. #### final def notifyAll(): Unit

Definition Classes
AnyRef

69. #### def plugin: Option[Plugin]

Optionally, a plug-in implementing reasoning in this theory

Optionally, a plug-in implementing reasoning in this theory

Definition Classes
HeapTheory
70. #### val postSimplifiers: Seq[(IExpression) ⇒ IExpression]

Optionally, simplifiers that are applied to formulas output by the prover, for instance to interpolants or the result of quantifier.

Optionally, simplifiers that are applied to formulas output by the prover, for instance to interpolants or the result of quantifier. Such simplifiers are invoked by with `ap.parser.Simplifier`.

Definition Classes
HeapTheory
71. #### def postprocess(f: Conjunction, order: TermOrder): Conjunction

Optionally, a post-processor that is applied to formulas output by the prover, for instance to interpolants or the result of quantifier elimination.

Optionally, a post-processor that is applied to formulas output by the prover, for instance to interpolants or the result of quantifier elimination. This method will be applied to the raw formulas, before calling `Internal2Inputabsy`.

Definition Classes
Theory

73. #### val predicateMatchConfig: PredicateMatchConfig

Information how interpreted predicates should be handled for e-matching.

Information how interpreted predicates should be handled for e-matching.

Definition Classes
HeapTheory
74. #### val predicates: List[Predicate]

Interpreted predicates of the theory

Interpreted predicates of the theory

Definition Classes
HeapTheory
75. #### def preprocess(f: Conjunction, order: TermOrder): Conjunction

Optionally, a pre-processor that is applied to formulas over this theory, prior to sending the formula to a prover.

Optionally, a pre-processor that is applied to formulas over this theory, prior to sending the formula to a prover.

Definition Classes
Theory

77. #### val reducerPlugin: ReducerPluginFactory

Optionally, a plugin for the reducer applied to formulas both before and during proving.

Optionally, a plugin for the reducer applied to formulas both before and during proving.

Definition Classes
Theory

79. #### val singleInstantiationPredicates: Set[Predicate]

When instantiating existentially quantifier formulas, `EX phi`, at most one instantiation is necessary provided that all predicates in `phi` are contained in this set.

When instantiating existentially quantifier formulas, `EX phi`, at most one instantiation is necessary provided that all predicates in `phi` are contained in this set.

Definition Classes
Theory
80. #### final def synchronized[T0](arg0: ⇒ T0): T0

Definition Classes
AnyRef

82. #### def toString(): String

Definition Classes
Heap → AnyRef → Any
83. #### val totalityAxioms: Conjunction

Additional axioms that are included if the option `+genTotalityAxioms` is given to Princess.

Additional axioms that are included if the option `+genTotalityAxioms` is given to Princess.

Definition Classes
HeapTheory
84. #### val triggerRelevantFunctions: Set[IFunction]

A list of functions that should be considered in automatic trigger generation

A list of functions that should be considered in automatic trigger generation

Definition Classes
HeapTheory

89. #### final def wait(): Unit

Definition Classes
AnyRef
Annotations
@throws( ... )
90. #### final def wait(arg0: Long, arg1: Int): Unit

Definition Classes
AnyRef
Annotations
@throws( ... )
91. #### final def wait(arg0: Long): Unit

Definition Classes
AnyRef
Annotations
@throws( ... )

94. #### def writeADT(lhs: IFunApp, rhs: ITerm): ITerm

Helper function to write to ADT fields.

Helper function to write to ADT fields.

lhs

: the ADT field term to be written to. This should be an IFunApp, where the outermost function is a selector of the ADT, the innermost function is a heap read to the ADT on the heap, the innermost+1 function is the getter of the ADT, and any intermediate functions are other selectors e.g. x(getS(read(h, p))) or (in C: p->x) x(s(getS(read(h, p)))) (in C: p->s.x) note that this method works for writing to non-ADTs as well, if lhs is provided as a read Object (e.g. getInt(read(h,p))).

rhs

: the new value for the field, e.g. 42 this would return a new term, such as: S(42, y(s))

returns