Skip to content

Commit

Permalink
Merge branch 'branch-22.12' into fea-strings-udf-cec
Browse files Browse the repository at this point in the history
  • Loading branch information
brandon-b-miller committed Oct 26, 2022
2 parents 049e63a + b89c0e2 commit 4ba3124
Show file tree
Hide file tree
Showing 514 changed files with 8,077 additions and 4,867 deletions.
57 changes: 0 additions & 57 deletions .github/workflows/stale.yaml

This file was deleted.

1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@ junit-cudf.xml
test-results

## Patching
*.diff
*.orig
*.rej

Expand Down
6 changes: 4 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,14 @@ repos:
# Explicitly specify the pyproject.toml at the repo root, not per-project.
args: ["--config", "pyproject.toml"]
- repo: https://github.com/PyCQA/flake8
rev: 3.8.3
rev: 5.0.4
hooks:
- id: flake8
args: ["--config=setup.cfg"]
files: python/.*\.(py|pyx|pxd)$
files: python/.*$
types: [file]
types_or: [python, cython]
additional_dependencies: ["flake8-force"]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: 'v0.971'
hooks:
Expand Down
6 changes: 3 additions & 3 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ BUILD_BENCHMARKS=OFF
BUILD_ALL_GPU_ARCH=0
BUILD_NVTX=ON
BUILD_TESTS=OFF
BUILD_DISABLE_DEPRECATION_WARNING=ON
BUILD_DISABLE_DEPRECATION_WARNINGS=ON
BUILD_PER_THREAD_DEFAULT_STREAM=OFF
BUILD_REPORT_METRICS=OFF
BUILD_REPORT_INCL_CACHE_STATS=OFF
Expand Down Expand Up @@ -216,7 +216,7 @@ if hasArg --opensource_nvcomp; then
USE_PROPRIETARY_NVCOMP="OFF"
fi
if hasArg --show_depr_warn; then
BUILD_DISABLE_DEPRECATION_WARNING=OFF
BUILD_DISABLE_DEPRECATION_WARNINGS=OFF
fi
if hasArg --ptds; then
BUILD_PER_THREAD_DEFAULT_STREAM=ON
Expand Down Expand Up @@ -285,7 +285,7 @@ if buildAll || hasArg libcudf; then
-DCUDF_USE_PROPRIETARY_NVCOMP=${USE_PROPRIETARY_NVCOMP} \
-DBUILD_TESTS=${BUILD_TESTS} \
-DBUILD_BENCHMARKS=${BUILD_BENCHMARKS} \
-DDISABLE_DEPRECATION_WARNING=${BUILD_DISABLE_DEPRECATION_WARNING} \
-DDISABLE_DEPRECATION_WARNINGS=${BUILD_DISABLE_DEPRECATION_WARNINGS} \
-DCUDF_USE_PER_THREAD_DEFAULT_STREAM=${BUILD_PER_THREAD_DEFAULT_STREAM} \
-DCMAKE_BUILD_TYPE=${BUILD_TYPE} \
${EXTRA_CMAKE_ARGS}
Expand Down
17 changes: 16 additions & 1 deletion ci/gpu/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -202,11 +202,26 @@ else
conda list --show-channel-urls

gpuci_logger "GoogleTests"

# Set up library for finding incorrect default stream usage.
cd "$WORKSPACE/cpp/tests/utilities/identify_stream_usage/"
mkdir build && cd build && cmake .. -GNinja && ninja && ninja test
STREAM_IDENTIFY_LIB="$WORKSPACE/cpp/tests/utilities/identify_stream_usage/build/libidentify_stream_usage.so"

# Run libcudf and libcudf_kafka gtests from libcudf-tests package
for gt in "$CONDA_PREFIX/bin/gtests/libcudf"*/* ; do
test_name=$(basename ${gt})

echo "Running GoogleTest $test_name"
${gt} --gtest_output=xml:"$WORKSPACE/test-results/"
if [[ ${test_name} == "SPAN_TEST" ]]; then
# This one test is specifically designed to test using a thrust device
# vector, so we expect and allow it to include default stream usage.
gtest_filter="SpanTest.CanConstructFromDeviceContainers"
GTEST_CUDF_STREAM_MODE="custom" LD_PRELOAD=${STREAM_IDENTIFY_LIB} ${gt} --gtest_output=xml:"$WORKSPACE/test-results/" --gtest_filter="-${gtest_filter}"
${gt} --gtest_output=xml:"$WORKSPACE/test-results/" --gtest_filter="${gtest_filter}"
else
GTEST_CUDF_STREAM_MODE="custom" LD_PRELOAD=${STREAM_IDENTIFY_LIB} ${gt} --gtest_output=xml:"$WORKSPACE/test-results/"
fi
done

# Test libcudf (csv, orc, and parquet) with `LIBCUDF_CUFILE_POLICY=KVIKIO`
Expand Down
4 changes: 4 additions & 0 deletions ci/release/update-version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ function sed_runner() {
# cpp update
sed_runner 's/'"VERSION ${CURRENT_SHORT_TAG}.*"'/'"VERSION ${NEXT_FULL_TAG}"'/g' cpp/CMakeLists.txt

# cpp stream testing update
sed_runner 's/'"VERSION ${CURRENT_SHORT_TAG}.*"'/'"VERSION ${NEXT_FULL_TAG}"'/g' cpp/tests/utilities/identify_stream_usage/CMakeLists.txt

# Python update
sed_runner 's/'"cudf_version .*)"'/'"cudf_version ${NEXT_FULL_TAG})"'/g' python/cudf/CMakeLists.txt

Expand Down Expand Up @@ -74,6 +77,7 @@ sed_runner "s/cudf=${CURRENT_SHORT_TAG}/cudf=${NEXT_SHORT_TAG}/g" README.md

# Libcudf examples update
sed_runner "s/CUDF_TAG branch-${CURRENT_SHORT_TAG}/CUDF_TAG branch-${NEXT_SHORT_TAG}/" cpp/examples/basic/CMakeLists.txt
sed_runner "s/CUDF_TAG branch-${CURRENT_SHORT_TAG}/CUDF_TAG branch-${NEXT_SHORT_TAG}/" cpp/examples/strings/CMakeLists.txt

# ucx-py version update
sed_runner "s/export UCX_PY_VERSION=.*/export UCX_PY_VERSION='${NEXT_UCX_PY_VERSION}'/g" ci/gpu/build.sh
Expand Down
10 changes: 2 additions & 8 deletions conda/environments/cudf_dev_cuda11.5.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,9 @@ dependencies:
- ipython
- pandoc<=2.0.0
- cudatoolkit=11.5
- cuda-python >=11.5,<11.7.1
- cuda-python>=11.5,<11.7.1
- pip
- flake8=3.8.3
- black=22.3.0
- isort=5.10.1
- mypy=0.971
- types-cachetools
- doxygen=1.8.20
- pydocstyle=6.1.1
- typing_extensions
- pre-commit
- dask>=2022.9.2
Expand All @@ -63,7 +57,7 @@ dependencies:
- myst-nb
- scipy
- dask-cuda=22.12.*
- mimesis<4.1
- mimesis>=4.1.0
- packaging
- protobuf>=3.20.1,<3.21.0a0
- nvtx>=0.2.1
Expand Down
2 changes: 2 additions & 0 deletions conda/recipes/libcudf/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ outputs:
- test -f $PREFIX/include/cudf/detail/transpose.hpp
- test -f $PREFIX/include/cudf/detail/unary.hpp
- test -f $PREFIX/include/cudf/detail/utilities/alignment.hpp
- test -f $PREFIX/include/cudf/detail/utilities/default_stream.hpp
- test -f $PREFIX/include/cudf/detail/utilities/linked_column.hpp
- test -f $PREFIX/include/cudf/detail/utilities/int_fastdiv.h
- test -f $PREFIX/include/cudf/detail/utilities/integer_utils.hpp
Expand Down Expand Up @@ -275,6 +276,7 @@ outputs:
- test -f $PREFIX/include/cudf_test/file_utilities.hpp
- test -f $PREFIX/include/cudf_test/io_metadata_utilities.hpp
- test -f $PREFIX/include/cudf_test/iterator_utilities.hpp
- test -f $PREFIX/include/cudf_test/stream_checking_resource_adapter.hpp
- test -f $PREFIX/include/cudf_test/table_utilities.hpp
- test -f $PREFIX/include/cudf_test/timestamp_utilities.cuh
- test -f $PREFIX/include/cudf_test/type_list_utilities.hpp
Expand Down
49 changes: 27 additions & 22 deletions cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ option(
stream to external libraries."
OFF
)
option(DISABLE_DEPRECATION_WARNING "Disable warnings generated from deprecated declarations." OFF)
option(DISABLE_DEPRECATION_WARNINGS "Disable warnings generated from deprecated declarations." OFF)
# Option to enable line info in CUDA device compilation to allow introspection when profiling /
# memchecking
option(CUDA_ENABLE_LINEINFO
Expand All @@ -79,7 +79,7 @@ message(VERBOSE "CUDF: Build and enable S3 filesystem support for Arrow: ${CUDF_
message(VERBOSE "CUDF: Build with per-thread default stream: ${CUDF_USE_PER_THREAD_DEFAULT_STREAM}")
message(
VERBOSE
"CUDF: Disable warnings generated from deprecated declarations: ${DISABLE_DEPRECATION_WARNING}"
"CUDF: Disable warnings generated from deprecated declarations: ${DISABLE_DEPRECATION_WARNINGS}"
)
message(
VERBOSE
Expand Down Expand Up @@ -124,12 +124,6 @@ rapids_find_package(
)
include(cmake/Modules/ConfigureCUDA.cmake) # set other CUDA compilation flags

# ctest cuda memcheck
find_program(CUDA_SANITIZER compute-sanitizer)
set(MEMORYCHECK_COMMAND ${CUDA_SANITIZER})
set(MEMORYCHECK_TYPE CudaSanitizer)
set(CUDA_SANITIZER_COMMAND_OPTIONS "--tool memcheck")

# ##################################################################################################
# * dependencies ----------------------------------------------------------------------------------

Expand Down Expand Up @@ -617,9 +611,15 @@ target_compile_definitions(
# Disable Jitify log printing. See https://github.com/NVIDIA/jitify/issues/79
target_compile_definitions(cudf PRIVATE "JITIFY_PRINT_LOG=0")

# Instruct jitify to use the kernel JIT cache
if(JITIFY_USE_CACHE)
target_compile_definitions(cudf PUBLIC JITIFY_USE_CACHE "CUDF_VERSION=${PROJECT_VERSION}")
# Instruct src/jit/cache what version of cudf we are building so it can compute a cal-ver cache
# directory. We isolate this definition to the single source so it doesn't effect compiling
# caching for all of libcudf
set_property(
SOURCE src/jit/cache.cpp
APPEND
PROPERTY COMPILE_DEFINITIONS "JITIFY_USE_CACHE" "CUDF_VERSION=${PROJECT_VERSION}"
)
endif()

# Per-thread default stream
Expand Down Expand Up @@ -732,6 +732,13 @@ add_library(cudf::cudftestutil ALIAS cudftestutil)
if(CUDF_BUILD_TESTS)
# include CTest module -- automatically calls enable_testing()
include(CTest)

# ctest cuda memcheck
find_program(CUDA_SANITIZER compute-sanitizer)
set(MEMORYCHECK_COMMAND ${CUDA_SANITIZER})
set(MEMORYCHECK_TYPE CudaSanitizer)
set(CUDA_SANITIZER_COMMAND_OPTIONS "--tool memcheck")

# Always print verbose output when tests fail if run using `make test`.
list(APPEND CMAKE_CTEST_ARGUMENTS "--output-on-failure")
add_subdirectory(tests)
Expand All @@ -742,25 +749,15 @@ endif()

if(CUDF_BUILD_BENCHMARKS)
# Find or install GoogleBench
rapids_cpm_find(
benchmark 1.5.2
GIT_REPOSITORY https://github.com/google/benchmark.git
GIT_TAG v1.5.2
GIT_SHALLOW TRUE
OPTIONS "BENCHMARK_ENABLE_TESTING OFF" "BENCHMARK_ENABLE_INSTALL OFF"
)
include(${rapids-cmake-dir}/cpm/gbench.cmake)
rapids_cpm_gbench()

# Find or install NVBench
include(${rapids-cmake-dir}/cpm/nvbench.cmake)
rapids_cpm_nvbench()
add_subdirectory(benchmarks)
endif()

# build pretty-printer load script
if(Thrust_SOURCE_DIR AND rmm_SOURCE_DIR)
configure_file(scripts/load-pretty-printers.in load-pretty-printers @ONLY)
endif()

# ##################################################################################################
# * install targets -------------------------------------------------------------------------------
rapids_cmake_install_lib_dir(lib_dir)
Expand Down Expand Up @@ -924,3 +921,11 @@ add_custom_target(
DEPENDS CUDF_DOXYGEN
COMMENT "Custom command for building cudf doxygen docs."
)

# ##################################################################################################
# * make gdb helper scripts ------------------------------------------------------------------------

# build pretty-printer load script
if(Thrust_SOURCE_DIR AND rmm_SOURCE_DIR)
configure_file(scripts/load-pretty-printers.in load-pretty-printers @ONLY)
endif()
6 changes: 3 additions & 3 deletions cpp/benchmarks/column/concatenate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ static void BM_concatenate(benchmark::State& state)
CUDF_CHECK_CUDA(0);

for (auto _ : state) {
cuda_event_timer raii(state, true, cudf::default_stream_value);
cuda_event_timer raii(state, true, cudf::get_default_stream());
auto result = cudf::concatenate(column_views);
}

Expand Down Expand Up @@ -91,7 +91,7 @@ static void BM_concatenate_tables(benchmark::State& state)
CUDF_CHECK_CUDA(0);

for (auto _ : state) {
cuda_event_timer raii(state, true, cudf::default_stream_value);
cuda_event_timer raii(state, true, cudf::get_default_stream());
auto result = cudf::concatenate(table_views);
}

Expand Down Expand Up @@ -150,7 +150,7 @@ static void BM_concatenate_strings(benchmark::State& state)
CUDF_CHECK_CUDA(0);

for (auto _ : state) {
cuda_event_timer raii(state, true, cudf::default_stream_value);
cuda_event_timer raii(state, true, cudf::get_default_stream());
auto result = cudf::concatenate(column_views);
}

Expand Down
Loading

0 comments on commit 4ba3124

Please sign in to comment.