Skip to content

Commit d864866

Browse files
committed
update all test outputs
1 parent aef1b1c commit d864866

File tree

94 files changed

+14902
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

94 files changed

+14902
-0
lines changed

src/test/resources/correct_test_outputs/LRA_w_body.cpp

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,39 +57,48 @@ C[i][j] = 0.0;
5757

5858
long time_computation = 0, start_computation, end_computation;
5959
start_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
60+
{
6061
for (int i = 0; i < N; ++i) {
6162

6263
for (int j = max({i, 0}); j < N; ++j) {
6364

6465
A[i][j] += (f[i] * f[j]);
6566
}
6667
}
68+
}
69+
{
6770
for (int i = 0; i < N; ++i) {
6871

6972
for (int j = max({i, 0}); j < N; ++j) {
7073

7174
B[i][j] += (g[i] * g[j]);
7275
}
7376
}
77+
}
78+
{
7479
for (int i = 0; i < N; ++i) {
7580

7681
for (int j = max({i, 0}); j < N; ++j) {
7782

7883
C[i][j] += (f[i] * f[j]);
7984
}
8085
}
86+
}
87+
{
8188
for (int i = 0; i < N; ++i) {
8289

8390
for (int j = max({i, 0}); j < N; ++j) {
8491

8592
C[i][j] += (g[i] * g[j]);
8693
}
8794
}
95+
}
8896
end_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
8997
time_computation = end_computation - start_computation;
9098
cout << time_computation << endl;
9199
long time_reconstruction = 0, start_reconstruction, end_reconstruction;
92100
start_reconstruction = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
101+
{
93102
for (int i = 0; i < N; ++i) {
94103

95104
int jp = i;
@@ -99,6 +108,8 @@ int ip = j;
99108
A[i][j] = A[ip][jp];
100109
}
101110
}
111+
}
112+
{
102113
for (int i = 0; i < N; ++i) {
103114

104115
int jp = i;
@@ -108,6 +119,8 @@ int ip = j;
108119
B[i][j] = B[ip][jp];
109120
}
110121
}
122+
}
123+
{
111124
for (int i = 0; i < N; ++i) {
112125

113126
int jp = i;
@@ -117,6 +130,7 @@ int ip = j;
117130
C[i][j] = C[ip][jp];
118131
}
119132
}
133+
}
120134
end_reconstruction = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
121135
time_reconstruction = end_reconstruction - start_reconstruction;
122136
cout << time_reconstruction << endl;

src/test/resources/correct_test_outputs/LRA_wo_body.cpp

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,39 +13,48 @@ void fn(double ** A, double * f, double ** B, double * g, double ** C, int N) {
1313

1414
long time_computation = 0, start_computation, end_computation;
1515
start_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
16+
{
1617
for (int i = 0; i < N; ++i) {
1718

1819
for (int j = max({i, 0}); j < N; ++j) {
1920

2021
A[i][j] += (f[i] * f[j]);
2122
}
2223
}
24+
}
25+
{
2326
for (int i = 0; i < N; ++i) {
2427

2528
for (int j = max({i, 0}); j < N; ++j) {
2629

2730
B[i][j] += (g[i] * g[j]);
2831
}
2932
}
33+
}
34+
{
3035
for (int i = 0; i < N; ++i) {
3136

3237
for (int j = max({i, 0}); j < N; ++j) {
3338

3439
C[i][j] += (f[i] * f[j]);
3540
}
3641
}
42+
}
43+
{
3744
for (int i = 0; i < N; ++i) {
3845

3946
for (int j = max({i, 0}); j < N; ++j) {
4047

4148
C[i][j] += (g[i] * g[j]);
4249
}
4350
}
51+
}
4452
end_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
4553
time_computation = end_computation - start_computation;
4654
cout << time_computation << endl;
4755
long time_reconstruction = 0, start_reconstruction, end_reconstruction;
4856
start_reconstruction = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
57+
{
4958
for (int i = 0; i < N; ++i) {
5059

5160
int jp = i;
@@ -55,6 +64,8 @@ int ip = j;
5564
A[i][j] = A[ip][jp];
5665
}
5766
}
67+
}
68+
{
5869
for (int i = 0; i < N; ++i) {
5970

6071
int jp = i;
@@ -64,6 +75,8 @@ int ip = j;
6475
B[i][j] = B[ip][jp];
6576
}
6677
}
78+
}
79+
{
6780
for (int i = 0; i < N; ++i) {
6881

6982
int jp = i;
@@ -73,6 +86,7 @@ int ip = j;
7386
C[i][j] = C[ip][jp];
7487
}
7588
}
89+
}
7690
end_reconstruction = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
7791
time_reconstruction = end_reconstruction - start_reconstruction;
7892
cout << time_reconstruction << endl;

src/test/resources/correct_test_outputs/LRC_w_body.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,18 +32,21 @@ A[i][j] = 0.0;
3232

3333
long time_computation = 0, start_computation, end_computation;
3434
start_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
35+
{
3536
for (int i = 0; i < N; ++i) {
3637

3738
for (int j = max({i, 0}); j < N; ++j) {
3839

3940
A[i][j] += (f[i] * f[j]);
4041
}
4142
}
43+
}
4244
end_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
4345
time_computation = end_computation - start_computation;
4446
cout << time_computation << endl;
4547
long time_reconstruction = 0, start_reconstruction, end_reconstruction;
4648
start_reconstruction = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
49+
{
4750
for (int i = 0; i < N; ++i) {
4851

4952
int jp = i;
@@ -53,6 +56,7 @@ int ip = j;
5356
A[i][j] = A[ip][jp];
5457
}
5558
}
59+
}
5660
end_reconstruction = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
5761
time_reconstruction = end_reconstruction - start_reconstruction;
5862
cout << time_reconstruction << endl;

src/test/resources/correct_test_outputs/LRC_wo_body.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,18 +13,21 @@ void fn(double ** A, double * f, int N) {
1313

1414
long time_computation = 0, start_computation, end_computation;
1515
start_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
16+
{
1617
for (int i = 0; i < N; ++i) {
1718

1819
for (int j = max({i, 0}); j < N; ++j) {
1920

2021
A[i][j] += (f[i] * f[j]);
2122
}
2223
}
24+
}
2325
end_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
2426
time_computation = end_computation - start_computation;
2527
cout << time_computation << endl;
2628
long time_reconstruction = 0, start_reconstruction, end_reconstruction;
2729
start_reconstruction = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
30+
{
2831
for (int i = 0; i < N; ++i) {
2932

3033
int jp = i;
@@ -34,6 +37,7 @@ int ip = j;
3437
A[i][j] = A[ip][jp];
3538
}
3639
}
40+
}
3741
end_reconstruction = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
3842
time_reconstruction = end_reconstruction - start_reconstruction;
3943
cout << time_reconstruction << endl;

src/test/resources/correct_test_outputs/MTTKRP_IJ_w_body.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ A[i][j] = 0.0;
7171

7272
long time_computation = 0, start_computation, end_computation;
7373
start_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
74+
{
7475
int i = I;
7576
if (i >= 0 && i < M) {
7677
int j = J;
@@ -84,6 +85,7 @@ A[i][j] += (B[i][k][l] * C[k][j] * D[l][j]);
8485
}
8586
}
8687
}
88+
}
8789
end_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
8890
time_computation = end_computation - start_computation;
8991
cout << time_computation << endl;

src/test/resources/correct_test_outputs/MTTKRP_IJ_w_body_DataLayout.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,13 +80,16 @@ for (size_t j = 0; j < Q; ++j) {
8080
A[i][j] = 0.0;
8181
}
8282
}
83+
{
8384
for (int l = 0; l < P; ++l) {
8485

8586
int j = J;
8687
if (j >= 0 && j < Q) {
8788
D2[l] += D[l][j];
8889
}
8990
}
91+
}
92+
{
9093
for (int k = 0; k < N; ++k) {
9194

9295
for (int l = 0; l < P; ++l) {
@@ -97,8 +100,10 @@ B2[k][l] += B[i][k][l];
97100
}
98101
}
99102
}
103+
}
100104
long time_computation = 0, start_computation, end_computation;
101105
start_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
106+
{
102107
int i = I;
103108
int j = J;
104109
if (j >= 0 && j < Q) {
@@ -110,6 +115,7 @@ A[i][j] += (B2[k][l] * C[k][j] * D2[l]);
110115
}
111116
}
112117
}
118+
}
113119
end_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
114120
time_computation = end_computation - start_computation;
115121
cout << time_computation << endl;

src/test/resources/correct_test_outputs/MTTKRP_IJ_wo_body.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ void fn(double ** A, double *** B, double ** C, double ** D, int M, int N, int P
1313

1414
long time_computation = 0, start_computation, end_computation;
1515
start_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
16+
{
1617
int i = I;
1718
if (i >= 0 && i < M) {
1819
int j = J;
@@ -26,6 +27,7 @@ A[i][j] += (B[i][k][l] * C[k][j] * D[l][j]);
2627
}
2728
}
2829
}
30+
}
2931
end_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
3032
time_computation = end_computation - start_computation;
3133
cout << time_computation << endl;

src/test/resources/correct_test_outputs/MTTKRP_IJ_wo_body_DataLayout.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,16 @@ using namespace std::chrono;
1010
extern "C"
1111
void fn(double * D2, double ** D, double ** B2, double *** B, double ** A, double ** C, int M, int N, int P, int Q, int I, int J) {
1212

13+
{
1314
for (int l = 0; l < P; ++l) {
1415

1516
int j = J;
1617
if (j >= 0 && j < Q) {
1718
D2[l] += D[l][j];
1819
}
1920
}
21+
}
22+
{
2023
for (int k = 0; k < N; ++k) {
2124

2225
for (int l = 0; l < P; ++l) {
@@ -27,8 +30,10 @@ B2[k][l] += B[i][k][l];
2730
}
2831
}
2932
}
33+
}
3034
long time_computation = 0, start_computation, end_computation;
3135
start_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
36+
{
3237
int i = I;
3338
int j = J;
3439
if (j >= 0 && j < Q) {
@@ -40,6 +45,7 @@ A[i][j] += (B2[k][l] * C[k][j] * D2[l]);
4045
}
4146
}
4247
}
48+
}
4349
end_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
4450
time_computation = end_computation - start_computation;
4551
cout << time_computation << endl;

src/test/resources/correct_test_outputs/MTTKRP_I_w_body.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ A[i][j] = 0.0;
7070

7171
long time_computation = 0, start_computation, end_computation;
7272
start_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
73+
{
7374
int i = I;
7475
if (i >= 0 && i < M) {
7576
for (int j = 0; j < Q; ++j) {
@@ -83,6 +84,7 @@ A[i][j] += (B[i][k][l] * C[k][j] * D[l][j]);
8384
}
8485
}
8586
}
87+
}
8688
end_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
8789
time_computation = end_computation - start_computation;
8890
cout << time_computation << endl;

src/test/resources/correct_test_outputs/MTTKRP_I_w_body_DataLayout.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ for (size_t j = 0; j < Q; ++j) {
7575
A[i][j] = 0.0;
7676
}
7777
}
78+
{
7879
for (int k = 0; k < N; ++k) {
7980

8081
for (int l = 0; l < P; ++l) {
@@ -85,8 +86,10 @@ B2[k][l] += B[i][k][l];
8586
}
8687
}
8788
}
89+
}
8890
long time_computation = 0, start_computation, end_computation;
8991
start_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
92+
{
9093
int i = I;
9194
for (int j = 0; j < Q; ++j) {
9295

@@ -98,6 +101,7 @@ A[i][j] += (B2[k][l] * C[k][j] * D[l][j]);
98101
}
99102
}
100103
}
104+
}
101105
end_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
102106
time_computation = end_computation - start_computation;
103107
cout << time_computation << endl;

src/test/resources/correct_test_outputs/MTTKRP_I_wo_body.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ void fn(double ** A, double *** B, double ** C, double ** D, int M, int N, int P
1313

1414
long time_computation = 0, start_computation, end_computation;
1515
start_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
16+
{
1617
int i = I;
1718
if (i >= 0 && i < M) {
1819
for (int j = 0; j < Q; ++j) {
@@ -26,6 +27,7 @@ A[i][j] += (B[i][k][l] * C[k][j] * D[l][j]);
2627
}
2728
}
2829
}
30+
}
2931
end_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
3032
time_computation = end_computation - start_computation;
3133
cout << time_computation << endl;

src/test/resources/correct_test_outputs/MTTKRP_I_wo_body_DataLayout.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ using namespace std::chrono;
1010
extern "C"
1111
void fn(double ** B2, double *** B, double ** A, double ** C, double ** D, int M, int N, int P, int Q, int I) {
1212

13+
{
1314
for (int k = 0; k < N; ++k) {
1415

1516
for (int l = 0; l < P; ++l) {
@@ -20,8 +21,10 @@ B2[k][l] += B[i][k][l];
2021
}
2122
}
2223
}
24+
}
2325
long time_computation = 0, start_computation, end_computation;
2426
start_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
27+
{
2528
int i = I;
2629
for (int j = 0; j < Q; ++j) {
2730

@@ -33,6 +36,7 @@ A[i][j] += (B2[k][l] * C[k][j] * D[l][j]);
3336
}
3437
}
3538
}
39+
}
3640
end_computation = duration_cast<microseconds>(system_clock::now().time_since_epoch()).count();
3741
time_computation = end_computation - start_computation;
3842
cout << time_computation << endl;

0 commit comments

Comments
 (0)