fix mkldnn linux build break. (#1458)

This commit is contained in:
jywu-msft 2019-07-22 12:22:49 -07:00 committed by GitHub
parent f938a6e53a
commit a5f57f43c2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 5 deletions

View file

@ -111,8 +111,7 @@ std::shared_ptr<KernelRegistry> MKLDNNExecutionProvider::GetKernelRegistry() con
return kernel_registry;
}
bool MKLDNNExecutionProvider::UseSubgraph(const onnxruntime::GraphViewer& graph_viewer,
const std::vector<const KernelRegistry*>& kernel_registries) const {
bool MKLDNNExecutionProvider::UseSubgraph(const onnxruntime::GraphViewer& graph_viewer) const {
// switch between mkldnn-vanilla and mkldnn-subgraph implementation using
// MKLDNN_SUBGRAPH environment variable
bool use_subgraph = true;
@ -224,7 +223,7 @@ std::vector<std::unique_ptr<ComputeCapability>> MKLDNNExecutionProvider::GetCapa
// temporary switch to toggle between mkldnn-vanilla and mkldnn-subgraph implementation using
// ORT_MKLDNN_SUBGRAPH environment variable
if (UseSubgraph(graph_viewer, kernel_registries) == false) {
if (UseSubgraph(graph_viewer) == false) {
return IExecutionProvider::GetCapability(graph_viewer, kernel_registries);
}

View file

@ -98,8 +98,7 @@ class MKLDNNExecutionProvider : public IExecutionProvider {
return graph_name;
}
bool UseSubgraph(const onnxruntime::GraphViewer& graph_viewer,
const std::vector<const KernelRegistry*>& kernel_registries) const;
bool UseSubgraph(const onnxruntime::GraphViewer& graph_viewer) const;
// Some dimensions are not supported by MKL-DNN
// example: Pool with NumDimensions <= 3 is not supported