17 #include <gtest/gtest.h>
18 #include <boost/bind.hpp>
25 using namespace impala;
32 long arg =
reinterpret_cast<long>(value);
38 for (
int i = 0; i < 10000; ++i) {
39 for (
int j = 0; j < 200; ++j) {
40 result += sin(i) + cos(j);
62 int num_work_items = 100;
66 for (
int i = 0; i < num_work_items; ++i) {
72 reinterpret_cast<void**>(&args[0]), args.size());
73 EXPECT_TRUE(status.
ok());
80 int main(
int argc,
char **argv) {
81 ::testing::InitGoogleTest(&argc, argv);
83 return RUN_ALL_TESTS();
ParallelExecutorTest(int num_updates)
vector< int > updates_found_
void InitThreading()
Initialises the threading subsystem. Must be called before a Thread is created.
Status UpdateFunction(void *value)
int main(int argc, char **argv)
static Status Exec(Function function, void **args, int num_args, StatsMetric< double > *latencies=NULL)
Callers may pass a StatsMetric to gather the latency distribution of task execution.