gemini-code-assist[bot] commented on code in PR #18450:
URL: https://github.com/apache/tvm/pull/18450#discussion_r2527423453


##########
web/src/runtime.ts:
##########
@@ -1421,6 +1421,12 @@ export class Instance implements Disposable {
           throw err;
         }
       }
+      if (i === 0) {
+        // Reset for the loading phase to avoid double counting with download 
phase.
+        fetchedBytes = 0;
+      }
+      fetchedBytes += shard.nbytes;
+      timeElapsed = Math.ceil((perf.now() - tstart) / 1000);

Review Comment:
   Understood. I agree that adhering to the single responsibility principle for 
this PR is a sound approach. Deferring the change from `Math.ceil` to 
`Math.round` to a separate refactoring effort makes sense to keep this PR 
focused on its primary goal of fixing progress reporting for cached loads. 
Thanks for the clarification!



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to