Commit 233366cc authored by SPARSA ROYCHOWDHURY's avatar SPARSA ROYCHOWDHURY

6/11/2017:

1. restored the result 
2. testing the openmp


Sparsa Roychowdhury
parent 88b292a0
8 8 1 1 2
1
8
1 2 0 0 0
1 2
2 3 0 1 0
1 0 0 -1 1
1 1
3 4 0 0 1
1
2 1 1 0 2 0
4 5 0 0 0
1 1
5 6 0 1 0
1 1 0 1 0
2 1 0 0 -1 1
6 1 0 1 1
1 0 0 1 0
1
2 2 0 0 1 0
2 7 0 1 1
1 1 0 2 0
1
1 2
7 3 0 1 1
1 1 0 2 0
1
2 2 2 0 2 0
digraph finite_state_machine {
node [shape = point ]; qi0;
node [shape = doublecircle];8;
node [shape=circle];
qi0 -> 0;
0 -> 1 [ label = "{tn:0,x1:=0}" ];
1 -> 2 [ label = "{tn:1,ps_2}" ];
2 -> 3 [ label = "{tn:2,0<=x1<inf,ps_1}" ];
3 -> 4 [ label = "{tn:3,x1:=0,pp_1,1<=ag(1)<=2}" ];
4 -> 5 [ label = "{tn:4,ps_1}" ];
5 -> 6 [ label = "{tn:5,1<=x1<=1,pp_1,0<=ag(1)<inf}" ];
6 -> 1 [ label = "{tn:6,0<=x1<=1,x1:=0,pp_2,0<=ag(2)<=1}" ];
2 -> 7 [ label = "{tn:7,1<=x1<=2,x1:=0,ps_2}" ];
7 -> 3 [ label = "{tn:8,1<=x1<=2,x1:=0,pp_2,2<=ag(2)<=2}" ];
}
\ No newline at end of file
5 8 1 1 2
1
5
1 1 0 1 1
1 0 0 0 0
1
1 1
1 2 0 1 1
1 0 0 0 0
1
1 2
2 1 0 1 1
1 1 0 2 0
1
0
2 3 0 1 1
1 3 0 3 0
1
0
3 1 0 1 1
1 0 0 0 0
1
0
3 4 0 1 1
1 0 0 0 0
1
2 2 0 0 -1 1
4 3 0 1 1
1 1 0 1 0
1
0
1 5 0 1 1
1 0 0 0 0
1
2 1 6 0 6 0
digraph finite_state_machine {
node [shape = point ]; qi0;
node [shape = doublecircle];5;
node [shape=circle];
qi0 -> 0;
0 -> 1 [ label = "{tn:0,x1:=0}" ];
1 -> 1 [ label = "{tn:1,0<=x1<=0,x1:=0,ps_1}" ];
1 -> 2 [ label = "{tn:2,0<=x1<=0,x1:=0,ps_2}" ];
2 -> 1 [ label = "{tn:3,1<=x1<=2,x1:=0}" ];
2 -> 3 [ label = "{tn:4,3<=x1<=3,x1:=0}" ];
3 -> 1 [ label = "{tn:5,0<=x1<=0,x1:=0}" ];
3 -> 4 [ label = "{tn:6,0<=x1<=0,x1:=0,pp_2,0<=ag(2)<inf}" ];
4 -> 3 [ label = "{tn:7,1<=x1<=1,x1:=0}" ];
1 -> 5 [ label = "{tn:8,0<=x1<=0,x1:=0,pp_1,6<=ag(1)<=6}" ];
}
\ No newline at end of file
5 4 1 1 2
1
5
1 2 0 1 1
1 0 0 2 0
1
1 1
2 3 0 1 1
1 1 0 2 0
1
1 2
3 4 0 1 1
1 2 0 2 0
1
2 2 1 0 2 0
4 1 0 1 1
1 2 0 2 0
1
2 1 0 0 2 0
digraph finite_state_machine {
node [shape = point ]; qi0;
node [shape = doublecircle];5;
node [shape=circle];
qi0 -> 0;
0 -> 1 [ label = "{tn:0,x1:=0}" ];
1 -> 2 [ label = "{tn:1,0<=x1<=2,x1:=0,ps_1}" ];
2 -> 3 [ label = "{tn:2,1<=x1<=2,x1:=0,ps_2}" ];
3 -> 4 [ label = "{tn:3,2<=x1<=2,x1:=0,pp_2,1<=ag(2)<=2}" ];
4 -> 1 [ label = "{tn:4,2<=x1<=2,x1:=0,pp_1,0<=ag(1)<=2}" ];
}
\ No newline at end of file
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
#include"tpdaCGPP.h" #include"tpdaCGPP.h"
#include"timePushDown.h" #include"timePushDown.h"
#include"treeBitOperations.h" #include"treeBitOperations.h"
#include<omp.h>
#include<iostream> #include<iostream>
//relation comparison[4][4] = {{les,les,les,les},{les,leq,leq,leq},{les,leq,que,que},{les,leq,que,na}}; //relation comparison[4][4] = {{les,les,les,les},{les,leq,leq,leq},{les,leq,que,que},{les,leq,que,na}};
//relation addition[4][4] = {{z,les,leq,que},{les,les,les,que},{leq,les,leq,que},{que,que,que,que}};//,{inf,les,leq,que,inf}}; //relation addition[4][4] = {{z,les,leq,que},{les,les,les,que},{leq,les,leq,que},{que,que,que,que}};//,{inf,les,leq,que,inf}};
...@@ -837,7 +837,7 @@ vector<stateGCPP*> stateGCPP::addNextTPDA() { ...@@ -837,7 +837,7 @@ vector<stateGCPP*> stateGCPP::addNextTPDA() {
char q = transitions[ del[P-1] ].target; // target state of last transition char q = transitions[ del[P-1] ].target; // target state of last transition
// iterate through all the upcoming transitions // iterate through all the upcoming transitions
//#pragma openmp parallel for #pragma openmp parallel for
for(char i=0; i < nexttrans[q].size(); i++) { for(char i=0; i < nexttrans[q].size(); i++) {
dn = nexttrans[q][i]; // i-th upcoming transition dn = nexttrans[q][i]; // i-th upcoming transition
...@@ -882,7 +882,7 @@ vector<stateGCPP*> stateGCPP::addNextTPDA() { ...@@ -882,7 +882,7 @@ vector<stateGCPP*> stateGCPP::addNextTPDA() {
// iterate through all possible TSM value for tranistion 'dn' and check for constraints on clocks and stack // iterate through all possible TSM value for tranistion 'dn' and check for constraints on clocks and stack
//relation rel[2] = {leq,les}; //relation rel[2] = {leq,les};
//#pragma openmp parallel for #pragma openmp parallel for
for(char wn=0; wn < M; wn++) { for(char wn=0; wn < M; wn++) {
stateGCPP* vs = reduce2(dn,wn,clockDis,clockAcc,dlr,aclr); stateGCPP* vs = reduce2(dn,wn,clockDis,clockAcc,dlr,aclr);
...@@ -1923,7 +1923,7 @@ stateGCPP* stateGCPP::reduce2(char dn,char wn,short* clockDis,bool* clockAcc,sho ...@@ -1923,7 +1923,7 @@ stateGCPP* stateGCPP::reduce2(char dn,char wn,short* clockDis,bool* clockAcc,sho
//firstindex = i; //firstindex = i;
if( !big(i+1, P) ) if( !big(i+1, P) )
nf |= a32[j+1]; nf |= a32[j+1];
vs->w[count-1] = dist(i+1, P); vs->w[count-1] = dist(i+1, P); //?
} }
lastindex = i; // this is now the last index lastindex = i; // this is now the last index
...@@ -1955,7 +1955,7 @@ stateGCPP* stateGCPP::reduce2(char dn,char wn,short* clockDis,bool* clockAcc,sho ...@@ -1955,7 +1955,7 @@ stateGCPP* stateGCPP::reduce2(char dn,char wn,short* clockDis,bool* clockAcc,sho
else{ // if you have not choosed any point in the middle starting from point P** else{ // if you have not choosed any point in the middle starting from point P**
if( !big(L, P) ) if( !big(L, P) )
nf |= a32[L]; nf |= a32[L];
vs->w[count-1] = dist(L, P); vs->w[count-1] = dist(L, P); //?
} }
if(isPop(dn) ) // if dn has a pop, then push-pop has been added to L and R repectively if(isPop(dn) ) // if dn has a pop, then push-pop has been added to L and R repectively
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment