Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Minor] Fix Clang compilation warning in fuse_tir.cc and codegen_c_host.cc #16511

Merged
merged 1 commit into from
Feb 3, 2024

Conversation

Hzfengsy
Copy link
Member

@Hzfengsy Hzfengsy commented Feb 2, 2024

The original two warnings are:

[build] /Users/syfeng/tvm/src/relax/transform/fuse_tir.cc:685:48: warning: lambda capture 'param' is not used [-Wunused-lambda-capture]
[build]       auto unify_name_hints = [this, &buffer, &param]() {
[build]                                             ~~~^~~~~

[build] /Users/syfeng/tvm/src/target/source/codegen_c_host.h:47:8: warning: 'tvm::codegen::CodeGenCHost::AddFunction' hides overloaded virtual function [-Woverloaded-virtual]
[build]   void AddFunction(const GlobalVar& gvar, const PrimFunc& f, bool emit_fwd_func_decl = false);
[build]        ^
[build] /Users/syfeng/tvm/src/target/source/codegen_c.h:86:16: note: hidden overloaded virtual function 'tvm::codegen::CodeGenC::AddFunction' declared here: different number of parameters (2 vs 3)
[build]   virtual void AddFunction(const GlobalVar& gvar, const PrimFunc& func);
[build]                ^

…st.cc

The original warning is:
```
[build] /Users/syfeng/tvm/src/relax/transform/fuse_tir.cc:685:48: warning: lambda capture 'param' is not used [-Wunused-lambda-capture]
[build]       auto unify_name_hints = [this, &buffer, &param]() {
[build]                                             ~~~^~~~~

[build] /Users/syfeng/tvm/src/target/source/codegen_c_host.h:47:8: warning: 'tvm::codegen::CodeGenCHost::AddFunction' hides overloaded virtual function [-Woverloaded-virtual]
[build]   void AddFunction(const GlobalVar& gvar, const PrimFunc& f, bool emit_fwd_func_decl = false);
[build]        ^
[build] /Users/syfeng/tvm/src/target/source/codegen_c.h:86:16: note: hidden overloaded virtual function 'tvm::codegen::CodeGenC::AddFunction' declared here: different number of parameters (2 vs 3)
[build]   virtual void AddFunction(const GlobalVar& gvar, const PrimFunc& func);
[build]                ^
```
Copy link
Contributor

@quic-sanirudh quic-sanirudh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks

@Hzfengsy Hzfengsy merged commit a3ec544 into apache:main Feb 3, 2024
19 checks passed
@Hzfengsy Hzfengsy deleted the fix_warning branch February 4, 2024 05:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants