Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
margo
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
18
Issues
18
List
Boards
Labels
Milestones
Merge Requests
2
Merge Requests
2
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
sds
margo
Commits
16c4d990
Commit
16c4d990
authored
May 05, 2016
by
Philip Carns
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
eliminate dedicated progress pool from clients
parent
b3f12b8c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
38 deletions
+11
-38
examples/client-timeout.c
examples/client-timeout.c
+5
-18
examples/client.c
examples/client.c
+6
-20
No files found.
examples/client-timeout.c
View file @
16c4d990
...
...
@@ -43,8 +43,6 @@ int main(int argc, char **argv)
ABT_xstream
xstream
;
ABT_pool
pool
;
margo_instance_id
mid
;
ABT_xstream
progress_xstream
;
ABT_pool
progress_pool
;
hg_context_t
*
hg_context
;
hg_class_t
*
hg_class
;
hg_addr_t
svr_addr
=
HG_ADDR_NULL
;
...
...
@@ -107,22 +105,14 @@ int main(int argc, char **argv)
return
(
-
1
);
}
/* create a dedicated ES drive Mercury progress */
ret
=
ABT_snoozer_xstream_create
(
1
,
&
progress_pool
,
&
progress_xstream
);
if
(
ret
!=
0
)
{
fprintf
(
stderr
,
"Error: ABT_snoozer_xstream_create()
\n
"
);
return
(
-
1
);
}
/* actually start margo */
/*
provide argobots pools for driving communication progress and
*
executing rpc handlers as well as class and context for Mercury
*
communication. The rpc handler pool is null in this example program
*
because this is a pure client that
will not be servicing rpc requests.
/*
Use main process to drive progress (it will relinquish control to
*
Mercury during blocking communication calls). The rpc handler pool
*
is null in this example program because this is a pure client that
* will not be servicing rpc requests.
*/
/***************************************/
mid
=
margo_init_pool
(
p
rogress_p
ool
,
ABT_POOL_NULL
,
hg_context
);
mid
=
margo_init_pool
(
pool
,
ABT_POOL_NULL
,
hg_context
);
/* register RPC */
my_rpc_id
=
MERCURY_REGISTER
(
hg_class
,
"my_rpc"
,
my_rpc_in_t
,
my_rpc_out_t
,
...
...
@@ -183,9 +173,6 @@ int main(int argc, char **argv)
/* shut down everything */
margo_finalize
(
mid
);
ABT_xstream_join
(
progress_xstream
);
ABT_xstream_free
(
&
progress_xstream
);
ABT_finalize
();
HG_Context_destroy
(
hg_context
);
...
...
examples/client.c
View file @
16c4d990
...
...
@@ -43,8 +43,6 @@ int main(int argc, char **argv)
ABT_xstream
xstream
;
ABT_pool
pool
;
margo_instance_id
mid
;
ABT_xstream
progress_xstream
;
ABT_pool
progress_pool
;
hg_context_t
*
hg_context
;
hg_class_t
*
hg_class
;
hg_addr_t
svr_addr
=
HG_ADDR_NULL
;
...
...
@@ -99,30 +97,21 @@ int main(int argc, char **argv)
{
fprintf
(
stderr
,
"Error: ABT_xstream_self()
\n
"
);
return
(
-
1
);
}
ret
=
ABT_xstream_get_main_pools
(
xstream
,
1
,
&
pool
);
}
ret
=
ABT_xstream_get_main_pools
(
xstream
,
1
,
&
pool
);
if
(
ret
!=
0
)
{
fprintf
(
stderr
,
"Error: ABT_xstream_get_main_pools()
\n
"
);
return
(
-
1
);
}
/* create a dedicated ES drive Mercury progress */
ret
=
ABT_snoozer_xstream_create
(
1
,
&
progress_pool
,
&
progress_xstream
);
if
(
ret
!=
0
)
{
fprintf
(
stderr
,
"Error: ABT_snoozer_xstream_create()
\n
"
);
return
(
-
1
);
}
/* actually start margo */
/*
provide argobots pools for driving communication progress and
*
executing rpc handlers as well as class and context for Mercury
*
communication. The rpc handler pool is null in this example program
*
because this is a pure client that
will not be servicing rpc requests.
/*
Use main process to drive progress (it will relinquish control to
*
Mercury during blocking communication calls). The rpc handler pool
*
is null in this example program because this is a pure client that
* will not be servicing rpc requests.
*/
/***************************************/
mid
=
margo_init_pool
(
p
rogress_p
ool
,
ABT_POOL_NULL
,
hg_context
);
mid
=
margo_init_pool
(
pool
,
ABT_POOL_NULL
,
hg_context
);
/* register RPC */
my_rpc_id
=
MERCURY_REGISTER
(
hg_class
,
"my_rpc"
,
my_rpc_in_t
,
my_rpc_out_t
,
...
...
@@ -185,9 +174,6 @@ int main(int argc, char **argv)
/* shut down everything */
margo_finalize
(
mid
);
ABT_xstream_join
(
progress_xstream
);
ABT_xstream_free
(
&
progress_xstream
);
ABT_finalize
();
HG_Context_destroy
(
hg_context
);
...
...
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