Skip to content

Commit

Permalink
Merge branch 'branch-0.20' into refactor-combine
Browse files Browse the repository at this point in the history
  • Loading branch information
davidwendt committed Apr 15, 2021
2 parents 10188c5 + 8a504d1 commit 0615000
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 12 deletions.
2 changes: 1 addition & 1 deletion cpp/benchmarks/string/json_benchmark.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ static void BM_case(benchmark::State& state, QueryArg&&... query_arg)
std::string json_path(query_arg...);

for (auto _ : state) {
cuda_event_timer raii(state, true, 0);
cuda_event_timer raii(state, true);
auto result = cudf::strings::get_json_object(scv, json_path);
cudaStreamSynchronize(0);
}
Expand Down
2 changes: 1 addition & 1 deletion cpp/benchmarks/text/ngrams_benchmark.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ static void BM_ngrams(benchmark::State& state, ngrams_type nt)
cudf::strings_column_view input(table->view().column(0));

for (auto _ : state) {
cuda_event_timer raii(state, true, 0);
cuda_event_timer raii(state, true);
switch (nt) {
case ngrams_type::tokens: nvtext::generate_ngrams(input); break;
case ngrams_type::characters: nvtext::generate_character_ngrams(input); break;
Expand Down
2 changes: 1 addition & 1 deletion cpp/benchmarks/text/replace_benchmark.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ static void BM_replace(benchmark::State& state)
cudf::test::strings_column_wrapper replacements({"1", "2", "7", "0"});

for (auto _ : state) {
cuda_event_timer raii(state, true, 0);
cuda_event_timer raii(state, true);
nvtext::replace_tokens(
view, cudf::strings_column_view(targets), cudf::strings_column_view(replacements));
}
Expand Down
2 changes: 1 addition & 1 deletion cpp/src/strings/json/json_path.cu
Original file line number Diff line number Diff line change
Expand Up @@ -945,7 +945,7 @@ std::unique_ptr<cudf::column> get_json_object(cudf::strings_column_view const& c
rmm::mr::device_memory_resource* mr)
{
CUDF_FUNC_RANGE();
return detail::get_json_object(col, json_path, 0, mr);
return detail::get_json_object(col, json_path, rmm::cuda_stream_default, mr);
}

} // namespace strings
Expand Down
10 changes: 4 additions & 6 deletions cpp/tests/transform/row_bit_count_test.cu
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@

#include <cudf/column/column.hpp>
#include <cudf/column/column_view.hpp>
#include <cudf/detail/copy.hpp>
#include <cudf/strings/detail/utilities.hpp>
#include <cudf/transform.hpp>
#include <cudf/types.hpp>
#include <cudf_test/base_fixture.hpp>
Expand Down Expand Up @@ -47,7 +45,7 @@ TYPED_TEST(RowBitCountTyped, SimpleTypes)
// expect size of the type per row
auto expected = make_fixed_width_column(data_type{type_id::INT32}, 16);
cudf::mutable_column_view mcv(*expected);
thrust::fill(rmm::exec_policy(0),
thrust::fill(rmm::exec_policy(rmm::cuda_stream_default),
mcv.begin<size_type>(),
mcv.end<size_type>(),
sizeof(device_storage_type_t<T>) * CHAR_BIT);
Expand All @@ -70,7 +68,7 @@ TYPED_TEST(RowBitCountTyped, SimpleTypesWithNulls)
// expect size of the type + 1 bit per row
auto expected = make_fixed_width_column(data_type{type_id::INT32}, 16);
cudf::mutable_column_view mcv(*expected);
thrust::fill(rmm::exec_policy(0),
thrust::fill(rmm::exec_policy(rmm::cuda_stream_default),
mcv.begin<size_type>(),
mcv.end<size_type>(),
(sizeof(device_storage_type_t<T>) * CHAR_BIT) + 1);
Expand Down Expand Up @@ -490,7 +488,7 @@ TEST_F(RowBitCount, Table)
auto expected = cudf::make_fixed_width_column(data_type{type_id::INT32}, t.num_rows());
cudf::mutable_column_view mcv(*expected);
thrust::transform(
rmm::exec_policy(0),
rmm::exec_policy(rmm::cuda_stream_default),
thrust::make_counting_iterator(0),
thrust::make_counting_iterator(0) + t.num_rows(),
mcv.begin<size_type>(),
Expand Down Expand Up @@ -586,7 +584,7 @@ TEST_F(RowBitCount, EmptyTable)
}

{
auto strings = cudf::strings::detail::make_empty_strings_column(0);
auto strings = cudf::make_empty_column(data_type{type_id::STRING});
auto ints = cudf::make_empty_column(data_type{type_id::INT32});
cudf::table_view empty({*strings, *ints});

Expand Down
4 changes: 2 additions & 2 deletions java/src/main/native/src/row_conversion.cu
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2020, NVIDIA CORPORATION.
* Copyright (c) 2020-2021, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -404,7 +404,7 @@ static std::unique_ptr<cudf::column> fixed_width_convert_to_rows(
input_data->data(), input_nm->data(), data->mutable_view().data<int8_t>());

return cudf::make_lists_column(num_rows, std::move(offsets), std::move(data), 0,
rmm::device_buffer{0, 0, mr}, stream, mr);
rmm::device_buffer{0, rmm::cuda_stream_default, mr}, stream, mr);
}

static cudf::data_type get_data_type(const cudf::column_view &v) {
Expand Down

0 comments on commit 0615000

Please sign in to comment.