-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1caad27
commit 983a3ba
Showing
91 changed files
with
830 additions
and
831 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -64,30 +64,30 @@ DEMOS_TESTING_OUTPUT_DIR ::= .build/demos/output | |
DEMOS_TESTING_INPUTS ::= $(wildcard $(DEMOS_TESTING_INPUT_DIR)/*.run) | ||
DEMOS_TESTING_OUTPUTS ::= $(patsubst $(DEMOS_TESTING_INPUT_DIR)/%,$(DEMOS_TESTING_OUTPUT_DIR)/%.executed.kore,$(DEMOS_TESTING_INPUTS)) | ||
|
||
UKM_SEMANTICS_FILES ::= $(shell find ukm-semantics/ -type f -a '(' -name '*.md' -or -name '*.k' ')') | ||
ULM_SEMANTICS_FILES ::= $(shell find ulm-semantics/ -type f -a '(' -name '*.md' -or -name '*.k' ')') | ||
|
||
UKM_EXECUTION_KOMPILED ::= .build/ukm-execution-kompiled | ||
UKM_EXECUTION_TIMESTAMP ::= $(UKM_EXECUTION_KOMPILED)/timestamp | ||
ULM_EXECUTION_KOMPILED ::= .build/ulm-execution-kompiled | ||
ULM_EXECUTION_TIMESTAMP ::= $(ULM_EXECUTION_KOMPILED)/timestamp | ||
|
||
UKM_PREPROCESSING_KOMPILED ::= .build/ukm-preprocessing-kompiled | ||
UKM_PREPROCESSING_TIMESTAMP ::= $(UKM_PREPROCESSING_KOMPILED)/timestamp | ||
ULM_PREPROCESSING_KOMPILED ::= .build/ulm-preprocessing-kompiled | ||
ULM_PREPROCESSING_TIMESTAMP ::= $(ULM_PREPROCESSING_KOMPILED)/timestamp | ||
|
||
UKM_TESTING_KOMPILED ::= .build/ukm-testing-kompiled | ||
UKM_TESTING_TIMESTAMP ::= $(UKM_TESTING_KOMPILED)/timestamp | ||
ULM_TESTING_KOMPILED ::= .build/ulm-testing-kompiled | ||
ULM_TESTING_TIMESTAMP ::= $(ULM_TESTING_KOMPILED)/timestamp | ||
|
||
UKM_CONTRACTS_TESTING_INPUT_DIR ::= tests/ukm-contracts | ||
ULM_CONTRACTS_TESTING_INPUT_DIR ::= tests/ulm-contracts | ||
|
||
UKM_NO_CONTRACT_TESTING_INPUT_DIR ::= tests/ukm-no-contract | ||
UKM_NO_CONTRACT_TESTING_OUTPUT_DIR ::= .build/ukm-no-contract/output | ||
UKM_NO_CONTRACT_TESTING_INPUTS ::= $(wildcard $(UKM_NO_CONTRACT_TESTING_INPUT_DIR)/*.run) | ||
UKM_NO_CONTRACT_TESTING_OUTPUTS ::= $(patsubst $(UKM_NO_CONTRACT_TESTING_INPUT_DIR)/%,$(UKM_NO_CONTRACT_TESTING_OUTPUT_DIR)/%.executed.kore,$(UKM_NO_CONTRACT_TESTING_INPUTS)) | ||
ULM_NO_CONTRACT_TESTING_INPUT_DIR ::= tests/ulm-no-contract | ||
ULM_NO_CONTRACT_TESTING_OUTPUT_DIR ::= .build/ulm-no-contract/output | ||
ULM_NO_CONTRACT_TESTING_INPUTS ::= $(wildcard $(ULM_NO_CONTRACT_TESTING_INPUT_DIR)/*.run) | ||
ULM_NO_CONTRACT_TESTING_OUTPUTS ::= $(patsubst $(ULM_NO_CONTRACT_TESTING_INPUT_DIR)/%,$(ULM_NO_CONTRACT_TESTING_OUTPUT_DIR)/%.executed.kore,$(ULM_NO_CONTRACT_TESTING_INPUTS)) | ||
|
||
UKM_WITH_CONTRACT_TESTING_INPUT_DIR ::= tests/ukm-with-contract | ||
UKM_WITH_CONTRACT_TESTING_OUTPUT_DIR ::= .build/ukm-with-contract/output | ||
UKM_WITH_CONTRACT_TESTING_INPUTS ::= $(wildcard $(UKM_WITH_CONTRACT_TESTING_INPUT_DIR)/*.run) | ||
UKM_WITH_CONTRACT_TESTING_OUTPUTS ::= $(patsubst $(UKM_WITH_CONTRACT_TESTING_INPUT_DIR)/%,$(UKM_WITH_CONTRACT_TESTING_OUTPUT_DIR)/%.executed.kore,$(UKM_WITH_CONTRACT_TESTING_INPUTS)) | ||
ULM_WITH_CONTRACT_TESTING_INPUT_DIR ::= tests/ulm-with-contract | ||
ULM_WITH_CONTRACT_TESTING_OUTPUT_DIR ::= .build/ulm-with-contract/output | ||
ULM_WITH_CONTRACT_TESTING_INPUTS ::= $(wildcard $(ULM_WITH_CONTRACT_TESTING_INPUT_DIR)/*.run) | ||
ULM_WITH_CONTRACT_TESTING_OUTPUTS ::= $(patsubst $(ULM_WITH_CONTRACT_TESTING_INPUT_DIR)/%,$(ULM_WITH_CONTRACT_TESTING_OUTPUT_DIR)/%.executed.kore,$(ULM_WITH_CONTRACT_TESTING_INPUTS)) | ||
|
||
.PHONY: clean build build-legacy test test-legacy syntax-test preprocessing-test execution-test mx-test mx-rust-test mx-rust-contract-test mx-rust-two-contracts-test demos-test ukm-no-contracts-test | ||
.PHONY: clean build build-legacy test test-legacy syntax-test preprocessing-test execution-test mx-test mx-rust-test mx-rust-contract-test mx-rust-two-contracts-test demos-test ulm-no-contracts-test | ||
|
||
all: build test | ||
|
||
|
@@ -96,9 +96,9 @@ clean: | |
|
||
build: $(RUST_PREPROCESSING_TIMESTAMP) \ | ||
$(RUST_EXECUTION_TIMESTAMP) \ | ||
$(UKM_EXECUTION_TIMESTAMP) \ | ||
$(UKM_PREPROCESSING_TIMESTAMP) \ | ||
$(UKM_TESTING_TIMESTAMP) | ||
$(ULM_EXECUTION_TIMESTAMP) \ | ||
$(ULM_PREPROCESSING_TIMESTAMP) \ | ||
$(ULM_TESTING_TIMESTAMP) | ||
|
||
build-legacy: \ | ||
$(MX_TESTING_TIMESTAMP) \ | ||
|
@@ -108,7 +108,7 @@ build-legacy: \ | |
$(MX_RUST_TWO_CONTRACTS_TESTING_TIMESTAMP) | ||
|
||
|
||
test: build syntax-test preprocessing-test execution-test crates-test ukm-no-contracts-test ukm-with-contracts-test | ||
test: build syntax-test preprocessing-test execution-test crates-test ulm-no-contracts-test ulm-with-contracts-test | ||
|
||
test-legacy: mx-test mx-rust-test mx-rust-contract-test mx-rust-two-contracts-test demos-test | ||
|
||
|
@@ -130,9 +130,9 @@ mx-rust-two-contracts-test: $(MX_RUST_TWO_CONTRACTS_TESTING_OUTPUTS) | |
|
||
demos-test: $(DEMOS_TESTING_OUTPUTS) | ||
|
||
ukm-no-contracts-test: $(UKM_NO_CONTRACT_TESTING_OUTPUTS) | ||
ulm-no-contracts-test: $(ULM_NO_CONTRACT_TESTING_OUTPUTS) | ||
|
||
ukm-with-contracts-test: $(UKM_WITH_CONTRACT_TESTING_OUTPUTS) | ||
ulm-with-contracts-test: $(ULM_WITH_CONTRACT_TESTING_OUTPUTS) | ||
|
||
deps/blockchain-k-plugin/build/krypto/lib/krypto.a: | ||
make -C deps/blockchain-k-plugin build | ||
|
@@ -184,37 +184,37 @@ $(MX_RUST_TWO_CONTRACTS_TESTING_TIMESTAMP): $(MX_SEMANTICS_FILES) $(RUST_SEMANTI | |
-I . \ | ||
--debug | ||
|
||
$(UKM_EXECUTION_TIMESTAMP): $(UKM_SEMANTICS_FILES) $(RUST_SEMANTICS_FILES) deps/blockchain-k-plugin/build/krypto/lib/krypto.a | ||
$(ULM_EXECUTION_TIMESTAMP): $(ULM_SEMANTICS_FILES) $(RUST_SEMANTICS_FILES) deps/blockchain-k-plugin/build/krypto/lib/krypto.a | ||
# Workaround for https://github.com/runtimeverification/k/issues/4141 | ||
-rm -r $(UKM_EXECUTION_KOMPILED) | ||
$$(which kompile) ukm-semantics/targets/execution/ukm-target.md \ | ||
-rm -r $(ULM_EXECUTION_KOMPILED) | ||
$$(which kompile) ulm-semantics/targets/execution/ulm-target.md \ | ||
--hook-namespaces KRYPTO -ccopt -g -ccopt -std=c++17 -ccopt -lcrypto \ | ||
-ccopt -lsecp256k1 -ccopt -lssl -ccopt 'deps/blockchain-k-plugin/build/krypto/lib/krypto.a' \ | ||
--emit-json -o $(UKM_EXECUTION_KOMPILED) \ | ||
--emit-json -o $(ULM_EXECUTION_KOMPILED) \ | ||
-I kllvm \ | ||
-I deps/blockchain-k-plugin \ | ||
-I . \ | ||
--debug | ||
|
||
$(UKM_PREPROCESSING_TIMESTAMP): $(UKM_SEMANTICS_FILES) $(RUST_SEMANTICS_FILES) deps/blockchain-k-plugin/build/krypto/lib/krypto.a | ||
$(ULM_PREPROCESSING_TIMESTAMP): $(ULM_SEMANTICS_FILES) $(RUST_SEMANTICS_FILES) deps/blockchain-k-plugin/build/krypto/lib/krypto.a | ||
# Workaround for https://github.com/runtimeverification/k/issues/4141 | ||
-rm -r $(UKM_PREPROCESSING_KOMPILED) | ||
$$(which kompile) ukm-semantics/targets/preprocessing/ukm-target.md \ | ||
-rm -r $(ULM_PREPROCESSING_KOMPILED) | ||
$$(which kompile) ulm-semantics/targets/preprocessing/ulm-target.md \ | ||
--hook-namespaces KRYPTO -ccopt -g -ccopt -std=c++17 -ccopt -lcrypto \ | ||
-ccopt -lsecp256k1 -ccopt -lssl -ccopt 'deps/blockchain-k-plugin/build/krypto/lib/krypto.a' \ | ||
--emit-json -o $(UKM_PREPROCESSING_KOMPILED) \ | ||
--emit-json -o $(ULM_PREPROCESSING_KOMPILED) \ | ||
-I . \ | ||
-I deps/blockchain-k-plugin \ | ||
--debug | ||
|
||
$(UKM_TESTING_TIMESTAMP): $(UKM_SEMANTICS_FILES) $(RUST_SEMANTICS_FILES) deps/blockchain-k-plugin/build/krypto/lib/krypto.a | ||
$(ULM_TESTING_TIMESTAMP): $(ULM_SEMANTICS_FILES) $(RUST_SEMANTICS_FILES) deps/blockchain-k-plugin/build/krypto/lib/krypto.a | ||
# Workaround for https://github.com/runtimeverification/k/issues/4141 | ||
-rm -r $(UKM_TESTING_KOMPILED) | ||
$$(which kompile) ukm-semantics/targets/testing/ukm-target.md \ | ||
-rm -r $(ULM_TESTING_KOMPILED) | ||
$$(which kompile) ulm-semantics/targets/testing/ulm-target.md \ | ||
--hook-namespaces KRYPTO -ccopt -g -ccopt -std=c++17 -ccopt -lcrypto \ | ||
-ccopt -lsecp256k1 -ccopt -lssl -ccopt 'deps/blockchain-k-plugin/build/krypto/lib/krypto.a' \ | ||
${PLUGIN_FLAGS} \ | ||
--emit-json -o $(UKM_TESTING_KOMPILED) \ | ||
--emit-json -o $(ULM_TESTING_KOMPILED) \ | ||
-I . \ | ||
-I deps/blockchain-k-plugin \ | ||
-I kllvm \ | ||
|
@@ -408,26 +408,26 @@ $(CRATES_TESTING_OUTPUT_DIR)/%.run.executed.kore: \ | |
|
||
# TODO: Add $(shell echo "$<" | sed 's/\.[^.]*.run$$//').rs | ||
# as a dependency | ||
$(UKM_NO_CONTRACT_TESTING_OUTPUT_DIR)/%.run.executed.kore: \ | ||
$(UKM_NO_CONTRACT_TESTING_INPUT_DIR)/%.run \ | ||
$(UKM_CONTRACTS_TESTING_INPUT_DIR)/bytes_hooks.rs \ | ||
$(UKM_CONTRACTS_TESTING_INPUT_DIR)/ukm.rs \ | ||
$(UKM_TESTING_TIMESTAMP) \ | ||
$(ULM_NO_CONTRACT_TESTING_OUTPUT_DIR)/%.run.executed.kore: \ | ||
$(ULM_NO_CONTRACT_TESTING_INPUT_DIR)/%.run \ | ||
$(ULM_CONTRACTS_TESTING_INPUT_DIR)/bytes_hooks.rs \ | ||
$(ULM_CONTRACTS_TESTING_INPUT_DIR)/ulm.rs \ | ||
$(ULM_TESTING_TIMESTAMP) \ | ||
$(wildcard parsers/inc-*.sh) \ | ||
parsers/crates-ukm-testing-execution.sh \ | ||
parsers/test-ukm-testing-execution.sh | ||
mkdir -p $(UKM_NO_CONTRACT_TESTING_OUTPUT_DIR) | ||
parsers/crates-ulm-testing-execution.sh \ | ||
parsers/test-ulm-testing-execution.sh | ||
mkdir -p $(ULM_NO_CONTRACT_TESTING_OUTPUT_DIR) | ||
|
||
echo "<(<" > [email protected] | ||
echo "::bytes_hooks" >> [email protected] | ||
echo "<|>" >> [email protected] | ||
cat $(UKM_CONTRACTS_TESTING_INPUT_DIR)/bytes_hooks.rs >> [email protected] | ||
cat $(ULM_CONTRACTS_TESTING_INPUT_DIR)/bytes_hooks.rs >> [email protected] | ||
echo ">)>" >> [email protected] | ||
|
||
# echo "<(<" > [email protected] | ||
# echo "::ukm" >> [email protected] | ||
# echo "::ulm" >> [email protected] | ||
# echo "<|>" >> [email protected] | ||
# cat $(UKM_CONTRACTS_TESTING_INPUT_DIR)/ukm.rs >> [email protected] | ||
# cat $(ULM_CONTRACTS_TESTING_INPUT_DIR)/ulm.rs >> [email protected] | ||
# echo ">)>" >> [email protected] | ||
|
||
echo "<(<" >> [email protected] | ||
|
@@ -438,68 +438,68 @@ $(UKM_NO_CONTRACT_TESTING_OUTPUT_DIR)/%.run.executed.kore: \ | |
|
||
krun \ | ||
[email protected] \ | ||
--parser $(CURDIR)/parsers/crates-ukm-testing-execution.sh \ | ||
--definition $(UKM_TESTING_KOMPILED) \ | ||
--parser $(CURDIR)/parsers/crates-ulm-testing-execution.sh \ | ||
--definition $(ULM_TESTING_KOMPILED) \ | ||
--output kore \ | ||
--output-file [email protected] \ | ||
-cTEST='$(shell cat $<)' \ | ||
-pTEST=$(CURDIR)/parsers/test-ukm-testing-execution.sh | ||
-pTEST=$(CURDIR)/parsers/test-ulm-testing-execution.sh | ||
cat [email protected] | grep -q "Lbl'-LT-'k'-GT-'{}(dotk{}())" | ||
mv -f [email protected] $@ | ||
|
||
|
||
# TODO: Add $(shell echo "$<" | sed 's/\.[^.]*.run$$//').rs | ||
# as a dependency | ||
$(UKM_WITH_CONTRACT_TESTING_OUTPUT_DIR)/%.run.executed.kore: \ | ||
$(UKM_WITH_CONTRACT_TESTING_INPUT_DIR)/%.run \ | ||
$(UKM_CONTRACTS_TESTING_INPUT_DIR)/bytes_hooks.rs \ | ||
$(UKM_CONTRACTS_TESTING_INPUT_DIR)/ukm.rs \ | ||
$(UKM_TESTING_TIMESTAMP) \ | ||
$(ULM_WITH_CONTRACT_TESTING_OUTPUT_DIR)/%.run.executed.kore: \ | ||
$(ULM_WITH_CONTRACT_TESTING_INPUT_DIR)/%.run \ | ||
$(ULM_CONTRACTS_TESTING_INPUT_DIR)/bytes_hooks.rs \ | ||
$(ULM_CONTRACTS_TESTING_INPUT_DIR)/ulm.rs \ | ||
$(ULM_TESTING_TIMESTAMP) \ | ||
$(wildcard parsers/inc-*.sh) \ | ||
parsers/crates-ukm-testing-execution.sh \ | ||
parsers/test-ukm-testing-execution.sh | ||
mkdir -p $(UKM_WITH_CONTRACT_TESTING_OUTPUT_DIR) | ||
parsers/crates-ulm-testing-execution.sh \ | ||
parsers/test-ulm-testing-execution.sh | ||
mkdir -p $(ULM_WITH_CONTRACT_TESTING_OUTPUT_DIR) | ||
|
||
echo "<(<" > [email protected] | ||
echo "::address" >> [email protected] | ||
echo "<|>" >> [email protected] | ||
cat $(UKM_CONTRACTS_TESTING_INPUT_DIR)/address.rs >> [email protected] | ||
cat $(ULM_CONTRACTS_TESTING_INPUT_DIR)/address.rs >> [email protected] | ||
echo ">)>" >> [email protected] | ||
|
||
echo "<(<" >> [email protected] | ||
echo "::bytes_hooks" >> [email protected] | ||
echo "<|>" >> [email protected] | ||
cat $(UKM_CONTRACTS_TESTING_INPUT_DIR)/bytes_hooks.rs >> [email protected] | ||
cat $(ULM_CONTRACTS_TESTING_INPUT_DIR)/bytes_hooks.rs >> [email protected] | ||
echo ">)>" >> [email protected] | ||
|
||
echo "<(<" >> [email protected] | ||
echo "::test_helpers" >> [email protected] | ||
echo "<|>" >> [email protected] | ||
cat $(UKM_CONTRACTS_TESTING_INPUT_DIR)/test_helpers.rs >> [email protected] | ||
cat $(ULM_CONTRACTS_TESTING_INPUT_DIR)/test_helpers.rs >> [email protected] | ||
echo ">)>" >> [email protected] | ||
|
||
echo "<(<" >> [email protected] | ||
echo "::helpers" >> [email protected] | ||
echo "<|>" >> [email protected] | ||
cat $(UKM_CONTRACTS_TESTING_INPUT_DIR)/helpers.rs >> [email protected] | ||
cat $(ULM_CONTRACTS_TESTING_INPUT_DIR)/helpers.rs >> [email protected] | ||
echo ">)>" >> [email protected] | ||
|
||
echo "<(<" >> [email protected] | ||
echo "::state_hooks" >> [email protected] | ||
echo "<|>" >> [email protected] | ||
cat $(UKM_CONTRACTS_TESTING_INPUT_DIR)/state_hooks.rs >> [email protected] | ||
cat $(ULM_CONTRACTS_TESTING_INPUT_DIR)/state_hooks.rs >> [email protected] | ||
echo ">)>" >> [email protected] | ||
|
||
echo "<(<" >> [email protected] | ||
echo "::single_value_mapper" >> [email protected] | ||
echo "<|>" >> [email protected] | ||
cat $(UKM_CONTRACTS_TESTING_INPUT_DIR)/single_value_mapper.rs >> [email protected] | ||
cat $(ULM_CONTRACTS_TESTING_INPUT_DIR)/single_value_mapper.rs >> [email protected] | ||
echo ">)>" >> [email protected] | ||
|
||
echo "<(<" >> [email protected] | ||
echo "::ukm" >> [email protected] | ||
echo "::ulm" >> [email protected] | ||
echo "<|>" >> [email protected] | ||
cat $(UKM_CONTRACTS_TESTING_INPUT_DIR)/ukm.rs >> [email protected] | ||
cat $(ULM_CONTRACTS_TESTING_INPUT_DIR)/ulm.rs >> [email protected] | ||
echo ">)>" >> [email protected] | ||
|
||
echo "<(<" >> [email protected] | ||
|
@@ -510,11 +510,11 @@ $(UKM_WITH_CONTRACT_TESTING_OUTPUT_DIR)/%.run.executed.kore: \ | |
|
||
krun \ | ||
[email protected] \ | ||
--parser $(CURDIR)/parsers/crates-ukm-testing-execution.sh \ | ||
--definition $(UKM_TESTING_KOMPILED) \ | ||
--parser $(CURDIR)/parsers/crates-ulm-testing-execution.sh \ | ||
--definition $(ULM_TESTING_KOMPILED) \ | ||
--output kore \ | ||
--output-file [email protected] \ | ||
-cTEST='$(shell cat $<)' \ | ||
-pTEST=$(CURDIR)/parsers/test-ukm-testing-execution.sh | ||
-pTEST=$(CURDIR)/parsers/test-ulm-testing-execution.sh | ||
cat [email protected] | grep -q "Lbl'-LT-'k'-GT-'{}(dotk{}())" | ||
mv -f [email protected] $@ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule blockchain-k-plugin
deleted from
e6994c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#! /bin/bash | ||
|
||
kast \ | ||
--output kore \ | ||
--definition .build/ulm-testing-kompiled \ | ||
--module ULM-TARGET-SYNTAX \ | ||
--sort ExecutionTest \ | ||
$1 |
File renamed without changes.
File renamed without changes.
Oops, something went wrong.