Skip to content

Commit

Permalink
Merge pull request #95 from vorpal-research/release-preparation
Browse files Browse the repository at this point in the history
Release preparation
  • Loading branch information
AbdullinAM authored Nov 10, 2023
2 parents 0175ef9 + 99b7958 commit 07a9d88
Show file tree
Hide file tree
Showing 175 changed files with 65 additions and 32 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/jdk8-cd.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Java CD

on:
release:
types: [ published ]

jobs:
publish:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
- name: Set up JDK 1.8
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Build sources
id: build
run: |
mvn versions:set -DnewVersion=${{ github.event.release.tag_name }}
mvn package --file pom.xml -s .github/github-settings.xml
- name: Clean temporary files after the tests
run: rm -rf test-temp/

- name: Create zip archive with the release
run: zip release.zip ./* -r

- name: Attach zip archive to the release
id: upload-source-asset
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ github.token }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: release.zip
asset_name: ${{ github.event.repository.name }}-${{ github.event.release.tag_name }}.zip
asset_content_type: application/zip
2 changes: 1 addition & 1 deletion core/pom.xml → kex-core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>core</artifactId>
<artifactId>kex-core</artifactId>

<properties>
<ini4j.version>0.5.4</ini4j.version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import org.vorpal.research.kfg.ir.Class
import org.vorpal.research.kfg.ir.Method
import org.vorpal.research.kfg.visitor.MethodVisitor
import org.vorpal.research.kthelper.logging.log
import java.util.Locale
import java.util.*

data class CoverageInfo(
val bodyCovered: Int,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package org.vorpal.research.kex.config

import org.vorpal.research.kex.util.outputDirectory
import org.slf4j.MDC
import org.vorpal.research.kex.util.outputDirectory

val kexConfig: GlobalConfig by lazy { GlobalConfig() }

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ import org.vorpal.research.kfg.ir.value.instruction.BinaryOpcode
import org.vorpal.research.kfg.ir.value.instruction.UnaryOpcode
import ru.spbstu.Apply
import ru.spbstu.Symbolic
import ru.spbstu.div
import ru.spbstu.gcd
import ru.spbstu.plus
import ru.spbstu.minus
import ru.spbstu.times
import ru.spbstu.div
import ru.spbstu.plus
import ru.spbstu.shl
import ru.spbstu.shr
import ru.spbstu.times
import ru.spbstu.unaryMinus

fun BinaryOpcode.toFunc(): (Symbolic, Symbolic) -> Symbolic = when (this) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,7 @@ import org.vorpal.research.kex.config.kexConfig
import org.vorpal.research.kex.util.isAbstract
import org.vorpal.research.kthelper.assert.unreachable
import org.vorpal.research.kthelper.logging.log
import java.util.ArrayList
import java.util.ArrayDeque
import java.util.EnumSet
import java.util.EnumMap
import java.util.LinkedList
import java.util.Stack
import java.util.Queue
import java.util.PriorityQueue
import java.util.TreeSet
import java.util.TreeMap
import java.util.*
import java.util.concurrent.ConcurrentSkipListMap
import java.util.concurrent.ConcurrentSkipListSet

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ interface AbstractAsyncSMTSolver : Closeable {
suspend fun isViolatedAsync(state: PredicateState, query: PredicateState): Result
}

@Suppress("unused")
@AbstractIncrementalSolver
interface AbstractIncrementalSMTSolver : AbstractSMTSolver, Closeable {
fun isSatisfiable(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package org.vorpal.research.kex.state
import kotlinx.serialization.Serializable
import org.vorpal.research.kex.InheritorOf
import org.vorpal.research.kex.state.predicate.Predicate
import org.vorpal.research.kthelper.defaultHashCode

@InheritorOf("State")
@Serializable
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ class ArrayStorePredicate(
@Required @Contextual override val location: Location = Location()) : Predicate() {
override val operands by lazy { listOf(arrayRef, value) }

@Suppress("unused")
val componentType: KexType
get() = (arrayRef.type as? KexReference)?.reference ?: unreachable { log.error("Non-array type of array ref") }

Expand All @@ -34,4 +35,4 @@ class ArrayStorePredicate(
else -> predicate(type, location) { ref.store(store) }
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import kotlinx.serialization.Serializable
import org.vorpal.research.kex.InheritorOf
import org.vorpal.research.kex.ktype.KexType
import org.vorpal.research.kex.state.transformer.Transformer
import org.vorpal.research.kthelper.defaultHashCode

@InheritorOf("Term")
@Serializable
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ class ConstStringCollector : StringInfoContext(), Transformer<ConstStringCollect
&& predicate.length is ConstIntTerm
&& predicate.elements.all { it.isConst }
) {
valueArrays[predicate.lhv] = predicate.elements.mapTo(mutableListOf()) { it.numericValue.toChar() }
valueArrays[predicate.lhv] = predicate.elements.mapTo(mutableListOf()) { it.numericValue.toInt().toChar() }
}
return super.transformNewArrayInitializer(predicate)
}
Expand Down Expand Up @@ -84,7 +84,7 @@ class ConstStringCollector : StringInfoContext(), Transformer<ConstStringCollect
&& predicate.value.isConst
) {
valueArrays[arrayIndex.arrayRef]!![arrayIndex.index.numericValue.toInt()] =
predicate.value.numericValue.toChar()
predicate.value.numericValue.toInt().toChar()
}
return super.transformArrayStore(predicate)
}
Expand All @@ -96,7 +96,7 @@ class ConstStringCollector : StringInfoContext(), Transformer<ConstStringCollect
&& predicate.value.isConst
) {
valueArrays[arrayIndex.arrayRef]!![arrayIndex.index.numericValue.toInt()] =
predicate.value.numericValue.toChar()
predicate.value.numericValue.toInt().toChar()
}
return super.transformArrayInitializer(predicate)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ package org.vorpal.research.kex.state.transformer

import org.vorpal.research.kex.state.term.ArgumentTerm
import org.vorpal.research.kex.state.term.LambdaTerm
import org.vorpal.research.kex.state.term.ValueTerm
import org.vorpal.research.kex.state.term.ReturnValueTerm
import org.vorpal.research.kex.state.term.Term
import org.vorpal.research.kex.state.term.ValueTerm
import org.vorpal.research.kex.state.term.term
import org.vorpal.research.kex.trace.symbolic.PathClause
import org.vorpal.research.kex.trace.symbolic.PersistentSymbolicState
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@file:Suppress("unused")

package org.vorpal.research.kex.util

import org.vorpal.research.kex.config.Config
Expand All @@ -12,6 +14,7 @@ import kotlin.io.path.readLines

val Config.outputDirectory: Path get() = getPathValue("kex", "outputDir")!!.normalize()

@Deprecated("kex now does not write instrumented code into a directory")
val Config.instrumentedCodeDirectory: Path
get() {
val instrumentedDirName = getStringValue("output", "instrumentedDir", "instrumented")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import java.nio.file.Files
import java.nio.file.Path
import java.nio.file.SimpleFileVisitor
import java.nio.file.attribute.BasicFileAttributes
import java.util.Locale
import java.util.*
import kotlin.io.path.ExperimentalPathApi
import kotlin.io.path.deleteRecursively

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@file:Suppress("unused")

package org.vorpal.research.kex.util

import java.io.IOException
Expand Down
File renamed without changes.
3 changes: 1 addition & 2 deletions kex-executor/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@

<dependency>
<groupId>org.vorpal.research</groupId>
<artifactId>core</artifactId>
<artifactId>kex-core</artifactId>
<version>${project.version}</version>
</dependency>

Expand All @@ -56,7 +56,6 @@

<build>
<sourceDirectory>src/main/kotlin</sourceDirectory>
<testSourceDirectory>src/test/kotlin</testSourceDirectory>

<plugins>
<plugin>
Expand Down
4 changes: 2 additions & 2 deletions kex-ksmt/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,12 @@

<dependency>
<groupId>org.vorpal.research</groupId>
<artifactId>core</artifactId>
<artifactId>kex-core</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.vorpal.research</groupId>
<artifactId>core</artifactId>
<artifactId>kex-core</artifactId>
<version>${project.version}</version>
<classifier>tests</classifier>
<type>test-jar</type>
Expand Down
4 changes: 2 additions & 2 deletions kex-runner/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,12 @@

<dependency>
<groupId>org.vorpal.research</groupId>
<artifactId>core</artifactId>
<artifactId>kex-core</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.vorpal.research</groupId>
<artifactId>core</artifactId>
<artifactId>kex-core</artifactId>
<version>${project.version}</version>
<classifier>tests</classifier>
<type>test-jar</type>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ suspend fun Method.checkAsync(
.mapValues { it.value.rtMapped }
.toTypeMap()
val result = checker.prepareAndCheck(this, clauses + query, concreteTypeInfo, enableInlining)
// log.error("Checking clause type ${state.path.last().type}, acquired $result")
if (result !is Result.SatResult) {
return null
}
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<version>0.0.1</version>
<modules>
<module>kex-test</module>
<module>core</module>
<module>kex-core</module>
<module>kex-annotation-processor</module>
<module>kex-runner</module>
<module>kex-executor</module>
Expand Down

0 comments on commit 07a9d88

Please sign in to comment.