Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
O
openfpm_pdata
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
1
Issues
1
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Environments
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
openfpm
openfpm_pdata
Commits
1dc070fe
Commit
1dc070fe
authored
Aug 06, 2015
by
incardon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixing LLVM compilation
parent
6531e554
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
8 deletions
+6
-8
src/Decomposition/CartDecomposition.hpp
src/Decomposition/CartDecomposition.hpp
+6
-8
No files found.
src/Decomposition/CartDecomposition.hpp
View file @
1dc070fe
...
...
@@ -32,8 +32,6 @@
* \tparam layout to use
* \tparam Memory Memory factory used to allocate memory
* \tparam Domain Structure that contain the information of your physical domain
* \tparam data type of structure that store the sub-domain decomposition can be an openfpm structure like
* vector, ...
*
* Given an N-dimensional space, this class decompose the space into a Cartesian grid of small
* sub-sub-domain. At each sub-sub-domain is assigned an id that identify which processor is
...
...
@@ -63,7 +61,7 @@
*
*/
template
<
unsigned
int
dim
,
typename
T
,
template
<
typename
>
class
device_l
=
openfpm
::
device_cpu
,
typename
Memory
=
HeapMemory
,
template
<
unsigned
int
,
typename
>
class
Domain
=
Box
,
template
<
typename
,
typename
,
typename
,
typename
,
unsigned
int
>
class
data_s
=
openfpm
::
vector
>
template
<
unsigned
int
dim
,
typename
T
,
template
<
typename
>
class
device_l
=
openfpm
::
device_cpu
,
typename
Memory
=
HeapMemory
,
template
<
unsigned
int
,
typename
>
class
Domain
=
Box
>
class
CartDecomposition
{
struct
N_box
...
...
@@ -151,7 +149,7 @@ class CartDecomposition
}
// encap interface to make compatible with OpenFPM_IO
template
<
int
i
>
auto
get
()
->
decltype
(
st
atic_cast
<
Box
<
dim
,
T
>
*>
(
this
)
->
template
get
<
i
>())
template
<
int
i
>
auto
get
()
->
decltype
(
st
d
::
declval
<
Box
<
dim
,
T
>
*>
(
)
->
template
get
<
i
>())
{
return
::
Box
<
dim
,
T
>::
template
get
<
i
>();
}
...
...
@@ -192,7 +190,7 @@ private:
//! This is the key type to access data_s, for example in the case of vector
//! acc_key is size_t
typedef
typename
data_s
<
SpaceBox
<
dim
,
T
>
,
device_l
<
SpaceBox
<
dim
,
T
>>
,
Memory
,
openfpm
::
vector_grow_policy_default
,
openfpm
::
vect_isel
<
SpaceBox
<
dim
,
T
>>::
value
>::
access_key
acc_key
;
typedef
typename
openfpm
::
vector
<
SpaceBox
<
dim
,
T
>
,
device_l
<
SpaceBox
<
dim
,
T
>>
,
Memory
,
openfpm
::
vector_grow_policy_default
,
openfpm
::
vect_isel
<
SpaceBox
<
dim
,
T
>>::
value
>::
access_key
acc_key
;
//! the margin of the sub-domain selected
SpaceBox
<
dim
,
T
>
sub_domain
;
...
...
@@ -772,7 +770,7 @@ private:
static
void
*
message_alloc
(
size_t
msg_i
,
size_t
total_msg
,
size_t
total_p
,
size_t
i
,
size_t
ri
,
void
*
ptr
)
{
// cast the pointer
CartDecomposition
<
dim
,
T
,
device_l
,
Memory
,
Domain
,
data_s
>
*
cd
=
static_cast
<
CartDecomposition
<
dim
,
T
,
device_l
,
Memory
,
Domain
,
data_s
>
*>
(
ptr
);
CartDecomposition
<
dim
,
T
,
device_l
,
Memory
,
Domain
>
*
cd
=
static_cast
<
CartDecomposition
<
dim
,
T
,
device_l
,
Memory
,
Domain
>
*>
(
ptr
);
// Resize the memory
cd
->
nn_processor_subdomains
[
i
].
bx
.
resize
(
msg_i
/
sizeof
(
::
Box
<
dim
,
T
>
)
);
...
...
@@ -788,7 +786,7 @@ public:
* \param v_cl Virtual cluster, used internally to handle or pipeline communication
*
*/
CartDecomposition
(
CartDecomposition
<
dim
,
T
,
device_l
,
Memory
,
Domain
,
data_s
>
&&
cd
)
CartDecomposition
(
CartDecomposition
<
dim
,
T
,
device_l
,
Memory
,
Domain
>
&&
cd
)
:
sub_domain
(
cd
.
sub_domain
),
gr
(
cd
.
gr
),
cd
(
cd
.
cd
),
domain
(
cd
.
domain
),
v_cl
(
cd
.
v_cl
)
{
// Reset the box to zero
...
...
@@ -1126,7 +1124,7 @@ p1[0]<-----+ +----> p2[0]
// Intersect all the local sub-domains with the sub-domains of the contiguous processors
// Get the sub-domains of the near processors
v_cl
.
sendrecvMultipleMessagesNBX
(
nn_processors
,
boxes
,
CartDecomposition
<
dim
,
T
,
device_l
,
Memory
,
Domain
,
data_s
>::
message_alloc
,
this
,
NEED_ALL_SIZE
);
v_cl
.
sendrecvMultipleMessagesNBX
(
nn_processors
,
boxes
,
CartDecomposition
<
dim
,
T
,
device_l
,
Memory
,
Domain
>::
message_alloc
,
this
,
NEED_ALL_SIZE
);
// create the internal structures that store ghost information
create_box_nn_processor_ext
(
ghost
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment