Commit 3a8c6860 authored by PanZezhong's avatar PanZezhong
Browse files

issue/811 add warmups before cuda graph capture

parent 91f91f7c
......@@ -80,6 +80,12 @@ void Graph::instantiate() {
// Reset device graph
device_graph_ = std::make_unique<DeviceGraph>();
// warmup
for (size_t iter = 0; iter < 5; ++iter) {
this->run();
}
infinicore::context::syncStream();
if (infinirtStreamBeginCapture(
context::getStream(),
INFINIRT_STREAM_CAPTURE_MODE_GLOBAL)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment