From 0903efda0d16205d75941034f75233f155245952 Mon Sep 17 00:00:00 2001 From: Fayez Abu Alia Date: Thu, 19 Sep 2019 13:00:35 +0200 Subject: [PATCH 1/6] Fixed bug 115 --- src/main/java/de/dhbwstuttgart/bytecode/TPHExtractor.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/main/java/de/dhbwstuttgart/bytecode/TPHExtractor.java b/src/main/java/de/dhbwstuttgart/bytecode/TPHExtractor.java index aded8fd0..9e73fb03 100644 --- a/src/main/java/de/dhbwstuttgart/bytecode/TPHExtractor.java +++ b/src/main/java/de/dhbwstuttgart/bytecode/TPHExtractor.java @@ -192,7 +192,10 @@ public class TPHExtractor extends AbstractASTWalker { @Override public void visit(Constructor cons) { inMethod = false; - super.visit(cons); + //super.visit(cons); + cons.getParameterList().accept(this); + if(cons.block != null) + cons.block.accept(this); inMethod = true; } From 37f8f2e1e09736c9e018d062c8efaa09a1c69953 Mon Sep 17 00:00:00 2001 From: "pl@gohorb.ba-horb.de" Date: Thu, 19 Sep 2019 13:57:49 +0200 Subject: [PATCH 2/6] modified: ../../bytecode/javFiles/Y.jav Anwendung von Y eingefuegt. --- src/test/resources/bytecode/javFiles/Y.jav | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/test/resources/bytecode/javFiles/Y.jav b/src/test/resources/bytecode/javFiles/Y.jav index 3c3e204d..085bfd3c 100644 --- a/src/test/resources/bytecode/javFiles/Y.jav +++ b/src/test/resources/bytecode/javFiles/Y.jav @@ -8,8 +8,21 @@ class Y { y = f -> t -> f.apply(y.apply(f)).apply(t); //factorial = y.apply(f -> n -> { if (n == 0) return 1; else return n * f.apply(n - 1); }); } + + getY() { + return y; + } } +class fac1 { + factorial; + + fac1() { + var y; + y = new Y().getY(); + factorial = y.apply(f -> n -> { if (n == 0) return 1; else return n * f.apply(n - 1); }); + } +} /* ergibt Parse-Error class fac1 { From 8c195601d5acca35c536282134d8a5bd4119179e Mon Sep 17 00:00:00 2001 From: Fayez Abu Alia Date: Sat, 12 Oct 2019 11:32:56 +0200 Subject: [PATCH 3/6] Fixed signature problem for FunN --- .../java/de/dhbwstuttgart/bytecode/signature/Signature.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/main/java/de/dhbwstuttgart/bytecode/signature/Signature.java b/src/main/java/de/dhbwstuttgart/bytecode/signature/Signature.java index 90c4ed20..47254170 100644 --- a/src/main/java/de/dhbwstuttgart/bytecode/signature/Signature.java +++ b/src/main/java/de/dhbwstuttgart/bytecode/signature/Signature.java @@ -370,4 +370,10 @@ public class Signature { } } + @Override + public String toString() { + if(sw == null) + return super.toString(); + return sw.toString(); + } } From 6c783a18c73dfbf07a139f166ed670bf64276d33 Mon Sep 17 00:00:00 2001 From: "pl@gohorb.ba-horb.de" Date: Tue, 22 Oct 2019 16:44:38 +0200 Subject: [PATCH 4/6] new file: ../../../../../PlugInBau.txt modified: ../../bytecode/javFiles/Faculty.jav modified: ../../bytecode/javFiles/OL.jav modified: ../../bytecode/javFiles/Y.jav modified: ../../bytecode/javFiles/mathStruc.jav --- PlugInBau.txt | 22 +++++++++++++++++++ .../resources/bytecode/javFiles/Faculty.jav | 7 +++--- src/test/resources/bytecode/javFiles/OL.jav | 12 +++++----- src/test/resources/bytecode/javFiles/Y.jav | 7 +++--- .../resources/bytecode/javFiles/mathStruc.jav | 1 - 5 files changed, 36 insertions(+), 13 deletions(-) create mode 100644 PlugInBau.txt diff --git a/PlugInBau.txt b/PlugInBau.txt new file mode 100644 index 00000000..a76097ad --- /dev/null +++ b/PlugInBau.txt @@ -0,0 +1,22 @@ +Repositories: Branches: JavaCompilerCore: simplyRes + JavaCompilerPlugin: copy_libs +JavaCompilerCore > mvn install -Dskip.test=true + +[INFO] Installing /Users/pl/workspace_oxygen/JavaCompilerCore/target/JavaTXcompiler-0.2.jar to /Users/pl/.m2/repository/de/dhbwstuttgart/JavaTXcompiler/0.2/JavaTXcompiler-0.2.jar +[INFO] Installing /Users/pl/workspace_oxygen/JavaCompilerCore/pom.xml to /Users/pl/.m2/repository/de/dhbwstuttgart/JavaTXcompiler/0.2/JavaTXcompiler-0.2.pom +[INFO] Installing /Users/pl/workspace_oxygen/JavaCompilerCore/target/JavaTXcompiler-0.2-jar-with-dependencies.jar to /Users/pl/.m2/repository/de/dhbwstuttgart/JavaTXcompiler/0.2/JavaTXcompiler-0.2-jar-with-dependencies.jar +[INFO] ------------------------------------------------------------------------ +[INFO] BUILD SUCCESS +[INFO] ------------------------------------------------------------------------ +[INFO] Total time: 23.279 s +[INFO] Finished at: 2019-09-17T09:31:30+02:00 +[INFO] ------------------------------------- + +JavaCompilerCore > cd target + +JavaCompilerCore/target > cp JavaTXcompiler-0.2.jar ../../Plugin_JCC/JavaCompilerPlugin/bundles/JavaCompilerPlugin.Plugin/lib/JavaTXcompiler.jar + +Im Eclipse: Plugin_JCC/JavaCompilerPlugin> mvn install + +Plugin_JCC/JavaCompilerPlugin/releng/JavaCompilerPlugin.Update/target > cp JavaCompilerPlugin.Update-0.1.0-SNAPSHOT.zip ~/webdav/public_html/javatx/javatx_XXXXXX.zip + diff --git a/src/test/resources/bytecode/javFiles/Faculty.jav b/src/test/resources/bytecode/javFiles/Faculty.jav index 9d1e6124..14007ece 100644 --- a/src/test/resources/bytecode/javFiles/Faculty.jav +++ b/src/test/resources/bytecode/javFiles/Faculty.jav @@ -3,9 +3,9 @@ import java.lang.Integer; //import java.lang.Short; public class Faculty { - //public fact; - //Faculty() { - public fact = (x) -> { + public fact; + Faculty() { + fact = (x) -> { if (x == 1) { return 1; } @@ -13,6 +13,7 @@ public class Faculty { return x * (fact.apply(x-1)); } }; + } diff --git a/src/test/resources/bytecode/javFiles/OL.jav b/src/test/resources/bytecode/javFiles/OL.jav index ec5f9ab5..01a353fd 100644 --- a/src/test/resources/bytecode/javFiles/OL.jav +++ b/src/test/resources/bytecode/javFiles/OL.jav @@ -2,7 +2,7 @@ import java.lang.String; import java.lang.Integer; import java.lang.Double; import java.lang.Boolean; -import java.util.Vector; +//import java.util.Vector; public class OL { @@ -13,11 +13,11 @@ public class OL { // if the class contains just this method, then correct BC will be generated. // But if another methods are contained then the generated BC is not correct - m(x) { - //x.add(1); - x.addAll(x); - return x; - } +// m(x) { +// //x.add(1); +// x.addAll(x); +// return x; +// } } diff --git a/src/test/resources/bytecode/javFiles/Y.jav b/src/test/resources/bytecode/javFiles/Y.jav index 085bfd3c..a97360d4 100644 --- a/src/test/resources/bytecode/javFiles/Y.jav +++ b/src/test/resources/bytecode/javFiles/Y.jav @@ -8,12 +8,13 @@ class Y { y = f -> t -> f.apply(y.apply(f)).apply(t); //factorial = y.apply(f -> n -> { if (n == 0) return 1; else return n * f.apply(n - 1); }); } - + /* getY() { return y; } + */ } - +/* class fac1 { factorial; @@ -23,7 +24,7 @@ class fac1 { factorial = y.apply(f -> n -> { if (n == 0) return 1; else return n * f.apply(n - 1); }); } } -/* + ergibt Parse-Error class fac1 { factorial; diff --git a/src/test/resources/bytecode/javFiles/mathStruc.jav b/src/test/resources/bytecode/javFiles/mathStruc.jav index 5ee06793..37c5d08c 100644 --- a/src/test/resources/bytecode/javFiles/mathStruc.jav +++ b/src/test/resources/bytecode/javFiles/mathStruc.jav @@ -8,4 +8,3 @@ public class mathStruc { model =m; //innerOp = (o) -> (ms) -> new mathStruc<>(o.apply(this.model,ms.model)); } -} \ No newline at end of file From 00bbd5279fb75c2313c0717aa14491dd31c39d28 Mon Sep 17 00:00:00 2001 From: "pl@gohorb.ba-horb.de" Date: Thu, 24 Oct 2019 17:47:51 +0200 Subject: [PATCH 5/6] modified: src/main/java/de/dhbwstuttgart/core/JavaTXCompiler.java log-File-Ausgabe etwas ergaenzt modified: src/main/java/de/dhbwstuttgart/parser/SyntaxTreeGenerator/SyntaxTreeGenerator.java Fehler korrigiert, dass alle Fieldinitializer bei mehreren Klassen additiv hinzugefuegt werden modified: src/main/java/de/dhbwstuttgart/syntaxtree/statement/This.java toString veranedert modified: src/test/resources/bytecode/javFiles/mathStruc.jav leichte Korrektur new file: src/test/java/bytecode/mathStrucIntegerTest.java new file: src/test/resources/bytecode/javFiles/mathStrucInteger.jav mathStruc auf Integer angewandt new file: src/test/resources/bytecode/javFiles/mathStrucMatrixOP.jav mathStruc auf MatrixOP angewandt, laeuft noch nicht durch, des halb Test noch nicht eingecheckt --- .../de/dhbwstuttgart/core/JavaTXCompiler.java | 4 +- .../SyntaxTreeGenerator.java | 3 +- .../syntaxtree/statement/This.java | 4 + .../java/bytecode/mathStrucIntegerTest.java | 38 ++++++++ .../resources/bytecode/javFiles/mathStruc.jav | 5 + .../bytecode/javFiles/mathStrucInteger.jav | 23 +++++ .../bytecode/javFiles/mathStrucMatrixOP.jav | 91 +++++++++++++++++++ 7 files changed, 165 insertions(+), 3 deletions(-) create mode 100644 src/test/java/bytecode/mathStrucIntegerTest.java create mode 100644 src/test/resources/bytecode/javFiles/mathStrucInteger.jav create mode 100644 src/test/resources/bytecode/javFiles/mathStrucMatrixOP.jav diff --git a/src/main/java/de/dhbwstuttgart/core/JavaTXCompiler.java b/src/main/java/de/dhbwstuttgart/core/JavaTXCompiler.java index e3dce48a..d44ac77f 100644 --- a/src/main/java/de/dhbwstuttgart/core/JavaTXCompiler.java +++ b/src/main/java/de/dhbwstuttgart/core/JavaTXCompiler.java @@ -474,9 +474,9 @@ public class JavaTXCompiler { return x; }; - logFile.write(unifyCons.toString()); + logFile.write("Unify:" + unifyCons.toString()); unifyCons = unifyCons.map(distributeInnerVars); - logFile.write(unifyCons.toString()); + logFile.write("\nUnify_distributeInnerVars: " + unifyCons.toString()); TypeUnify unify = new TypeUnify(); // Set> results = new HashSet<>(); Nach vorne gezogen logFile.write("FC:\\" + finiteClosure.toString() + "\n"); diff --git a/src/main/java/de/dhbwstuttgart/parser/SyntaxTreeGenerator/SyntaxTreeGenerator.java b/src/main/java/de/dhbwstuttgart/parser/SyntaxTreeGenerator/SyntaxTreeGenerator.java index a945b02a..140b3432 100644 --- a/src/main/java/de/dhbwstuttgart/parser/SyntaxTreeGenerator/SyntaxTreeGenerator.java +++ b/src/main/java/de/dhbwstuttgart/parser/SyntaxTreeGenerator/SyntaxTreeGenerator.java @@ -35,7 +35,7 @@ public class SyntaxTreeGenerator{ Set imports = new HashSet(); private Map fields = new HashMap<>(); //PL 2018-11-01 fields eingefuegt, damit die fields immer die gleiche TPH bekommen - List fieldInitializations = new ArrayList<>(); + List fieldInitializations = new ArrayList<>(); //PL 2019-10-23: Muss für jede Klasse neu initilisiert werden public SyntaxTreeGenerator(JavaClassRegistry reg, GenericsRegistry globalGenerics){ //Die Generics müssen während des Bauens des AST erstellt werden, @@ -159,6 +159,7 @@ public class SyntaxTreeGenerator{ private ClassOrInterface convertClass(Java8Parser.ClassDeclarationContext ctx) { ClassOrInterface newClass; + fieldInitializations = new ArrayList<>(); //PL 2019-10-22: muss für jede Klasse neu initilisiert werden if(ctx.normalClassDeclaration() != null){ newClass = convertNormal(ctx.normalClassDeclaration()); } diff --git a/src/main/java/de/dhbwstuttgart/syntaxtree/statement/This.java b/src/main/java/de/dhbwstuttgart/syntaxtree/statement/This.java index d35e7797..cd7ef5ec 100644 --- a/src/main/java/de/dhbwstuttgart/syntaxtree/statement/This.java +++ b/src/main/java/de/dhbwstuttgart/syntaxtree/statement/This.java @@ -19,4 +19,8 @@ public class This extends Expression public void accept(StatementVisitor visitor) { visitor.visit(this); } + + public String toString() { + return "this: "+ this.getType(); + } } diff --git a/src/test/java/bytecode/mathStrucIntegerTest.java b/src/test/java/bytecode/mathStrucIntegerTest.java new file mode 100644 index 00000000..7100e4af --- /dev/null +++ b/src/test/java/bytecode/mathStrucIntegerTest.java @@ -0,0 +1,38 @@ +package bytecode; + +import static org.junit.Assert.*; + +import java.io.File; +import java.lang.reflect.Field; +import java.net.URL; +import java.net.URLClassLoader; + +import org.junit.BeforeClass; +import org.junit.Test; + +import de.dhbwstuttgart.core.JavaTXCompiler; + +public class mathStrucIntegerTest { + + private static String path; + private static File fileToTest; + private static JavaTXCompiler compiler; + private static ClassLoader loader; + private static Class classToTest; + private static String pathToClassFile; + private static Object instanceOfClass; + + + @Test + public void test() throws Exception { + path = System.getProperty("user.dir")+"/src/test/resources/bytecode/javFiles/mathStrucInteger.jav"; + fileToTest = new File(path); + compiler = new JavaTXCompiler(fileToTest); + compiler.generateBytecode(System.getProperty("user.dir")+"/src/test/resources/testBytecode/generatedBC/"); + pathToClassFile = System.getProperty("user.dir")+"/src/test/resources/testBytecode/generatedBC/"; + loader = new URLClassLoader(new URL[] {new URL("file://"+pathToClassFile)}); + classToTest = loader.loadClass("mathStrucInteger"); + //instanceOfClass = classToTest.getDeclaredConstructor(Integer.class).newInstance("A"); + } + +} diff --git a/src/test/resources/bytecode/javFiles/mathStruc.jav b/src/test/resources/bytecode/javFiles/mathStruc.jav index 37c5d08c..171881b1 100644 --- a/src/test/resources/bytecode/javFiles/mathStruc.jav +++ b/src/test/resources/bytecode/javFiles/mathStruc.jav @@ -1,3 +1,6 @@ +import java.util.Vector; +import java.lang.Integer; + public class mathStruc { model; @@ -8,3 +11,5 @@ public class mathStruc { model =m; //innerOp = (o) -> (ms) -> new mathStruc<>(o.apply(this.model,ms.model)); } +} + diff --git a/src/test/resources/bytecode/javFiles/mathStrucInteger.jav b/src/test/resources/bytecode/javFiles/mathStrucInteger.jav new file mode 100644 index 00000000..f1f67553 --- /dev/null +++ b/src/test/resources/bytecode/javFiles/mathStrucInteger.jav @@ -0,0 +1,23 @@ +import java.util.Vector; +import java.lang.Integer; + +public class mathStrucInteger { + model; + + innerOp = (o) -> (ms) -> new mathStrucInteger<>(o.apply(model,ms.model)); + + public mathStrucInteger(m) { + model =m; + } +} + +class mathStrucIntegerUse { + + main() { + var ms; + ms = new mathStrucInteger<>(2); + var ms2; + ms2 = ms.innerOp.apply((x,y) -> x+y).apply(ms); + return ms2; + } +} diff --git a/src/test/resources/bytecode/javFiles/mathStrucMatrixOP.jav b/src/test/resources/bytecode/javFiles/mathStrucMatrixOP.jav new file mode 100644 index 00000000..2b24f037 --- /dev/null +++ b/src/test/resources/bytecode/javFiles/mathStrucMatrixOP.jav @@ -0,0 +1,91 @@ +//PL 2019-10-24: laeuft nicht durch, zu gross +import java.util.Vector; +import java.lang.Integer; +import java.lang.Boolean; + +public class mathStrucMatrixOP { + model; + + innerOp = (o) -> (ms) -> new mathStrucMatrixOP<>(o.apply(model,ms.model)); + + public mathStrucMatrixOP(m) { + model =m; + } +} + +public class MatrixOP extends Vector> { + + MatrixOP () { + } + + MatrixOP(vv) { + Integer i; + i = 0; + while(i < vv.size()) { +// Boolean a = this.add(vv.elementAt(i)); + this.add(vv.elementAt(i)); + i=i+1; + } + } + + public mul = (m1, m2) -> { + var ret = new MatrixOP(); + var i = 0; + while(i < m1.size()) { + var v1 = m1.elementAt(i); + var v2 = new Vector(); + var j = 0; + while(j < v1.size()) { + var erg = 0; + var k = 0; + while(k < v1.size()) { + erg = erg + v1.elementAt(k) + * m2.elementAt(k).elementAt(j); + k++; } +// v2.addElement(new Integer(erg)); + v2.addElement(erg); + j++; } + ret.addElement(v2); + i++; + } + return ret; + }; +} + + +class mathStrucUseMatrixOP { + + main() { + Vector> vv = new Vector>(); + Vector v1 = new Vector(); + v1.addElement(2); + v1.addElement(2); + Vector v2 = new Vector(); + v2.addElement(3); + v2.addElement(3); + vv.addElement(v1); + vv.addElement(v2); + + MatrixOP m1 = new MatrixOP(vv); + + Vector> vv1 = new Vector>(); + Vector v3 = new Vector(); + v3.addElement(2); + v3.addElement(2); + Vector v4 = new Vector(); + v4.addElement(3); + v4.addElement(3); + vv1.addElement(v3); + vv1.addElement(v4); + + MatrixOP m2 = new MatrixOP(vv1); + + var mms; + mms = new mathStrucMatrixOP<>(m1); + var mms2; + mms2 = new mathStrucMatrixOP<>(m2); + var mms3; + mms3 = mms.innerOp.apply(m1.mul).apply(mms2); + return mms3; + } +} From c68d77348665b2244153099da5d49585fcbaec5e Mon Sep 17 00:00:00 2001 From: "pl@gohorb.ba-horb.de" Date: Mon, 18 Nov 2019 14:37:59 +0100 Subject: [PATCH 6/6] =?UTF-8?q?=09modified:=20=20=20../../../../main/java/?= =?UTF-8?q?de/dhbwstuttgart/typeinference/unify/TypeUnify2Task.java=20=09m?= =?UTF-8?q?odified:=20=20=20../../../../main/java/de/dhbwstuttgart/typeinf?= =?UTF-8?q?erence/unify/TypeUnifyTask.java=20Threadsteuerung=20veranendert?= =?UTF-8?q?,=20so=20dass=20m=C3=B6glichst=20veile=20Threads=20gleichzeitig?= =?UTF-8?q?=20laufen.=20M=C3=BCsste=20noch=20verbessert=20werden=20k=C3=B6?= =?UTF-8?q?nnen.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../typeinference/unify/TypeUnify2Task.java | 4 ++-- .../typeinference/unify/TypeUnifyTask.java | 21 +++++++++++++------ 2 files changed, 17 insertions(+), 8 deletions(-) diff --git a/src/main/java/de/dhbwstuttgart/typeinference/unify/TypeUnify2Task.java b/src/main/java/de/dhbwstuttgart/typeinference/unify/TypeUnify2Task.java index b3884e07..54c3fb99 100644 --- a/src/main/java/de/dhbwstuttgart/typeinference/unify/TypeUnify2Task.java +++ b/src/main/java/de/dhbwstuttgart/typeinference/unify/TypeUnify2Task.java @@ -39,8 +39,8 @@ public class TypeUnify2Task extends TypeUnifyTask { return new HashSet<>(); } else */ - - noOfThread--; + //writeLog("xxx"); + //noOfThread--; synchronized (usedTasks) { if (this.myIsCancelled()) { return new HashSet<>(); diff --git a/src/main/java/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java b/src/main/java/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java index 39f55184..8e940d70 100644 --- a/src/main/java/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java +++ b/src/main/java/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java @@ -904,9 +904,10 @@ public class TypeUnifyTask extends RecursiveTask>> { /* FORK ANFANG */ synchronized (this) { - noOfThread--; writeLog("wait "+ forkOrig.thNo); + noOfThread--; res = forkOrig.join(); + //noOfThread++; forkOrig.writeLog("final Orig 1"); forkOrig.closeLogFile(); //Set> fork_res = forkOrig.join(); @@ -919,7 +920,9 @@ public class TypeUnifyTask extends RecursiveTask>> { forks.forEach(x -> writeLog("wait: " + x.thNo)); for(TypeUnify2Task fork : forks) { synchronized (this) { + noOfThread--; Set> fork_res = fork.join(); + //noOfThread++; writeLog("Join " + new Integer(fork.thNo).toString()); //noOfThread--; an das Ende von compute verschoben writeLog("fork_res: " + fork_res.toString()); @@ -932,7 +935,7 @@ public class TypeUnifyTask extends RecursiveTask>> { fork.closeLogFile(); }; } - noOfThread++; + //noOfThread++; } else { if(parallel && (variance == -1) && noOfThread <= MaxNoOfThreads) { Set forks = new HashSet<>(); @@ -1007,9 +1010,10 @@ public class TypeUnifyTask extends RecursiveTask>> { /* FORK ANFANG */ synchronized (this) { - noOfThread--; writeLog("wait "+ forkOrig.thNo); + noOfThread--; res = forkOrig.join(); + //noOfThread++; forkOrig.writeLog("final Orig -1"); forkOrig.closeLogFile(); //Set> fork_res = forkOrig.join(); @@ -1022,7 +1026,9 @@ public class TypeUnifyTask extends RecursiveTask>> { forks.forEach(x -> writeLog("wait: " + x.thNo)); for(TypeUnify2Task fork : forks) { synchronized (this) { + noOfThread--; Set> fork_res = fork.join(); + //noOfThread++; writeLog("Join " + new Integer(fork.thNo).toString()); //noOfThread--; an das Ende von compute verschoben writeLog("fork_res: " + fork_res.toString()); @@ -1035,7 +1041,7 @@ public class TypeUnifyTask extends RecursiveTask>> { fork.closeLogFile(); }; } - noOfThread++; + //noOfThread++; } else { if(parallel && (variance == 2) && noOfThread <= MaxNoOfThreads) { writeLog("var2einstieg"); @@ -1080,9 +1086,10 @@ public class TypeUnifyTask extends RecursiveTask>> { /* FORK ANFANG */ synchronized (this) { - noOfThread--; writeLog("wait "+ forkOrig.thNo); + noOfThread--; res = forkOrig.join(); + //noOfThread++; forkOrig.writeLog("final Orig 2"); forkOrig.closeLogFile(); //Set> fork_res = forkOrig.join(); @@ -1094,7 +1101,9 @@ public class TypeUnifyTask extends RecursiveTask>> { forks.forEach(x -> writeLog("wait: " + x.thNo)); for(TypeUnify2Task fork : forks) { synchronized (this) { + noOfThread--; Set> fork_res = fork.join(); + //noOfThread++; writeLog("Join " + new Integer(fork.thNo).toString()); //noOfThread--; an das Ende von compute verschoben add_res.add(fork_res); @@ -1102,7 +1111,7 @@ public class TypeUnifyTask extends RecursiveTask>> { fork.closeLogFile(); }; } - noOfThread++; + //noOfThread++; } else { //parallel = false; //Wenn MaxNoOfThreads erreicht ist, sequentiell weiterarbeiten elems.add(a); //PL 2019-01-16 muss das wirklich hin steht schon in Zeile 859 ja braucht man siehe Zeile 859