Skip to content

Commit

Permalink
Fix clang llvm 12.0.1 warnings (#10744)
Browse files Browse the repository at this point in the history
* Fix warning: zero as null pointer constant [-Wzero-as-null-pointer-constant]

* Fix warning: private field 'first_for_' is not used [-Wunused-private-field]
  • Loading branch information
csullivan authored Mar 25, 2022
1 parent 0b2f5b7 commit 63461c0
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion src/target/llvm/codegen_llvm.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1265,7 +1265,7 @@ llvm::Value* CodeGenLLVM::VisitExpr_(const LetNode* op) {

llvm::Value* CodeGenLLVM::VisitExpr_(const LoadNode* op) {
LOG(FATAL) << "Unexpected deprecated LoadNode. Use BufferLoadNode instead.";
return NULL;
return nullptr;
}

bool CodeGenLLVM::HasAlignmentPadding(DataType dtype) {
Expand Down
1 change: 0 additions & 1 deletion src/tir/transforms/bind_params.cc
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@ class ParamsCollector : public StmtExprVisitor {
private:
std::vector<const tir::VarNode*> constant_list_;
Map<tir::Var, runtime::NDArray> constant_map_;
bool first_for_ = true;
};

namespace transform {
Expand Down

0 comments on commit 63461c0

Please sign in to comment.