Home
last modified time | relevance | path

Searched refs:nth_element (Results 1 – 25 of 43) sorted by relevance

12

/llvm-project/libcxx/test/std/algorithms/alg.sorting/alg.nth.element/
H A Dranges_nth_element.pass.cpp42 std::ranges::nth_element(first, nth, last, comp);
55 std::ranges::nth_element(range, nth, comp);
104 std::same_as<Iter> decltype(auto) last = std::ranges::nth_element(b, nth, e);
119 std::same_as<Iter> decltype(auto) last = std::ranges::nth_element(range, nth);
195 auto last = std::ranges::nth_element(in.begin(), in.begin() + 1, in.end(), comp); in test()
202 auto last = std::ranges::nth_element(in, in.begin() + 1, comp); in test()
218 auto last = std::ranges::nth_element(in.begin(), in.begin() + 1, in.end(), {}, &A::a); in test()
225 auto last = std::ranges::nth_element(in, in.begin() + 1, {}, &A::a); in test()
246 …auto last = std::ranges::nth_element(in.begin(), in.begin() + 1, in.end(), &S::comparator, &S::pro… in test()
253 auto last = std::ranges::nth_element(in, in.begin() + 1, &S::comparator, &S::projection); in test()
[all …]
H A Dnth_element.pass.cpp30 std::nth_element(Iter(work), Iter(work+m), Iter(work+n)); in test()
46 std::nth_element(Iter(input), Iter(input+4), Iter(input+7)); in test()
53 std::nth_element(Iter(input), Iter(input + 6), Iter(input + 8)); in test()
60 std::nth_element(Iter(input), Iter(input + 1), Iter(input + 8)); in test()
H A Dnth_element_comp.pass.cpp31 std::nth_element(Iter(work), Iter(work+m), Iter(work+n), std::greater<T>()); in test()
47 std::nth_element(Iter(input), Iter(input+4), Iter(input+7), std::greater<T>()); in test()
54 std::nth_element(Iter(input), Iter(input + 6), Iter(input + 8), std::greater<T>()); in test()
61 std::nth_element(Iter(input), Iter(input + 1), Iter(input + 8), std::greater<T>()); in test()
/llvm-project/libcxx/test/libcxx/algorithms/
H A Dnth_element_stability.pass.cpp49 std::nth_element(v.begin(), v.begin() + kSize / 2, v.end()); in test_randomization()
68 std::nth_element(v.begin(), v.begin() + kSize / 2, v.end()); in test_same()
69 std::nth_element(snapshot_v.begin(), snapshot_v.begin() + kSize / 2, snapshot_v.end()); in test_same()
70 …std::nth_element(snapshot_custom_v.begin(), snapshot_custom_v.begin() + kSize / 2, snapshot_custom… in test_same()
89 std::nth_element(v.begin(), v.begin() + 5, v.end()); in test_constexpr()
H A Drobust_against_cpp20_hostile_iterators.compile.pass.cpp165 (void) std::nth_element(it, it, it); in test()
166 (void) std::nth_element(it, it, it, pred); in test()
H A Dranges_robust_against_copying_comparators.pass.cpp184 (void)std::ranges::nth_element(first, mid, last, Less(&copies)); assert(copies == 0); in all_the_algorithms()
185 (void)std::ranges::nth_element(a, mid, Less(&copies)); assert(copies == 0); in all_the_algorithms()
H A Dranges_robust_against_copying_projections.pass.cpp181 (void)std::ranges::nth_element(first, mid, last, Less(), Proj(&copies)); assert(copies == 0); in all_the_algorithms()
182 (void)std::ranges::nth_element(a, mid, Less(), Proj(&copies)); assert(copies == 0); in all_the_algorithms()
/llvm-project/libcxx/test/libcxx/algorithms/alg.sorting/assert.sort.invalid_comparator/
H A Dassert.sort.invalid_comparator.oob.pass.cpp55 std::nth_element(copy.begin(), copy.begin(), copy.end(), fixture.checked_predicate()), in check_oob_nth_element_read()
62 std::ranges::nth_element(copy, copy.begin(), fixture.checked_predicate()), in check_oob_nth_element_read()
H A Dassert.sort.invalid_comparator.pass.cpp119 …TEST_LIBCPP_ASSERT_FAILURE(std::nth_element(copy.begin(), copy.begin(), copy.end(), fixture.checke… in check_oob_nth_element_read()
125 …TEST_LIBCPP_ASSERT_FAILURE(std::ranges::nth_element(copy, copy.begin(), fixture.checked_predicate(… in check_oob_nth_element_read()
/llvm-project/clang/test/Analysis/
H A Dptr-sort.cpp
/llvm-project/libcxx/include/__algorithm/
H A Dnth_element.h247 nth_element(_RandomAccessIterator __first, _RandomAccessIterator __nth, _RandomAccessIterator __las… in nth_element() function
253 nth_element(_RandomAccessIterator __first, _RandomAccessIterator __nth, _RandomAccessIterator __las… in nth_element() function
254 std::nth_element(std::move(__first), std::move(__nth), std::move(__last), __less<>()); in nth_element()
H A Dranges_nth_element.h14 #include <__algorithm/nth_element.h>
70 inline constexpr auto nth_element = __nth_element{};
/llvm-project/pstl/test/std/algorithms/alg.nonmodifying/
H A Dnth_element.pass.cpp103 std::nth_element(first1, mid1, last1, comp); in operator ()()
104 std::nth_element(exec, first2, mid2, last2, comp); in operator ()()
154 invoke_if(exec, [&]() { nth_element(exec, iter, iter, iter, non_const(std::less<T>())); }); in operator ()()
/llvm-project/clang/test/SemaTemplate/
H A Dtemp_arg_nontype_cxx1z.cpp309 template<size_t n, class List> struct nth_element;
310 template<size_t n, class List> constexpr auto nth_element_v = nth_element<n, List>::value;
313 struct nth_element<n, value_list<v0, vs...>> struct
315 static constexpr auto value = nth_element<n - 1, value_list<vs...>>::value; argument
318 struct nth_element<0, value_list<v0, vs...>> struct
320 valueAuto::Variadic::nth_element global() argument
/llvm-project/libcxx/test/std/algorithms/
H A Dranges_robust_against_nonbool.compile.pass.cpp269 // nth_element in f()
271 (void)std::ranges::nth_element(it, it, it, pred2); in f()
272 (void)std::ranges::nth_element(in, it, pred2); in f()
273 (void)std::ranges::nth_element(it, it, it, pred2, projection); in f()
274 (void)std::ranges::nth_element(in, it, pred2, projection); in f()
H A Drobust_re_difference_type.compile.pass.cpp196 (void)std::nth_element(first, mid, last); in all_the_algorithms()
197 (void)std::nth_element(first, mid, last, std::less<void*>()); in all_the_algorithms()
/llvm-project/libcxx/test/libcxx/fuzzing/
H A Dnth_element.pass.cpp24 std::nth_element(working.begin(), partition_iter, working.end()); in LLVMFuzzerTestOneInput()
/llvm-project/llvm/tools/llvm-xray/
H A Dxray-account.cpp284 std::nth_element(Timings.begin(), Timings.begin() + MedianOff, Timings.end()); in getStats()
288 std::nth_element(Timings.begin(), Timings.begin() + (uint64_t)Pct90Off, in getStats()
293 std::nth_element(Timings.begin(), Timings.begin() + (uint64_t)Pct99Off, in getStats()
H A Dxray-graph.cpp281 std::nth_element(begin, begin + MedianOff, end); in getStats()
284 std::nth_element(begin, begin + Pct90Off, end); in getStats()
287 std::nth_element(begin, begin + Pct99Off, end); in getStats()
/llvm-project/pstl/
H A DREADME.md23 …orithms do not allow efficient SIMD execution: `includes`, `inplace_merge`, `merge`, `nth_element`,
/llvm-project/libc/benchmarks/automemcpy/lib/
H A DResultAnalyzer.cpp
/llvm-project/third-party/benchmark/src/
H A Dstatistics.cc43 std::nth_element(copy.begin(), center, copy.end()); in StatisticsMedian()
/llvm-project/libcxx/docs/DesignDocs/
H A DUnspecifiedBehaviorRandomization.rst83 * ``std::nth_element``, there is no guarantee on the order from both sides of the
/llvm-project/libcxx/modules/std/
H A Dalgorithm.inc402 using std::nth_element;
405 using std::ranges::nth_element;
/llvm-project/llvm/lib/Support/
H A DBalancedPartitioning.cpp308 std::nth_element(Nodes.begin(), NodesMid, Nodes.end(), [](auto &L, auto &R) { in split()

12