mapleFU commented on PR #35527:
URL: https://github.com/apache/arrow/pull/35527#issuecomment-1542079281
Seems this was caused by gandiva or CI changed, I guess this will not
produce a nullptr or uninitialized:
```c++
llvm::Type* selection_vector_type;
switch (selection_vector_mode) {
case SelectionVector::MODE_NONE:
case SelectionVector::MODE_UINT16:
arguments.push_back(types()->ptr_type(types()->i16_type()));
selection_vector_type = types()->i16_type();
break;
case SelectionVector::MODE_UINT32:
arguments.push_back(types()->i32_ptr_type());
selection_vector_type = types()->i32_type();
break;
case SelectionVector::MODE_UINT64:
arguments.push_back(types()->i64_ptr_type());
selection_vector_type = types()->i64_type();
break;
}
```
```
[125/131] Building CXX object
src/gandiva/CMakeFiles/gandiva_shared.dir/Unity/unity_4_cxx.cxx.obj
In file included from
D:/a/arrow/arrow/build/cpp/src/gandiva/CMakeFiles/gandiva_shared.dir/Unity/unity_4_cxx.cxx:5:
D:/a/arrow/arrow/cpp/src/gandiva/llvm_generator.cc: In member function
'arrow::Status gandiva::LLVMGenerator::CodeGenExprValue(gandiva::DexPtr, int,
gandiva::FieldDescriptorPtr, int, std::string&,
gandiva::SelectionVector::Mode)':
D:/a/arrow/arrow/cpp/src/gandiva/llvm_generator.cc:362:27: warning:
'selection_vector_type' may be used uninitialized [-Wmaybe-uninitialized]
362 | builder->CreateGEP(selection_vector_type,
arg_selection_vector, loop_var);
|
~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
D:/a/arrow/arrow/cpp/src/gandiva/llvm_generator.cc:282:15: note:
'selection_vector_type' was declared here
282 | llvm::Type* selection_vector_type;
| ^~~~~~~~~~~~~~~~~~~~~
```
--
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]