-
Notifications
You must be signed in to change notification settings - Fork 449
/
Copy pathParallelExecutorsTest.cpp
671 lines (604 loc) · 22 KB
/
ParallelExecutorsTest.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
/*
* Copyright 2022 HEAVY.AI, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include "DBHandlerTestHelpers.h"
#include "Logger/Logger.h"
#include "QueryEngine/Descriptors/RelAlgExecutionDescriptor.h"
#include "QueryEngine/Execute.h"
#include "QueryRunner/QueryRunner.h"
#include "TestHelpers.h"
#include "gen-cpp/heavy_types.h"
#include <array>
#include <future>
#include <sstream>
#include <vector>
#ifdef TBB_PREVIEW_WAITING_FOR_WORKERS
#include <tbb/global_control.h>
#endif
#ifndef BASE_PATH
#define BASE_PATH "./tmp"
#endif
using NumExecutors = int;
bool g_keep_data{false};
NumExecutors g_max_num_executors{4};
size_t g_num_tables{25};
extern bool g_is_test_env;
extern bool g_enable_executor_resource_mgr;
using namespace TestHelpers;
#define SKIP_NO_GPU() \
if (skipTests(dt)) { \
CHECK(dt == TExecuteMode::type::GPU); \
LOG(WARNING) << "GPU not available, skipping GPU tests"; \
return; \
}
namespace {
// Return vector of powers of 2 up to max_num_executors.
std::vector<NumExecutors> num_executors_vec(NumExecutors const max_num_executors) {
std::vector<NumExecutors> vec;
for (NumExecutors i = 1; i <= max_num_executors; i *= 2) {
vec.push_back(i);
}
return vec;
}
using Param = std::tuple<TExecuteMode::type, NumExecutors>;
enum ParamName { DT = 0, NUM_EXECUTORS };
// Return false on error
bool finalize_tbb_private_server_threads() {
#ifdef TBB_PREVIEW_WAITING_FOR_WORKERS // set when ENABLE_TSAN
#if 2021006 <= TBB_VERSION_MAJOR * 1000 + TBB_VERSION_MINOR
auto handle = oneapi::tbb::task_scheduler_handle{oneapi::tbb::attach{}};
#else
auto handle = tbb::task_scheduler_handle::get();
#endif
return tbb::finalize(handle, std::nothrow_t{});
#else
return true;
#endif
}
} // namespace
class BaseTestFixture : public DBHandlerTestFixture,
public ::testing::WithParamInterface<Param> {
protected:
Param param_;
void SetUp() override {
param_ = GetParam();
Executor::nukeCacheOfExecutors();
resizeDispatchQueue(std::get<NUM_EXECUTORS>(param_));
}
void TearDown() override { finalize_tbb_private_server_threads(); }
bool skipTests(const TExecuteMode::type device_type) {
#ifdef HAVE_CUDA
return device_type == TExecuteMode::type::GPU &&
!(getCatalog().getDataMgr().gpusPresent());
#else
return device_type == TExecuteMode::type::GPU;
#endif
}
const char* table_schema = R"(
(
i64 BIGINT,
i32 INT,
i16 SMALLINT,
i8 TINYINT,
d DOUBLE,
f FLOAT,
i1 BOOLEAN,
str TEXT ENCODING DICT(32),
arri64 BIGINT[]
) WITH (FRAGMENT_SIZE=2);
)";
void runSqlExecuteTest(const std::string& table_name, const TExecuteMode::type dt) {
auto check_returned_rows = [this](const std::string& query, const size_t num_rows) {
TQueryResult result_set;
sql(result_set, query);
EXPECT_EQ(getRowCount(result_set), num_rows);
};
setExecuteMode(dt);
// basic queries
sqlAndCompareResult("SELECT COUNT(*) FROM " + table_name + " WHERE i32 < 50;",
{{i(15)}});
sqlAndCompareResult("SELECT MIN(d) FROM " + table_name + " WHERE i1 IS NOT NULL;",
{{1.0001}});
// Simple query with a sort
sqlAndCompareResult("SELECT i64 FROM " + table_name + " ORDER BY i64 LIMIT 1;",
{{i(0)}});
// complex queries
check_returned_rows("SELECT d, f, COUNT(*) FROM " + table_name + " GROUP BY d, f;",
6);
check_returned_rows("SELECT d, f, COUNT(*) FROM " + table_name +
" GROUP BY d, f ORDER BY f DESC NULLS LAST LIMIT 5;",
5);
sqlAndCompareResult("SELECT COUNT(*) FROM " + table_name + " WHERE str like 'hello';",
{{i(10)}});
sqlAndCompareResult(
"SELECT COUNT(*) FROM " + table_name + " WHERE str ilike 'hello';", {{i(10)}});
sqlAndCompareResult(
"SELECT COUNT(*) FROM " + table_name + " WHERE str REGEXP '^[a-z]+r$';",
{{i(0)}});
check_returned_rows(
"SELECT approx_count_distinct(d), approx_count_distinct(str), i64, i32, "
"i16 FROM " +
table_name + " WHERE i32 < 50 GROUP BY i64, i32, i16 ORDER BY i64, i32, i16;",
5);
// multi-step
check_returned_rows(
"SELECT d, f, COUNT(*) FROM " + table_name + " GROUP BY d, f HAVING d < f;", 5);
// joins
sqlAndCompareResult("SELECT COUNT(*) FROM " + table_name +
" a INNER JOIN (SELECT i32 FROM " + table_name +
" GROUP BY i32) b on a.i64 = b.i32;",
{{i(1)}});
}
void buildTable(const std::string& table_name) {
sql("DROP TABLE IF EXISTS " + table_name + ";");
sql("CREATE TABLE " + table_name + " " + table_schema);
ValuesGenerator gen(table_name);
for (size_t i = 0; i < 10; i++) {
sql(gen(100, 10, 2, 1, 1.0001, 1.1, "'true'", "'hello'", "{100, 200}"));
}
for (size_t i = 0; i < 5; i++) {
// Note - Windows template processing can't proccess an embedded
// ternary operator.
std::string row_alternate = (i % 2 == 0) ? "{NULL, 200}" : "{100, NULL}";
sql(gen(500, 50, "NULL", 5, 5.0001, 5.1, "'false'", "'world'", row_alternate));
}
for (size_t i = 0; i < 5; i++) {
sql(gen(100 * i,
10 * i,
2 * i,
1 * i,
1.0001 * static_cast<float>(i),
1.1 * static_cast<float>(i),
"NULL",
"NULL",
"{" + std::to_string(100 * i) + "," + std::to_string(200 * i) + "}"));
}
}
};
struct TestNameSuffix {
// NOTE: test names must be non-empty, unique, and may only contain ASCII alphanumeric
// characters. [Use of underscore must follow specific restrictions. See url for info.]
// https://google.github.io/googletest/advanced.html#specifying-names-for-value-parameterized-test-parameters
std::string operator()(
::testing::TestParamInfo<BaseTestFixture::ParamType> const& info) const {
std::ostringstream oss;
oss << std::get<DT>(info.param) << "_executors_"
<< std::get<NUM_EXECUTORS>(info.param);
return oss.str();
}
};
class SingleTableTestEnv : public BaseTestFixture {
protected:
void SetUp() override {
BaseTestFixture::SetUp();
buildTable("test_parallel");
if (!skipTests(TExecuteMode::type::GPU)) {
// warm up the PTX JIT
setExecuteMode(TExecuteMode::type::GPU);
sql("SELECT COUNT(*) FROM test_parallel;");
}
}
void TearDown() override {
if (!g_keep_data) {
sql("DROP TABLE IF EXISTS test_parallel;");
}
BaseTestFixture::TearDown();
}
};
TEST_P(SingleTableTestEnv, SingleTableTest) {
auto const num_executors = std::get<NUM_EXECUTORS>(param_);
TExecuteMode::type const dt = std::get<DT>(param_);
{
SKIP_NO_GPU();
setExecuteMode(dt);
std::vector<std::future<void>> worker_threads;
auto execution_time = measure<>::execution([&]() {
for (NumExecutors w = 0; w < num_executors; w++) {
worker_threads.push_back(std::async(
std::launch::async,
[this](const std::string& table_name, const TExecuteMode::type dt) {
runSqlExecuteTest(table_name, dt);
},
"test_parallel",
dt));
}
for (auto& t : worker_threads) {
t.get();
}
});
LOG(ERROR) << "Finished execution with " << num_executors << " executors, "
<< execution_time << " ms.";
}
}
class MultiTableTestEnv : public BaseTestFixture {
protected:
void SetUp() override {
BaseTestFixture::SetUp();
for (size_t i = 0; i < g_num_tables; i++) {
buildTable("test_parallel_" + std::to_string(i));
}
if (!skipTests(TExecuteMode::type::GPU)) {
// warm up the PTX JIT
setExecuteMode(TExecuteMode::type::GPU);
sql("SELECT COUNT(*) FROM test_parallel_0;");
}
}
void TearDown() override {
if (!g_keep_data) {
for (size_t i = 0; i < g_num_tables; i++) {
sql("DROP TABLE IF EXISTS test_parallel_" + std::to_string(i) + ";");
}
}
BaseTestFixture::TearDown();
}
};
TEST_P(MultiTableTestEnv, MultiTableTest) {
auto const num_executors = std::get<NUM_EXECUTORS>(param_);
TExecuteMode::type const dt = std::get<DT>(param_);
{
SKIP_NO_GPU();
setExecuteMode(dt);
std::vector<std::future<void>> worker_threads;
// use fewer tables on CPU, as speedup isn't as large
auto num_tables = dt == TExecuteMode::type::CPU ? 2 : g_num_tables;
auto execution_time = measure<>::execution([&]() {
for (size_t w = 0; w < num_tables; w++) {
worker_threads.push_back(std::async(
std::launch::async,
[this](const std::string& table_name, const TExecuteMode::type dt) {
runSqlExecuteTest(table_name, dt);
},
"test_parallel_" + std::to_string(w),
dt));
}
for (auto& t : worker_threads) {
t.get();
}
});
LOG(ERROR) << "Finished execution with " << g_num_tables << " tables, "
<< num_executors << " executors, " << execution_time << " ms.";
}
}
class UpdateDeleteTestEnv : public BaseTestFixture {
protected:
void SetUp() override {
BaseTestFixture::SetUp();
for (int i = 0; i < num_tables; i++) {
buildTable("test_parallel_" + std::to_string(i));
}
if (!skipTests(TExecuteMode::type::GPU)) {
setExecuteMode(TExecuteMode::type::GPU);
// warm up the PTX JIT
sql("SELECT COUNT(*) FROM test_parallel_0;");
}
}
void TearDown() override {
if (!g_keep_data) {
for (int i = 0; i < num_tables; i++) {
sql("DROP TABLE IF EXISTS test_parallel_" + std::to_string(i) + ";");
}
}
BaseTestFixture::TearDown();
}
public:
int num_tables{g_max_num_executors * 2};
};
TEST_P(UpdateDeleteTestEnv, Delete_OneTable) {
const size_t iterations = 5;
TExecuteMode::type const dt = std::get<DT>(param_);
{
SKIP_NO_GPU();
setExecuteMode(dt);
for (size_t i = 0; i < iterations; i++) {
std::vector<std::future<void>> worker_threads;
auto execution_time = measure<>::execution([&]() {
// three readers, one writer
for (size_t j = 0; j < 4; j++) {
worker_threads.push_back(std::async(
std::launch::async,
[this, j](const std::string& table_name, const TExecuteMode::type dt) {
if (j == 0) {
// run insert, then delete
sql("INSERT INTO " + table_name +
" VALUES(1, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);");
sql("DELETE FROM " + table_name + " WHERE i64 = 1;");
sqlAndCompareResult(
"SELECT COUNT(*) FROM " + table_name + " WHERE i64 = 1;",
{{int64_t(0)}});
} else {
// run select
sqlAndCompareResult(
"SELECT MIN(d) FROM " + table_name + " WHERE i1 IS NOT NULL;",
{{1.0001}});
}
},
"test_parallel_0",
dt));
}
for (auto& t : worker_threads) {
t.get();
}
});
LOG(ERROR) << "Finished execution of iteration " << i << " , " << execution_time
<< " ms.";
}
}
}
TEST_P(UpdateDeleteTestEnv, Delete_TwoTables) {
TExecuteMode::type const dt = std::get<DT>(param_);
{
SKIP_NO_GPU();
setExecuteMode(dt);
std::vector<std::future<void>> worker_threads;
// three readers, one writer
for (size_t j = 0; j < 4; j++) {
worker_threads.push_back(std::async(
std::launch::async,
[this, j](const std::string& select_table_name,
const std::string& delete_table_name,
const TExecuteMode::type dt) {
if (j == 0) {
// run insert, then delete
sql("INSERT INTO " + delete_table_name +
" VALUES(1, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);");
sql("DELETE FROM " + delete_table_name + " WHERE i64 = 1;");
sqlAndCompareResult(
"SELECT COUNT(*) FROM " + delete_table_name + " WHERE i64 = 1;",
{{i(0)}});
} else {
// run select
runSqlExecuteTest(select_table_name, dt);
}
},
"test_parallel_0",
"test_parallel_1",
dt));
}
for (auto& t : worker_threads) {
t.get();
}
}
}
TEST_P(UpdateDeleteTestEnv, Update_OneTable) {
const size_t iterations = 5;
TExecuteMode::type const dt = std::get<DT>(param_);
{
SKIP_NO_GPU();
setExecuteMode(dt);
for (size_t i = 0; i < iterations; i++) {
std::vector<std::future<void>> worker_threads;
auto execution_time = measure<>::execution([&]() {
// three readers, one writer
for (size_t j = 0; j < 4; j++) {
worker_threads.push_back(std::async(
std::launch::async,
[this, j](const std::string& table_name, const TExecuteMode::type dt) {
if (j == 0) {
// run insert, then delete
sql("INSERT INTO " + table_name +
" VALUES(1, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);");
sql("UPDATE " + table_name + " SET i64 = -1 WHERE i64 = 1;");
sqlAndCompareResult(
"SELECT COUNT(*) FROM " + table_name + " WHERE i64 = 1;",
{{int64_t(0)}});
} else {
// run select
sqlAndCompareResult(
"SELECT MIN(d) FROM " + table_name + " WHERE i1 IS NOT NULL;",
{{1.0001}});
}
},
"test_parallel_0",
dt));
}
for (auto& t : worker_threads) {
t.get();
}
});
LOG(ERROR) << "Finished execution of iteration " << i << " , " << execution_time
<< " ms.";
}
}
}
TEST_P(UpdateDeleteTestEnv, Update_OneTableVarlen) {
const size_t iterations = 5;
TExecuteMode::type const dt = std::get<DT>(param_);
{
SKIP_NO_GPU();
setExecuteMode(dt);
for (size_t i = 0; i < iterations; i++) {
std::vector<std::future<void>> worker_threads;
auto execution_time = measure<>::execution([&]() {
// three readers, one writer
for (size_t j = 0; j < 4; j++) {
worker_threads.push_back(std::async(
std::launch::async,
[this, j](const std::string& table_name, const TExecuteMode::type dt) {
if (j == 0) {
// run insert, then delete
sql("INSERT INTO " + table_name +
" VALUES(1, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);");
sql("UPDATE " + table_name +
" SET arri64 = ARRAY[1,2,3] WHERE i64 = 1;");
sqlAndCompareResult(
"SELECT COUNT(*) FROM " + table_name + " WHERE i64 = 1;",
{{int64_t(1)}});
sql("UPDATE " + table_name +
" SET arri64 = ARRAY[1,2,3] WHERE i64 = 1;");
sql("DELETE FROM " + table_name + " WHERE i64 = 1;");
} else {
// run select
sqlAndCompareResult(
"SELECT MIN(d) FROM " + table_name + " WHERE i1 IS NOT NULL;",
{{1.0001}});
}
},
"test_parallel_0",
dt));
}
for (auto& t : worker_threads) {
t.get();
}
});
LOG(ERROR) << "Finished execution of iteration " << i << " , " << execution_time
<< " ms.";
}
}
}
TEST_P(UpdateDeleteTestEnv, Update_TwoTables) {
TExecuteMode::type const dt = std::get<DT>(param_);
{
SKIP_NO_GPU();
setExecuteMode(dt);
std::vector<std::future<void>> worker_threads;
// three readers, one writer
for (size_t j = 0; j < 4; j++) {
worker_threads.push_back(std::async(
std::launch::async,
[this, j](const std::string& select_table_name,
const std::string& delete_table_name,
const TExecuteMode::type dt) {
if (j == 0) {
// run insert, then delete
sql("INSERT INTO " + delete_table_name +
" VALUES(1, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);");
sql("UPDATE " + delete_table_name + " SET i64 = -1 WHERE i64 = 1;");
sqlAndCompareResult(
"SELECT COUNT(*) FROM " + delete_table_name + " WHERE i64 = 1;",
{{int64_t(0)}});
} else {
// run select
runSqlExecuteTest(select_table_name, dt);
}
},
"test_parallel_0",
"test_parallel_1",
dt));
}
for (auto& t : worker_threads) {
t.get();
}
}
}
TEST_P(UpdateDeleteTestEnv, UpdateDelete_TwoTables) {
TExecuteMode::type const dt = std::get<DT>(param_);
{
SKIP_NO_GPU();
setExecuteMode(dt);
std::vector<std::future<void>> worker_threads;
// three readers, one delete, one update
for (size_t j = 0; j < 5; j++) {
worker_threads.push_back(std::async(
std::launch::async,
[this, j](const std::string& update_table_name,
const std::string& delete_table_name,
const TExecuteMode::type dt) {
if (j == 0) {
// run insert, then delete
sql("INSERT INTO " + delete_table_name +
" VALUES(1, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);");
sql("DELETE FROM " + delete_table_name + " WHERE i64 = 1;");
sqlAndCompareResult(
"SELECT COUNT(*) FROM " + delete_table_name + " WHERE i64 = 1;",
{{int64_t(0)}});
} else if (j == 1) {
sql("UPDATE " + update_table_name + " SET i32 = -1 WHERE i64 = 500;");
} else {
// run select
sqlAndCompareResult(
"SELECT MIN(d) FROM " + update_table_name + " WHERE i1 IS NOT NULL;",
{{1.0001}});
}
},
"test_parallel_0",
"test_parallel_1",
dt));
}
for (auto& t : worker_threads) {
t.get();
}
}
}
INSTANTIATE_TEST_SUITE_P(
SingleTableTest,
SingleTableTestEnv,
::testing::Combine(::testing::Values(TExecuteMode::type::CPU,
TExecuteMode::type::GPU),
::testing::ValuesIn(num_executors_vec(g_max_num_executors))),
TestNameSuffix{});
INSTANTIATE_TEST_SUITE_P(
MultiTableTest,
MultiTableTestEnv,
::testing::Combine(::testing::Values(TExecuteMode::type::CPU,
TExecuteMode::type::GPU),
::testing::ValuesIn(num_executors_vec(g_max_num_executors))),
TestNameSuffix{});
INSTANTIATE_TEST_SUITE_P(UpdateDeleteTest,
UpdateDeleteTestEnv,
::testing::Combine(::testing::Values(TExecuteMode::type::CPU,
TExecuteMode::type::GPU),
::testing::Values(g_max_num_executors)),
TestNameSuffix{});
int main(int argc, char* argv[]) {
g_is_test_env = true;
g_enable_executor_resource_mgr = false;
TestHelpers::init_logger_stderr_only(argc, argv);
namespace po = boost::program_options;
po::options_description desc("Options");
desc.add_options()("keep-data", "Don't drop tables at the end of the tests");
desc.add_options()(
"num-executors",
po::value<NumExecutors>(&g_max_num_executors)->default_value(g_max_num_executors),
"Maximum number of parallel executors to test (most tests will start with 1 "
"executor and increase by doubling until max is reached).");
desc.add_options()(
"enable-executor-resource-mgr",
po::value<bool>(&g_enable_executor_resource_mgr)->implicit_value(true),
"Enable executor resource manager to track execution resources and "
"selectively gate concurrency based on resource availability.");
logger::LogOptions log_options(argv[0]);
log_options.max_files_ = 0; // stderr only by default
desc.add(log_options.get_options());
po::variables_map vm;
po::store(po::command_line_parser(argc, argv).options(desc).allow_unregistered().run(),
vm);
po::notify(vm);
if (vm.count("keep-data")) {
g_keep_data = true;
}
if (g_enable_executor_resource_mgr) {
#ifdef HAVE_TSAN
// Parallel executor tests allocate too much memory to
// instrument under TSAN, so only enable the ExecutorResourceMgr
// (i.e. parallel kernel execution) if TSAN is off.
// Note that some parallel kernel execution is tested under TSAN
// in ConcurrencyTest, although before we turn on parallel kernel execution
// by default we probably will want to find a way to moderate resource requirements
// to run this test under TSAN as well.
// Todo(todd): Find way to run this test with parallel kernel execution on
// and TSAN enabled
return 0;
#endif
}
int err{0};
try {
testing::InitGoogleTest(&argc, argv);
testing::AddGlobalTestEnvironment(new DBHandlerTestEnvironment);
err = RUN_ALL_TESTS();
} catch (const std::exception& e) {
LOG(ERROR) << e.what();
}
return err;
}