-
Notifications
You must be signed in to change notification settings - Fork 825
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refine onednn primitive & use runitme env var to enable onednn #8274
Conversation
oneflow/core/ep/cpu/cpu_stream.cpp
Outdated
@@ -27,6 +27,64 @@ Maybe<void> CpuStream::Sync() { return Maybe<void>::Ok(); } | |||
|
|||
void CpuStream::RecordEvent(Event* /*event*/) {} | |||
|
|||
void CpuStream::ParallelFor(int64_t begin, int64_t end, const ParallelForFuncType& func) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里 func 还是建议用模板参数类型好一些,std::function 有额外开销
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
好的
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
虽然但是我觉得我们是不是可以搞一个轻量的 std::function 直接用模板参数类型感觉不是很清真
|
||
namespace oneflow { | ||
|
||
DEFINE_ENV_BOOL(ONEFLOW_ENABLE_ONEDNN_OPTS, true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里的 OPTS 是什么的缩写
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No description provided.