summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathanael Sensfelder <SpamShield0@MultiAgentSystems.org>2017-08-30 13:57:53 +0200
committerNathanael Sensfelder <SpamShield0@MultiAgentSystems.org>2017-08-30 13:57:53 +0200
commitb715c825c0a36063e7b79248059263b438a0b5a6 (patch)
tree0ffdcb05d7b24d8928109b11d7e4743ef57e804d
parentaebd8f1bd52495b0a787e0cccfa4501141eace2b (diff)
Gets stuck due to scaling issues.
-rw-r--r--Makefile5
-rw-r--r--data/level/instances.lvl22
-rw-r--r--instance-calculator/Makefile18
-rw-r--r--instr-to-kodkod/Makefile4
4 files changed, 37 insertions, 12 deletions
diff --git a/Makefile b/Makefile
index ecaee82..4a18566 100644
--- a/Makefile
+++ b/Makefile
@@ -1,13 +1,14 @@
## Makefile Parameters #########################################################
LEVEL_FILES = $(wildcard ${CURDIR}/data/level/*.lvl)
PROPERTY_FILES = \
- $(wildcard ${CURDIR}/data/property/*.pro) \
- $(wildcard ${CURDIR}/data/property/cnes/*.pro)
+ $(wildcard ${CURDIR}/data/property/*.pro)
+# $(wildcard ${CURDIR}/data/property/cnes/*.pro)
AST_FILE = ${CURDIR}/data/ast/best_chronometer_ever.xml
#AST_FILE = ${CURDIR}/data/ast/pong.xml
TMP_DIR = /tmp/tabellion
MODEL_DIR = $(TMP_DIR)/mod
+MODEL_INSTANCES_DIR = $(TMP_DIR)/instance
SOL_DIR = $(TMP_DIR)/sol
## Sub-programs ################################################################
diff --git a/data/level/instances.lvl b/data/level/instances.lvl
new file mode 100644
index 0000000..5fdb42b
--- /dev/null
+++ b/data/level/instances.lvl
@@ -0,0 +1,22 @@
+;; Instances
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; TYPES DECLARATION ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+(add_type instance)
+
+;; Redundancies
+(add_type entity)
+(add_type process)
+(add_type waveform)
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; PREDICATES DECLARATION ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+(add_predicate is_waveform_instance instance waveform)
+(add_predicate is_visible_in instance waveform entity)
+
+(add_predicate is_process_instance instance process)
+(add_predicate is_visible_in instance process entity)
+
+(add_predicate process_instance_maps instance process instance waveform waveform)
diff --git a/instance-calculator/Makefile b/instance-calculator/Makefile
index 25d31cc..5f25d1a 100644
--- a/instance-calculator/Makefile
+++ b/instance-calculator/Makefile
@@ -5,8 +5,8 @@ MODEL_DIR =
endif
#### Where to store the Instance model
-ifndef INSTANCE_MODEL_DIR
-INSTANCE_MODEL_DIR = $(MODEL_DIR)/instance/
+ifndef MODEL_INSTANCES_DIR
+MODEL_INSTANCES_DIR =
endif
#### Binaries
@@ -25,8 +25,8 @@ ifeq ($(strip $(MODEL_DIR)),)
$(error No MODEL_DIR defined as parameter.)
endif
-ifeq ($(strip $(INSTANCE_MODEL_DIR)),)
-$(error No INSTANCE_MODEL_DIR defined as parameter.)
+ifeq ($(strip $(MODEL_INSTANCES_DIR)),)
+$(error No MODEL_INSTANCES_DIR defined as parameter.)
endif
ifeq ($(strip $(JAVA)),)
@@ -44,12 +44,12 @@ CLASSPATH = "./src/"
SOURCES = $(wildcard src/*.java)
CLASSES = $(SOURCES:.java=.class)
MODEL_FILE = $(MODEL_DIR)/structural.mod
-OUTPUT_FILE = $(INSTANCE_MODEL_DIR)/instances.mod
+OUTPUT_FILE = $(MODEL_INSTANCES_DIR)/instances.mod
## Makefile Rules ##############################################################
compile: $(CLASSES)
-model: $(CLASSES) $(INSTANCE_MODEL_DIR) $(OUTPUT_FILE)
+model: $(CLASSES) $(MODEL_INSTANCES_DIR) $(OUTPUT_FILE)
solutions:
@@ -67,8 +67,8 @@ clean_solutions:
$(JAVAC) -cp $(CLASSPATH) $<
$(OUTPUT_FILE): $(MODEL_FILE) $(CLASSES)
- $(JAVA) -cp $(CLASSPATH) Main $(MODEL_FILE) "inst_" $(INSTANCE_MODEL_DIR)
+ $(JAVA) -cp $(CLASSPATH) Main $(MODEL_FILE) "inst_" $(MODEL_INSTANCES_DIR)
-$(INSTANCE_MODEL_DIR):
- mkdir -p $(INSTANCE_MODEL_DIR)
+$(MODEL_INSTANCES_DIR):
+ mkdir -p $(MODEL_INSTANCES_DIR)
diff --git a/instr-to-kodkod/Makefile b/instr-to-kodkod/Makefile
index 03e451a..8543ee4 100644
--- a/instr-to-kodkod/Makefile
+++ b/instr-to-kodkod/Makefile
@@ -95,7 +95,9 @@ MODEL_FILES = \
$(MODEL_DIR)/structural.mod \
$(MODEL_DIR)/depths.mod \
$(MODEL_DIR)/string_to_instr.map \
- $(filter-out %structural.mod,$(wildcard $(MODEL_DIR)/cfg_*.mod))
+ $(wildcard $(MODEL_DIR)/cfg_*.mod) \
+ $(MODEL_INSTANCES_DIR)/instances.mod \
+ $(wildcard $(MODEL_INSTANCESDIR)/instances_in_*.mod)
PARSER_SOURCES = $(wildcard parser/*.g4)
PARSER_CLASSES = $(PARSER_SOURCES:.g4=.class)