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


##########
src/s_tir/transform/inject_software_pipeline.cc:
##########
@@ -42,6 +43,14 @@ using namespace tvm::tirx;
 
 namespace software_pipeline {
 
+bool IsOp(const Call& call, const Op& compat_op, const char* canonical_name) {

Review Comment:
   ![medium](https://www.gstatic.com/codereviewagent/medium-priority.svg)
   
   The helper function `IsOp` is only used within this translation unit. To 
prevent potential linker collisions (ODR violations) and namespace pollution, 
it should be given internal linkage by declaring it `static` or placing it in 
an anonymous namespace, in accordance with the Google C++ Style Guide.
   
   ```suggestion
   static bool IsOp(const Call& call, const Op& compat_op, const char* 
canonical_name) {
   ```
   
   <details>
   <summary>References</summary>
   
   1. Google C++ Style Guide: When definitions in a .cc file do not need to be 
referenced outside that file, give them internal linkage by placing them in an 
unnamed namespace or declaring them static. 
<sup>([link](http://console.cloud.google.com/gemini-code-assist/agents-tools))</sup>
   </details>



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to