-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
【CINN】refactor cuda query component #59096
【CINN】refactor cuda query component #59096
Conversation
你的PR提交成功,感谢你对开源项目的贡献! |
paddle/cinn/common/dev_info_base.h
Outdated
@@ -20,6 +20,10 @@ namespace common { | |||
class DevInfoBase { | |||
public: | |||
virtual ~DevInfoBase() = default; | |||
explicit DevInfoBase(int device = 0) : device_num_(device) {} |
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.
构造函数和析构函数位置调一下
这里传入的参数名改成device_num
好一些?
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.
done
} | ||
template <Target::Arch arch> | ||
DevInfoMgr<arch>::DevInfoMgr(int device_num) : device_num_(device_num) { | ||
impl = std::make_unique<NVGPUDevInfo>(device_num) |
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.
- impl少个下划线
- 指针类型这里不应该写死吧
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.
done
* refactor cuda query component * fix bugs * fix review comments * fix bugs * fix cuda error * bind should be used on NVGPU device
PR types
Others
PR changes
Others
Description
card-72718
This PR remove the ugly code for query nvgpu device info and refactor device info component for cinn