xref: /llvm-project/pstl/include/pstl/internal/parallel_backend.h (revision 6069a6a5049497a32a50a49661c2f4169078bdba)
1 // -*- C++ -*-
2 //===----------------------------------------------------------------------===//
3 //
4 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
5 // See https://llvm.org/LICENSE.txt for license information.
6 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //
8 //===----------------------------------------------------------------------===//
9 
10 #ifndef _PSTL_PARALLEL_BACKEND_H
11 #define _PSTL_PARALLEL_BACKEND_H
12 
13 #include "pstl_config.h"
14 
15 #if defined(_PSTL_PAR_BACKEND_SERIAL)
16 #    include "parallel_backend_serial.h"
17 namespace __pstl
18 {
19 namespace __par_backend = __serial_backend;
20 }
21 #elif defined(_PSTL_PAR_BACKEND_TBB)
22 #    include "parallel_backend_tbb.h"
23 namespace __pstl
24 {
25 namespace __par_backend = __tbb_backend;
26 }
27 #elif defined(_PSTL_PAR_BACKEND_OPENMP)
28 #    include "parallel_backend_omp.h"
29 namespace __pstl
30 {
31 namespace __par_backend = __omp_backend;
32 }
33 #else
34 _PSTL_PRAGMA_MESSAGE("Parallel backend was not specified");
35 #endif
36 
37 #endif /* _PSTL_PARALLEL_BACKEND_H */
38