Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
Actor Framework
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cpp-libs
Actor Framework
Commits
1c4e4072
Commit
1c4e4072
authored
Aug 28, 2013
by
Joseph Noir
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
removed unused class (command_dummy)
removed command_dummy, renamed command_impl to command
parent
8d91ddb7
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
31 deletions
+12
-31
libcaf_opencl/cppa/opencl/actor_facade.hpp
libcaf_opencl/cppa/opencl/actor_facade.hpp
+5
-5
libcaf_opencl/cppa/opencl/command.hpp
libcaf_opencl/cppa/opencl/command.hpp
+7
-26
No files found.
libcaf_opencl/cppa/opencl/actor_facade.hpp
View file @
1c4e4072
...
@@ -65,7 +65,7 @@ class actor_facade;
...
@@ -65,7 +65,7 @@ class actor_facade;
template
<
typename
Ret
,
typename
...
Args
>
template
<
typename
Ret
,
typename
...
Args
>
class
actor_facade
<
Ret
(
Args
...)
>
:
public
actor
{
class
actor_facade
<
Ret
(
Args
...)
>
:
public
actor
{
friend
class
command
_impl
<
actor_facade
,
Ret
>
;
friend
class
command
<
actor_facade
,
Ret
>
;
public:
public:
...
@@ -159,7 +159,7 @@ class actor_facade<Ret(Args...)> : public actor {
...
@@ -159,7 +159,7 @@ class actor_facade<Ret(Args...)> : public actor {
add_arguments_to_kernel
<
Ret
>
(
arguments
,
add_arguments_to_kernel
<
Ret
>
(
arguments
,
ret_size
,
ret_size
,
get_ref
<
Is
>
(
*
opt
)...);
get_ref
<
Is
>
(
*
opt
)...);
auto
cmd
=
make_counted
<
command
_impl
<
actor_facade
,
Ret
>>
(
handle
,
auto
cmd
=
make_counted
<
command
<
actor_facade
,
Ret
>>
(
handle
,
this
,
this
,
std
::
move
(
arguments
),
std
::
move
(
arguments
),
m_queue
);
m_queue
);
...
...
libcaf_opencl/cppa/opencl/command.hpp
View file @
1c4e4072
...
@@ -46,29 +46,12 @@
...
@@ -46,29 +46,12 @@
namespace
cppa
{
namespace
opencl
{
namespace
cppa
{
namespace
opencl
{
class
command
:
public
ref_counted
{
public:
command
*
next
;
virtual
void
enqueue
()
=
0
;
};
class
command_dummy
:
public
command
{
public:
void
enqueue
()
override
{
}
};
template
<
typename
T
,
typename
R
>
template
<
typename
T
,
typename
R
>
class
command
_impl
:
public
comman
d
{
class
command
:
public
ref_counte
d
{
public:
public:
command
_impl
(
response_handle
handle
,
command
(
response_handle
handle
,
intrusive_ptr
<
T
>
actor_facade
,
intrusive_ptr
<
T
>
actor_facade
,
std
::
vector
<
mem_ptr
>
arguments
,
std
::
vector
<
mem_ptr
>
arguments
,
command_queue_ptr
queue
)
command_queue_ptr
queue
)
...
@@ -80,7 +63,7 @@ class command_impl : public command {
...
@@ -80,7 +63,7 @@ class command_impl : public command {
,
m_queue
(
queue
)
,
m_queue
(
queue
)
,
m_arguments
(
move
(
arguments
))
{
}
,
m_arguments
(
move
(
arguments
))
{
}
void
enqueue
()
override
{
void
enqueue
()
{
CPPA_LOG_TRACE
(
"command::enqueue()"
);
CPPA_LOG_TRACE
(
"command::enqueue()"
);
this
->
ref
();
// reference held by the OpenCL comand queue
this
->
ref
();
// reference held by the OpenCL comand queue
cl_int
err
{
0
};
cl_int
err
{
0
};
...
@@ -106,7 +89,7 @@ class command_impl : public command {
...
@@ -106,7 +89,7 @@ class command_impl : public command {
err
=
clSetEventCallback
(
event
,
err
=
clSetEventCallback
(
event
,
CL_COMPLETE
,
CL_COMPLETE
,
[](
cl_event
,
cl_int
,
void
*
data
)
{
[](
cl_event
,
cl_int
,
void
*
data
)
{
auto
cmd
=
reinterpret_cast
<
command
_impl
*>
(
data
);
auto
cmd
=
reinterpret_cast
<
command
*>
(
data
);
cmd
->
handle_results
();
cmd
->
handle_results
();
cmd
->
deref
();
cmd
->
deref
();
},
},
...
@@ -151,8 +134,6 @@ class command_impl : public command {
...
@@ -151,8 +134,6 @@ class command_impl : public command {
}
}
};
};
typedef
intrusive_ptr
<
command
>
command_ptr
;
}
}
// namespace cppa::opencl
}
}
// namespace cppa::opencl
#endif // CPPA_OPENCL_COMMAND_HPP
#endif // CPPA_OPENCL_COMMAND_HPP
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