Skip to content

Commit 7fed694

Browse files
committed
Update contrib/restricted/abseil-cpp to 20250127.0
commit_hash:cb84f6cd1a663877e7f59ac994d08e04a1e76205
1 parent add9063 commit 7fed694

File tree

172 files changed

+3225
-1591
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

172 files changed

+3225
-1591
lines changed

contrib/restricted/abseil-cpp/.yandex_meta/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,7 @@ def post_install(self):
160160
"absl_spinlock_wait",
161161
"absl_strerror",
162162
"absl_throw_delegate",
163+
"absl_tracing_internal",
163164
],
164165
"absl_debugging_internal": [
165166
"absl_decode_rust_punycode",
@@ -202,6 +203,7 @@ def post_install(self):
202203
"absl_log_internal_message",
203204
"absl_log_internal_nullguard",
204205
"absl_log_internal_proto",
206+
"absl_log_internal_structured_proto",
205207
"absl_log_sink",
206208
"absl_vlog_config_internal",
207209
],

contrib/restricted/abseil-cpp/.yandex_meta/devtools.copyrights.report

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -602,6 +602,8 @@ BELONGS absl/strings/ya.make
602602
Files with this license:
603603
absl/base/internal/poison.cc [1:1]
604604
absl/base/internal/poison.h [1:1]
605+
absl/base/internal/tracing.cc [1:1]
606+
absl/base/internal/tracing.h [1:1]
605607
absl/container/hash_container_defaults.h [1:1]
606608
absl/debugging/internal/bounded_utf8_length_sequence.h [1:1]
607609
absl/debugging/internal/decode_rust_punycode.cc [1:1]
@@ -610,11 +612,13 @@ BELONGS absl/strings/ya.make
610612
absl/debugging/internal/demangle_rust.h [1:1]
611613
absl/debugging/internal/utf8_for_code_point.cc [1:1]
612614
absl/debugging/internal/utf8_for_code_point.h [1:1]
615+
absl/log/internal/structured_proto.cc [2:2]
616+
absl/log/internal/structured_proto.h [1:1]
613617
absl/random/internal/mock_validators.h [1:1]
614618
absl/status/internal/status_matchers.h [1:1]
615619
Belongs difference:
616620
+ absl/strings/ya.make
617-
- absl/base/ya.make absl/container/ya.make absl/debugging/ya.make absl/random/ya.make absl/status/ya.make
621+
- absl/base/ya.make absl/container/ya.make absl/debugging/ya.make absl/log/ya.make absl/random/ya.make absl/status/ya.make
618622

619623
KEEP COPYRIGHT_SERVICE_LABEL 9fd4860fdb6776c0e8deab1d14ff7b1b
620624
BELONGS absl/debugging/ya.make

contrib/restricted/abseil-cpp/.yandex_meta/devtools.licenses.report

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ BELONGS absl/base/ya.make absl/debugging/ya.make absl/hash/ya.make absl/log/ya.m
4141
absl/base/internal/cycleclock_config.h [3:13]
4242
absl/base/internal/poison.cc [3:13]
4343
absl/base/internal/poison.h [3:13]
44+
absl/base/internal/tracing.cc [3:13]
45+
absl/base/internal/tracing.h [3:13]
4446
absl/base/internal/unscaledcycleclock_config.h [3:13]
4547
absl/base/prefetch.h [3:13]
4648
absl/container/hash_container_defaults.h [3:13]
@@ -402,6 +404,8 @@ BELONGS absl/algorithm/ya.make absl/base/ya.make absl/container/ya.make absl/deb
402404
absl/log/internal/proto.h [3:13]
403405
absl/log/internal/strip.h [3:13]
404406
absl/log/internal/structured.h [3:13]
407+
absl/log/internal/structured_proto.cc [4:14]
408+
absl/log/internal/structured_proto.h [3:13]
405409
absl/log/internal/test_actions.h [3:13]
406410
absl/log/internal/test_helpers.h [3:13]
407411
absl/log/internal/test_matchers.h [3:13]

contrib/restricted/abseil-cpp/.yandex_meta/override.nix

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
self: super: with self; rec {
2-
version = "20240722.1";
2+
version = "20250127.0";
33

44
src = fetchFromGitHub {
55
owner = "abseil";
66
repo = "abseil-cpp";
77
rev = version;
8-
hash = "sha256-ir4hG2VIPv3se7JfWqCM/siLqFEFkmhMW/IGCocy6Pc=";
8+
hash = "sha256-Tt4F0VT7koEARWNjL/L2E8jrPZbSsPb/Y32Kn86sb+k=";
99
};
1010

1111
patches = [];

contrib/restricted/abseil-cpp/absl/algorithm/algorithm.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,8 @@ using std::rotate;
5353
// n = (`last` - `first`) comparisons. A linear search over short containers
5454
// may be faster than a binary search, even when the container is sorted.
5555
template <typename InputIterator, typename EqualityComparable>
56-
bool linear_search(InputIterator first, InputIterator last,
57-
const EqualityComparable& value) {
56+
ABSL_INTERNAL_CONSTEXPR_SINCE_CXX20 bool linear_search(
57+
InputIterator first, InputIterator last, const EqualityComparable& value) {
5858
return std::find(first, last, value) != last;
5959
}
6060

contrib/restricted/abseil-cpp/absl/algorithm/container.h

Lines changed: 79 additions & 48 deletions
Large diffs are not rendered by default.

contrib/restricted/abseil-cpp/absl/algorithm/ya.make

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ LICENSE(Apache-2.0)
66

77
LICENSE_TEXTS(.yandex_meta/licenses.list.txt)
88

9-
VERSION(20240722.1)
9+
VERSION(20250127.0)
1010

11-
ORIGINAL_SOURCE(https://github.com/abseil/abseil-cpp/archive/20240722.1.tar.gz)
11+
ORIGINAL_SOURCE(https://github.com/abseil/abseil-cpp/archive/20250127.0.tar.gz)
1212

1313
NO_RUNTIME()
1414

contrib/restricted/abseil-cpp/absl/base/attributes.h

Lines changed: 66 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@
3131
// `__has_attribute()` first. If the check fails, we check if we are on GCC and
3232
// assume the attribute exists on GCC (which is verified on GCC 4.7).
3333

34+
// SKIP_ABSL_INLINE_NAMESPACE_CHECK
35+
3436
#ifndef ABSL_BASE_ATTRIBUTES_H_
3537
#define ABSL_BASE_ATTRIBUTES_H_
3638

@@ -133,12 +135,14 @@
133135
// Tags a function as weak for the purposes of compilation and linking.
134136
// Weak attributes did not work properly in LLVM's Windows backend before
135137
// 9.0.0, so disable them there. See https://bugs.llvm.org/show_bug.cgi?id=37598
136-
// for further information.
138+
// for further information. Weak attributes do not work across DLL boundary.
137139
// The MinGW compiler doesn't complain about the weak attribute until the link
138140
// step, presumably because Windows doesn't use ELF binaries.
139-
#if (ABSL_HAVE_ATTRIBUTE(weak) || \
140-
(defined(__GNUC__) && !defined(__clang__))) && \
141-
(!defined(_WIN32) || (defined(__clang__) && __clang_major__ >= 9)) && \
141+
#if (ABSL_HAVE_ATTRIBUTE(weak) || \
142+
(defined(__GNUC__) && !defined(__clang__))) && \
143+
(!defined(_WIN32) || \
144+
(defined(__clang__) && __clang_major__ >= 9 && \
145+
!defined(ABSL_BUILD_DLL) && !defined(ABSL_CONSUME_DLL))) && \
142146
!defined(__MINGW32__)
143147
#undef ABSL_ATTRIBUTE_WEAK
144148
#define ABSL_ATTRIBUTE_WEAK __attribute__((weak))
@@ -827,30 +831,76 @@
827831
#define ABSL_ATTRIBUTE_LIFETIME_BOUND
828832
#endif
829833

830-
// ABSL_INTERNAL_ATTRIBUTE_VIEW indicates that a type acts like a view i.e. a
831-
// raw (non-owning) pointer. This enables diagnoses similar to those enabled by
832-
// ABSL_ATTRIBUTE_LIFETIME_BOUND.
834+
// Internal attribute; name and documentation TBD.
835+
//
836+
// See the upstream documentation:
837+
// https://clang.llvm.org/docs/AttributeReference.html#lifetime_capture_by
838+
#if ABSL_HAVE_CPP_ATTRIBUTE(clang::lifetime_capture_by)
839+
#define ABSL_INTERNAL_ATTRIBUTE_CAPTURED_BY(Owner) \
840+
[[clang::lifetime_capture_by(Owner)]]
841+
#else
842+
#define ABSL_INTERNAL_ATTRIBUTE_CAPTURED_BY(Owner)
843+
#endif
844+
845+
// ABSL_ATTRIBUTE_VIEW indicates that a type is solely a "view" of data that it
846+
// points to, similarly to a span, string_view, or other non-owning reference
847+
// type.
848+
// This enables diagnosing certain lifetime issues similar to those enabled by
849+
// ABSL_ATTRIBUTE_LIFETIME_BOUND, such as:
850+
//
851+
// struct ABSL_ATTRIBUTE_VIEW StringView {
852+
// template<class R>
853+
// StringView(const R&);
854+
// };
855+
//
856+
// StringView f(std::string s) {
857+
// return s; // warning: address of stack memory returned
858+
// }
859+
//
860+
// We disable this on Clang versions < 13 because of the following
861+
// false-positive:
862+
//
863+
// absl::string_view f(absl::optional<absl::string_view> sv) { return *sv; }
833864
//
834865
// See the following links for details:
835866
// https://reviews.llvm.org/D64448
836867
// https://lists.llvm.org/pipermail/cfe-dev/2018-November/060355.html
837-
#if ABSL_HAVE_CPP_ATTRIBUTE(gsl::Pointer)
838-
#define ABSL_INTERNAL_ATTRIBUTE_VIEW [[gsl::Pointer]]
868+
#if ABSL_HAVE_CPP_ATTRIBUTE(gsl::Pointer) && \
869+
(!defined(__clang_major__) || __clang_major__ >= 13)
870+
#define ABSL_ATTRIBUTE_VIEW [[gsl::Pointer]]
839871
#else
840-
#define ABSL_INTERNAL_ATTRIBUTE_VIEW
872+
#define ABSL_ATTRIBUTE_VIEW
841873
#endif
842874

843-
// ABSL_INTERNAL_ATTRIBUTE_OWNER indicates that a type acts like a smart
844-
// (owning) pointer. This enables diagnoses similar to those enabled by
845-
// ABSL_ATTRIBUTE_LIFETIME_BOUND.
875+
// ABSL_ATTRIBUTE_OWNER indicates that a type is a container, smart pointer, or
876+
// similar class that owns all the data that it points to.
877+
// This enables diagnosing certain lifetime issues similar to those enabled by
878+
// ABSL_ATTRIBUTE_LIFETIME_BOUND, such as:
879+
//
880+
// struct ABSL_ATTRIBUTE_VIEW StringView {
881+
// template<class R>
882+
// StringView(const R&);
883+
// };
884+
//
885+
// struct ABSL_ATTRIBUTE_OWNER String {};
886+
//
887+
// StringView f(String s) {
888+
// return s; // warning: address of stack memory returned
889+
// }
890+
//
891+
// We disable this on Clang versions < 13 because of the following
892+
// false-positive:
893+
//
894+
// absl::string_view f(absl::optional<absl::string_view> sv) { return *sv; }
846895
//
847896
// See the following links for details:
848897
// https://reviews.llvm.org/D64448
849898
// https://lists.llvm.org/pipermail/cfe-dev/2018-November/060355.html
850-
#if ABSL_HAVE_CPP_ATTRIBUTE(gsl::Owner)
851-
#define ABSL_INTERNAL_ATTRIBUTE_OWNER [[gsl::Owner]]
899+
#if ABSL_HAVE_CPP_ATTRIBUTE(gsl::Owner) && \
900+
(!defined(__clang_major__) || __clang_major__ >= 13)
901+
#define ABSL_ATTRIBUTE_OWNER [[gsl::Owner]]
852902
#else
853-
#define ABSL_INTERNAL_ATTRIBUTE_OWNER
903+
#define ABSL_ATTRIBUTE_OWNER
854904
#endif
855905

856906
// ABSL_ATTRIBUTE_TRIVIAL_ABI

contrib/restricted/abseil-cpp/absl/base/call_once.h

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@
3131
#include <type_traits>
3232
#include <utility>
3333

34+
#include "absl/base/attributes.h"
35+
#include "absl/base/config.h"
3436
#include "absl/base/internal/invoke.h"
3537
#include "absl/base/internal/low_level_scheduling.h"
3638
#include "absl/base/internal/raw_logging.h"
@@ -147,10 +149,10 @@ enum {
147149
};
148150

149151
template <typename Callable, typename... Args>
150-
ABSL_ATTRIBUTE_NOINLINE void CallOnceImpl(
151-
absl::Nonnull<std::atomic<uint32_t>*> control,
152-
base_internal::SchedulingMode scheduling_mode, Callable&& fn,
153-
Args&&... args) {
152+
void
153+
CallOnceImpl(absl::Nonnull<std::atomic<uint32_t>*> control,
154+
base_internal::SchedulingMode scheduling_mode, Callable&& fn,
155+
Args&&... args) {
154156
#ifndef NDEBUG
155157
{
156158
uint32_t old_control = control->load(std::memory_order_relaxed);
@@ -209,7 +211,8 @@ void LowLevelCallOnce(absl::Nonnull<absl::once_flag*> flag, Callable&& fn,
209211
} // namespace base_internal
210212

211213
template <typename Callable, typename... Args>
212-
void call_once(absl::once_flag& flag, Callable&& fn, Args&&... args) {
214+
void
215+
call_once(absl::once_flag& flag, Callable&& fn, Args&&... args) {
213216
std::atomic<uint32_t>* once = base_internal::ControlWord(&flag);
214217
uint32_t s = once->load(std::memory_order_acquire);
215218
if (ABSL_PREDICT_FALSE(s != base_internal::kOnceDone)) {

contrib/restricted/abseil-cpp/absl/base/config.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -117,8 +117,8 @@
117117
//
118118
// LTS releases can be obtained from
119119
// https://github.com/abseil/abseil-cpp/releases.
120-
#define ABSL_LTS_RELEASE_VERSION 20240722
121-
#define ABSL_LTS_RELEASE_PATCH_LEVEL 1
120+
#define ABSL_LTS_RELEASE_VERSION 20250127
121+
#define ABSL_LTS_RELEASE_PATCH_LEVEL 0
122122

123123
// Helper macro to convert a CPP variable to a string literal.
124124
#define ABSL_INTERNAL_DO_TOKEN_STR(x) #x
@@ -380,7 +380,7 @@ static_assert(ABSL_INTERNAL_INLINE_NAMESPACE_STR[0] != 'h' ||
380380
defined(__asmjs__) || defined(__EMSCRIPTEN__) || defined(__Fuchsia__) || \
381381
defined(__sun) || defined(__myriad2__) || defined(__HAIKU__) || \
382382
defined(__OpenBSD__) || defined(__NetBSD__) || defined(__QNX__) || \
383-
defined(__VXWORKS__) || defined(__hexagon__)
383+
defined(__VXWORKS__) || defined(__hexagon__) || defined(__XTENSA__)
384384
#define ABSL_HAVE_MMAP 1
385385
#endif
386386

@@ -926,7 +926,7 @@ static_assert(ABSL_INTERNAL_INLINE_NAMESPACE_STR[0] != 'h' ||
926926
// https://llvm.org/docs/CompileCudaWithLLVM.html#detecting-clang-vs-nvcc-from-code
927927
#ifdef ABSL_INTERNAL_HAVE_ARM_NEON
928928
#error ABSL_INTERNAL_HAVE_ARM_NEON cannot be directly set
929-
#elif defined(__ARM_NEON) && !defined(__CUDA_ARCH__)
929+
#elif defined(__ARM_NEON) && !(defined(__NVCC__) && defined(__CUDACC__))
930930
#define ABSL_INTERNAL_HAVE_ARM_NEON 1
931931
#endif
932932

0 commit comments

Comments
 (0)