提交 695f2db6 编写于 作者: L luotao1

update expected_kernel_cache_pass

test=develop
上级 226596a2
......@@ -20,15 +20,13 @@ namespace paddle {
namespace framework {
namespace ir {
std::unique_ptr<ir::Graph> ExpectedKernelCachePass::ApplyImpl(
std::unique_ptr<ir::Graph> graph) const {
void ExpectedKernelCachePass::ApplyImpl(ir::Graph* graph) const {
VLOG(3) << "Applies Expected Kernel Cache strategy.";
for (const Node* n : graph->Nodes()) {
if (n->IsOp()) {
n->Op()->SetAttr(kEnableCacheExpectedKernel, true);
}
}
return graph;
}
} // namespace ir
......
......@@ -23,8 +23,7 @@ namespace ir {
class ExpectedKernelCachePass : public Pass {
protected:
std::unique_ptr<ir::Graph> ApplyImpl(
std::unique_ptr<ir::Graph> graph) const override;
void ApplyImpl(ir::Graph* graph) const override;
};
} // namespace ir
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册