Browse Source

more work: up

Former-commit-id: e7fa235111 [formerly 6323071a5b]
Former-commit-id: 72073e0de4
tempestpy_adaptions
dehnert 8 years ago
parent
commit
e8810a3be4
  1. 3
      src/builder/jit/ExplicitJitJaniModelBuilder.cpp
  2. 3
      src/builder/jit/ModelComponentsBuilder.cpp
  3. 2
      src/builder/jit/StateBehaviour.cpp
  4. 2
      src/builder/jit/StateBehaviour.h

3
src/builder/jit/ExplicitJitJaniModelBuilder.cpp

@ -189,9 +189,12 @@ namespace storm {
this->modelComponentsBuilder.registerLabel("init", stateIds.size()); this->modelComponentsBuilder.registerLabel("init", stateIds.size());
this->modelComponentsBuilder.registerLabel("deadlock", stateIds.size()); this->modelComponentsBuilder.registerLabel("deadlock", stateIds.size());
int stateCnt = 0;
for (auto const& stateEntry : stateIds) { for (auto const& stateEntry : stateIds) {
auto const& state = stateEntry.first; auto const& state = stateEntry.first;
{% for label in labels %}if ({$label.predicate}) { {% for label in labels %}if ({$label.predicate}) {
++stateCnt;
std::cout << "state " << state << " with index " << stateEntry.second << " has label {$label.name} (" << stateCnt << ") " << std::endl;
this->modelComponentsBuilder.addLabel(stateEntry.second, {$loop.index} - 1); this->modelComponentsBuilder.addLabel(stateEntry.second, {$loop.index} - 1);
} }
{% endfor %} {% endfor %}

3
src/builder/jit/ModelComponentsBuilder.cpp

@ -9,6 +9,7 @@
#include "src/exceptions/WrongFormatException.h" #include "src/exceptions/WrongFormatException.h"
#include "src/utility/macros.h" #include "src/utility/macros.h"
#include "src/utility/constants.h"
namespace storm { namespace storm {
namespace builder { namespace builder {
@ -49,7 +50,7 @@ namespace storm {
if (behaviour.isExpanded() && dontFixDeadlocks) { if (behaviour.isExpanded() && dontFixDeadlocks) {
STORM_LOG_THROW(false, storm::exceptions::WrongFormatException, "Error while creating sparse matrix from JANI model: found deadlock state and fixing deadlocks was explicitly disabled."); STORM_LOG_THROW(false, storm::exceptions::WrongFormatException, "Error while creating sparse matrix from JANI model: found deadlock state and fixing deadlocks was explicitly disabled.");
} else { } else {
// FIXME: fix deadlock
transitionMatrixBuilder->addNextValue(currentRow, currentRowGroup, storm::utility::one<ValueType>());
} }
} }
++currentRowGroup; ++currentRowGroup;

2
src/builder/jit/StateBehaviour.cpp

@ -62,7 +62,7 @@ namespace storm {
} }
template <typename IndexType, typename ValueType> template <typename IndexType, typename ValueType>
void StateBehaviour<IndexType, ValueType>::setExpaned() {
void StateBehaviour<IndexType, ValueType>::setExpanded() {
expanded = true; expanded = true;
} }

2
src/builder/jit/StateBehaviour.h

@ -23,7 +23,7 @@ namespace storm {
void compress(); void compress();
bool isExpanded() const; bool isExpanded() const;
void setExpaned();
void setExpanded();
bool empty() const; bool empty() const;
std::size_t size() const; std::size_t size() const;

Loading…
Cancel
Save