Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
Hercules
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
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
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
llvm
Hercules
Merge requests
!216
More optimizations
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
More optimizations
more_opt4
into
main
Overview
0
Commits
11
Pipelines
3
Changes
2
Merged
rarbore2
requested to merge
more_opt4
into
main
2 weeks ago
Overview
0
Commits
11
Pipelines
3
Changes
2
Expand
Speedup backprop
Fix gpu backend for different CUDA versions
0
0
Merge request reports
Viewing commit
94950efe
Prev
Next
Show latest version
2 files
+
67
−
86
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
2
Search (e.g. *.vue) (Ctrl+P)
94950efe
Load inputs once in benches
· 94950efe
Aaron Councilman
authored
2 weeks ago
juno_samples/rodinia/bfs/benches/bfs_bench.rs
+
11
−
30
Options
@@ -13,41 +13,22 @@ fn bfs_bench(c: &mut Criterion) {
let
mut
r
=
runner!
(
bfs
);
group
.bench_function
(
"bfs bench 4096"
,
|
b
|
{
let
input
=
"data/graph4096.txt"
;
let
(
nodes
,
source
,
edges
)
=
parse_graph
(
input
.into
())
.unwrap
();
let
n
=
nodes
.len
()
as
u64
;
let
m
=
edges
.len
()
as
u64
;
let
nodes
=
HerculesImmBox
::
from
(
&
nodes
as
&
[
Node
]);
let
edges
=
HerculesImmBox
::
from
(
&
edges
as
&
[
u32
]);
b
.iter
(||
{
async_std
::
task
::
block_on
(
async
{
r
.run
(
n
,
m
,
nodes
.to
(),
source
,
edges
.to
())
.await
});
})
});
group
.bench_function
(
"bfs bench 65536"
,
|
b
|
{
let
input
=
"data/graph65536.txt"
;
let
(
nodes
,
source
,
edges
)
=
parse_graph
(
input
.into
())
.unwrap
();
let
n
=
nodes
.len
()
as
u64
;
let
m
=
edges
.len
()
as
u64
;
let
nodes
=
HerculesImmBox
::
from
(
&
nodes
as
&
[
Node
]);
let
edges
=
HerculesImmBox
::
from
(
&
edges
as
&
[
u32
]);
b
.iter
(||
{
async_std
::
task
::
block_on
(
async
{
r
.run
(
n
,
m
,
nodes
.to
(),
source
,
edges
.to
())
.await
});
})
});
group
.bench_function
(
"bfs bench 64M"
,
|
b
|
{
let
input
=
"/scratch/aaronjc4/rodinia_3.1/data/bfs/graph64M.txt"
;
let
mut
bench
=
|
name
,
input
:
&
'_
str
|
{
let
(
nodes
,
source
,
edges
)
=
parse_graph
(
input
.into
())
.expect
(
"PANIC: Couldn't read input file for 64M benchmark. Currently, this benchmark uses a hard-coded path, so it can only be run on the lab machines."
);
let
n
=
nodes
.len
()
as
u64
;
let
m
=
edges
.len
()
as
u64
;
let
nodes
=
HerculesImmBox
::
from
(
&
nodes
as
&
[
Node
]);
let
edges
=
HerculesImmBox
::
from
(
&
edges
as
&
[
u32
]);
b
.iter
(||
{
async_std
::
task
::
block_on
(
async
{
r
.run
(
n
,
m
,
nodes
.to
(),
source
,
edges
.to
())
.await
});
})
});
group
.bench_function
(
name
,
|
b
|
{
b
.iter
(||
{
async_std
::
task
::
block_on
(
async
{
r
.run
(
n
,
m
,
nodes
.to
(),
source
,
edges
.to
())
.await
});
})
});
};
bench
(
"bfs bench 4096"
,
"data/graph4096.txt"
);
bench
(
"bfs bench 65536"
,
"data/graph65536.txt"
);
bench
(
"bfs bench 64M"
,
"/scratch/aaronjc4/rodinia_3.1/data/bfs/graph64M.txt"
);
}
criterion_group!
(
benches
,
bfs_bench
);
Loading