mozga-intel edited a comment on issue #20196:
URL: 
https://github.com/apache/incubator-mxnet/issues/20196#issuecomment-860544111


   Thanks, @szha, @leezu for this issue.
   
   Currently, there are a lot of places, where it is needed. I got an idea to 
discuss. Since we can't define a variable/objects in a header file as an 
explicitly defined object `const mkldnn::memory::desc &md` and if this type is 
used by multiple functions: (i.e `Reorder2DefaultAsync` ), then the object 
might be passed by using a void pointer `const void *md`.  In the same way, 
each time you call oneDNN function, the `static_cast` is needed to create a 
particular object.
   ```
   const mkldnn::memory *mem = static_cast<const mkldnn::memory 
*>(GetMKLDNNData());
   ```
   
   Therefore, a header might be placed in *cc file. 
   Please have a look: #20349
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@mxnet.apache.org
For additional commands, e-mail: issues-h...@mxnet.apache.org

Reply via email to