@@ -80,10 +80,10 @@ void seq_radix_sort_(slice<InIterator, InIterator> In,
8080 }
8181
8282 if (swapped && inplace) {
83- uninitialized_relocate_n (In .begin (), Out.begin (), In.size ());
83+ parlay::uninitialized_relocate (Out .begin (), Out.end (), In.begin ());
8484 }
8585 else if (!swapped && !inplace) {
86- uninitialized_relocate_n (Out .begin (), In.begin (), Out.size ());
86+ parlay::uninitialized_relocate (In .begin (), In.end (), Out.begin ());
8787 }
8888}
8989
@@ -105,10 +105,10 @@ void seq_radix_sort(slice<InIterator, InIterator> In,
105105 size_t n = In.size ();
106106 if (odd) {
107107 // We could just use assign_dispatch(Tmp[i], In[i]) for each i, but we
108- // can optimize better by calling destructive_move_slice , since this
108+ // can optimize better by calling uninitialized_relocate , since this
109109 // has the ability to memcpy multiple elements at once
110110 if constexpr (std::is_same_v<assignment_tag, uninitialized_relocate_tag>) {
111- uninitialized_relocate_n (Tmp .begin (), In.begin (), Tmp.size ());
111+ parlay::uninitialized_relocate (In .begin (), In.end (), Tmp.begin ());
112112 }
113113 else {
114114 for (size_t i = 0 ; i < n; i++)
@@ -117,7 +117,7 @@ void seq_radix_sort(slice<InIterator, InIterator> In,
117117 seq_radix_sort_ (Tmp, Out, g, key_bits, false );
118118 } else {
119119 if constexpr (std::is_same_v<assignment_tag, uninitialized_relocate_tag>) {
120- uninitialized_relocate_n (Out .begin (), In.begin (), Out.size ());
120+ parlay::uninitialized_relocate (In .begin (), In.end (), Out.begin ());
121121 }
122122 else {
123123 for (size_t i = 0 ; i < n; i++)
@@ -219,7 +219,7 @@ sequence<size_t> integer_sort_r(slice<InIterator, InIterator> In,
219219 // uninitialized_relocate_n, which can memcpy multiple elements at a time
220220 // to save on performing every copy individually.
221221 if constexpr (std::is_same_v<assignment_tag, uninitialized_relocate_tag>) {
222- uninitialized_relocate_n (Out .begin (), In.begin (), Out.size ());
222+ parlay::uninitialized_relocate (In .begin (), In.end (), Out.begin ());
223223 }
224224 else {
225225 parallel_for (0 , In.size (), [&](size_t i) {
@@ -248,7 +248,7 @@ sequence<size_t> integer_sort_r(slice<InIterator, InIterator> In,
248248
249249 if constexpr (inplace_tag::value == true ) {
250250 if (!one_bucket) {
251- uninitialized_relocate_n (In .begin (), Out.begin (), In.size ());
251+ parlay::uninitialized_relocate (Out .begin (), Out.end (), In.begin ());
252252 }
253253 }
254254
0 commit comments