MCPcopy Create free account
hub / github.com/apache/arrow / AddKernel

Function AddKernel

cpp/src/arrow/compute/kernels/vector_replace.cc:805–823  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

803};
804
805void AddKernel(Type::type type_id, std::shared_ptr<KernelSignature> signature,
806 ArrayKernelExec exec, VectorKernel::ChunkedExec exec_chunked,
807 FunctionRegistry* registry, VectorFunction* func) {
808 VectorKernel kernel;
809 kernel.can_execute_chunkwise = false;
810 if (is_fixed_width(type_id)) {
811 kernel.null_handling = NullHandling::type::COMPUTED_PREALLOCATE;
812 } else {
813 kernel.can_write_into_slices = false;
814 kernel.null_handling = NullHandling::type::COMPUTED_NO_PREALLOCATE;
815 }
816 kernel.mem_allocation = MemAllocation::type::PREALLOCATE;
817 kernel.signature = std::move(signature);
818 kernel.exec = std::move(exec);
819 kernel.exec_chunked = exec_chunked;
820 kernel.can_execute_chunkwise = false;
821 kernel.output_chunked = false;
822 DCHECK_OK(func->AddKernel(std::move(kernel)));
823}
824
825template <template <class> class Functor, template <class> class ChunkedFunctor>
826void RegisterVectorFunction(FunctionRegistry* registry,

Callers 2

AddKernelMethod · 0.85
RegisterVectorFunctionFunction · 0.85

Calls 2

is_fixed_widthFunction · 0.85
AddKernelMethod · 0.45

Tested by

no test coverage detected