Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
gpma_bfs
Manage
Activity
Members
Labels
Plan
Issues
2
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
Recolic
gpma_bfs
Commits
4bedf6cb
There was an error fetching the commit references. Please try again later.
Commit
4bedf6cb
authored
5 years ago
by
Recolic Keghart
Browse files
Options
Downloads
Patches
Plain Diff
adjust outputs and add script for report writing
parent
978a252c
No related branches found
No related tags found
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
Makefile
+2
-1
2 additions, 1 deletion
Makefile
gpma.cuh
+2
-2
2 additions, 2 deletions
gpma.cuh
gpma_bfs_demo.cu
+9
-1
9 additions, 1 deletion
gpma_bfs_demo.cu
par_test.fish
+10
-0
10 additions, 0 deletions
par_test.fish
with
23 additions
and
4 deletions
Makefile
+
2
−
1
View file @
4bedf6cb
...
...
@@ -9,7 +9,8 @@ TEST_DEV ?= GPU
OMP_FLAGS
=
-Xcompiler
-fopenmp
NVFLAGS
=
-I
.
-O3
-std
=
c++14
-DCUDA_SM
=
$(
SM
)
-arch
sm_
$(
SM
)
--relocatable-device-code
=
true
--extended-lambda
$(
OMP_FLAGS
)
-g
EXTRA_FLAGS
?=
-g
NVFLAGS
=
-I
.
-O3
-std
=
c++14
-DCUDA_SM
=
$(
SM
)
-arch
sm_
$(
SM
)
--relocatable-device-code
=
true
--extended-lambda
$(
OMP_FLAGS
)
$(
EXTRA_FLAGS
)
default
:
$(
NVCC
)
$(
NVFLAGS
)
gpma_bfs_demo.cu
-o
gpma_bfs_demo
-lgomp
...
...
This diff is collapsed.
Click to expand it.
gpma.cuh
+
2
−
2
View file @
4bedf6cb
...
...
@@ -969,7 +969,7 @@ template <dev_type_t DEV>
__host__
void
update_gpma
(
GPMA
<
DEV
>
&
gpma
,
NATIVE_VEC_KEY
<
DEV
>
&
update_keys
,
NATIVE_VEC_VALUE
<
DEV
>
&
update_values
)
{
DEBUG_PRINTFLN
(
"DBG: (ENTER UPDATE)update_gpma args, update_keys={}, values={}"
,
rlib
::
printable_iter
(
update_keys
),
rlib
::
printable_iter
(
values_for_print
(
update_values
)));
gpma
.
print_status
(
"ENTER update_gpma"
);
rlib
::
printfln
(
"DBG: tree_height={}, update_size={}"
,
gpma
.
tree_height
,
update_keys
.
size
());
//
rlib::printfln("DBG: tree_height={}, update_size={}", gpma.tree_height, update_keys.size());
//LOG_TIME("enter_update_gpma")
...
...
@@ -1046,5 +1046,5 @@ __host__ void update_gpma(GPMA<DEV> &gpma, NATIVE_VEC_KEY<DEV> &update_keys, NAT
anySync
<
DEV
>
();
gpma
.
print_status
(
"LEAVE update_gpma"
);
rlib
::
printfln
(
"DBG: (LEAVE UPDATE) ====================================================================================="
);
//
rlib::printfln("DBG: (LEAVE UPDATE) =====================================================================================");
}
This diff is collapsed.
Click to expand it.
gpma_bfs_demo.cu
+
9
−
1
View file @
4bedf6cb
...
...
@@ -62,7 +62,11 @@ int main(int argc, char **argv) {
LOG_TIME
(
"before init_csr_gpma"
)
constexpr
size_t
cpu_count
=
4
;
GPMA_multidev
<
cpu_count
-
1
,
1
>
gpma
(
node_size
);
#ifndef TEST_CPUS
#define TEST_CPUS cpu_count-1
#define TEST_GPUS 1
#endif
GPMA_multidev
<
TEST_CPUS
,
TEST_GPUS
>
gpma
(
node_size
);
cudaDeviceSynchronize
();
LOG_TIME
(
"before update_gpma 1"
)
...
...
@@ -71,9 +75,11 @@ int main(int argc, char **argv) {
cudaDeviceSynchronize
();
LOG_TIME
(
"before first bfs"
)
#ifndef _DISABLE_BFS
gpma_bfs
(
gpma
,
node_size
,
edge_size
,
bfs_start_node
,
RAW_PTR
(
bfs_result
));
int
reach_nodes
=
node_size
-
thrust
::
count
(
bfs_result
.
begin
(),
bfs_result
.
end
(),
0
);
printf
(
"start from node %d, number of reachable nodes: %d
\n
"
,
bfs_start_node
,
reach_nodes
);
#endif
LOG_TIME
(
"before main loop"
)
for
(
int
i
=
0
;
i
<
num_slide
;
i
++
)
{
...
...
@@ -99,9 +105,11 @@ int main(int argc, char **argv) {
printf
(
"Graph is updated.
\n
"
);
LOG_TIME
(
"before second bfs"
)
#ifndef _DISABLE_BFS
gpma_bfs
(
gpma
,
node_size
,
edge_size
,
bfs_start_node
,
RAW_PTR
(
bfs_result
));
reach_nodes
=
node_size
-
thrust
::
count
(
bfs_result
.
begin
(),
bfs_result
.
end
(),
0
);
printf
(
"start from node %d, number of reachable nodes: %d
\n
"
,
bfs_start_node
,
reach_nodes
);
#endif
LOG_TIME
(
"after second bfs"
)
return
0
;
...
...
This diff is collapsed.
Click to expand it.
par_test.fish
0 → 100644
+
10
−
0
View file @
4bedf6cb
#!/usr/bin/fish
for i in (seq 8)
echo CPUS=$i ===========================================
make EXTRA_FLAGS="-DTEST_CPUS=$i -DTEST_GPUS=0 -DTEST_DISABLE_BFS"
and time ./gpma_bfs_demo /tmp/999999999.pokec.txt 0
end
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment