C++ pip persistence
|
Type
|
Level
|
MID
|
UID
|
REFS
|
Title
|
Statement
|
Rationale
|
Comment
|
BIBLIOGRAPHY
|
STATUS
|
COMPONENT
|
APPLICABILITY
|
VERIFICATION_METHODS
|
VERIFICATION_CRITERIA
|
SOURCE
|
LANGUAGE
|
VISIBILITY
|
INTERFACE
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
SW_SPEC
|
1 |
|
|
|
Human-readable problem output shall show constraints, parameters and big-parameter selection and return its stream. print_solution shall display the already computed tree or infeasibility with the requested nonnegative indentation. A pending unsolved problem shall raise std::logic_error rather than be silently solved by this display member. Human display shall be distinct from reloadable serialization. The initialization, arithmetic, ownership and exceptional-completion conditions in 🔗 1. Optimization and ranking valid use shall apply. |
Observation of an existing solution is distinct from requesting solver work and from serializing its representation. |
|
|
|
|
|
Check solved, infeasible and pending states, indentation, stream identity, labels and empty solution tuples. |
src/PIP_Problem.cc; src/PIP_Problem_defs.hh; src/PIP_Problem_inlines.hh; src/PIP_Problem_templates.hh; src/PIP_Problem_types.hh; tests/PIP_Problem/ascii_dump_load1.cc; tests/PIP_Problem/exceptions1.cc; tests/PIP_Problem/pipproblem1.cc. |
|
|
Public header: <ppl.hh>; namespace Parma_Polyhedra_Library. Members of PIP_Problem or the concrete type named below. void print_solution(std::ostream&, int indent=0) const; void print() const; std::ostream& IO_Operators::operator<<(std::ostream&, const PIP_Problem&); |
||
|
SW_SPEC
|
2 |
|
|
Parents:
|
|
Dumping shall write original problem data, parameter context, controls, big-parameter selection and incremental tree state. Loading a complete admitted representation produced by a matching configuration shall replace the destination and preserve subsequent context-relative solution meaning. Every loaded node shall belong to the destination, with valid parent links. A complete prefix may be followed by unrelated stream content. These records are trusted solver snapshots. Malformed tokens, extents, counts, parameter/control selections and status, tree or tableau structures inconsistent with the declared dimensions, parameters and status shall return false in both optimized and debugging builds. The loader shall validate leaf dimensions and parameter references against the processed model and the path's artificial parameter definitions. The loader reads the recorded tableaux. An altered record can pass those checks with tableaux that fail to represent its processed constraints. False shall not promise rollback or further queries. Surviving owned storage shall remain destructible. Stream and resource exceptions may propagate. Valid records can require substantial resources. The initialization, arithmetic, ownership and exceptional-completion conditions in 🔗 1. Optimization and ranking valid use shall apply. |
A valid tree depends on a compatible problem, context and owner; retaining old destination constraints changes its meaning. |
|
|
|
|
|
Round-trip every solver state and heuristic into fresh/populated destinations, then refine; check recursive false branches, owners, truncations, incompatible parameter dimensions, status/tree contradictions and malformed controls. Reject raw coordinate sets containing the largest dimension_type value, reserved indices and indices outside the ambient dimension before using a derived coordinate-set dimension. Exercise unsolved and solved records, zero ambient dimensions, empty/unsorted/duplicate valid sets, trailing input and complete valid replacement after false. |
src/PIP_Problem.cc; src/PIP_Problem_defs.hh; src/PIP_Problem_inlines.hh; src/PIP_Problem_templates.hh; src/PIP_Problem_types.hh; tests/PIP_Problem/ascii_dump_load1.cc; tests/PIP_Problem/contextrefinement1.cc; tests/PIP_Problem/persistenceadmission1.cc; tests/PIP_Problem/pipmalformedvalues1.cc. |
|
|
Public header: <ppl.hh>; namespace Parma_Polyhedra_Library. Members of PIP_Problem or the concrete type named below. void ascii_dump(std::ostream&) const; void ascii_dump() const; bool ascii_load(std::istream&); |
|
|
SW_SPEC
|
3 |
|
|
|
OK shall check the implemented problem, context, control and tree invariants, including that every owned tree node refers to this problem. It shall not establish a new mathematical solution. External memory shall estimate managed constraint, parameter, context and solution-tree storage; total memory shall add sizeof(*this). Destroying, clearing or replacing the problem shall release the storage it owns. The initialization, arithmetic, ownership and exceptional-completion conditions in 🔗 1. Optimization and ranking valid use shall apply. |
Ownership and structural checks support resource safety separately from the solver correctness argument. |
|
|
|
|
|
Check valid pending/solved/infeasible states, every transferred owner, byte relationships and cleanup after copies, resets and failed loads. |
src/PIP_Problem.cc; src/PIP_Problem_defs.hh; src/PIP_Problem_inlines.hh; src/PIP_Problem_templates.hh; src/PIP_Problem_types.hh; tests/PIP_Problem/ascii_dump_load1.cc; tests/PIP_Problem/contextrefinement1.cc; tests/PIP_Problem/persistenceadmission1.cc; tests/PIP_Problem/pipproblem1.cc. |
|
|
Public header: <ppl.hh>; namespace Parma_Polyhedra_Library. Members of PIP_Problem or the concrete type named below. bool OK() const; memory_size_type external_memory_in_bytes() const; memory_size_type total_memory_in_bytes() const; |