forked from learning-process/parallel_programming_course
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathops_mpi.hpp
More file actions
28 lines (20 loc) · 718 Bytes
/
ops_mpi.hpp
File metadata and controls
28 lines (20 loc) · 718 Bytes
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
#pragma once
#include <vector>
#include "core/task/include/task.hpp"
namespace nesterov_a_test_task_mpi {
void MultiplyRowMajor(const std::vector<int> &in, std::vector<int> &out, int rc_size);
void MultiplyColumnMajor(const std::vector<int> &in, std::vector<int> &out, int rc_size);
class TestTaskMPI : public ppc::core::Task {
public:
explicit TestTaskMPI(const std::vector<int> &in) : input_(in) {}
bool ValidationImpl() override;
bool PreProcessingImpl() override;
bool RunImpl() override;
bool PostProcessingImpl() override;
std::vector<int> Get();
private:
std::vector<int> input_, output_;
int rc_size_{};
void MultiplyMatrixBasedOnRank();
};
} // namespace nesterov_a_test_task_mpi