cjolivier01 commented on a change in pull request #9464: refactor logging in
infer storage pass
URL: https://github.com/apache/incubator-mxnet/pull/9464#discussion_r162443172
##########
File path: src/common/utils.h
##########
@@ -364,6 +364,50 @@ inline std::string dev_type_string(const int dev_type) {
return "unknown";
}
+/*! \brief get string representation of the operator stypes */
+inline std::string operator_stype_string(const nnvm::NodeAttrs& attrs,
+ const int dev_mask,
+ const std::vector<int>& in_attrs,
+ const std::vector<int>& out_attrs) {
+ std::string result = "";
Review comment:
It's pretty expensive to do a lot of string +='s because it causes lots of
reallocations/copies. Maybe better to use stringstream/strstream like you did
with the fallback warning?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services