Export of internal Abseil changes

--
373171b46238585c818cec37af26959f5412f813 by Abseil Team <absl-team@google.com>:

Build with -Wl,-no-undefined.

PiperOrigin-RevId: 381276748

--
da32624792d2948fe83d0ce58794d505799ab5d0 by Benjamin Barenblat <bbaren@google.com>:

s/round/rint/ in exponential_biased

`rint` differs from `round` in that it uses the current FPU rounding
mode. It’s thus potentially faster, since it doesn’t have to save and
restore FPU state. It also is more reflective of developer intent –
most developers expect all FPU operations to use the current rounding
mode, and having exponential_biased follow that rule seems ideal.

PiperOrigin-RevId: 381268264

--
8f860253a4283d2cc8230fe98d7cdf7bcb3e05f1 by Abseil Team <absl-team@google.com>:

Internal change.

PiperOrigin-RevId: 381264180
GitOrigin-RevId: 373171b46238585c818cec37af26959f5412f813
Change-Id: Iefe60b15c80318a7707e0c32159ac004bfa26d72
pull/986/head
Abseil Team 3 years ago committed by rogeeff
parent a2419e63b8
commit 9a7e447c51
  1. 5
      absl/base/BUILD.bazel
  2. 2
      absl/base/internal/exponential_biased.cc
  3. 2
      absl/base/internal/exponential_biased.h
  4. 1
      absl/container/BUILD.bazel
  5. 10
      absl/flags/BUILD.bazel
  6. 1
      absl/hash/BUILD.bazel
  7. 1
      absl/numeric/BUILD.bazel
  8. 2
      absl/status/BUILD.bazel
  9. 7
      absl/strings/BUILD.bazel
  10. 2
      absl/synchronization/BUILD.bazel
  11. 1
      absl/time/BUILD.bazel
  12. 2
      absl/time/internal/cctz/BUILD.bazel

@ -56,7 +56,6 @@ cc_library(
srcs = ["log_severity.cc"],
hdrs = ["log_severity.h"],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
deps = [
":config",
@ -160,7 +159,6 @@ cc_library(
"internal/low_level_alloc.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = select({
"//absl:msvc_compiler": [],
"//absl:clang-cl_compiler": [],
@ -222,7 +220,6 @@ cc_library(
"internal/unscaledcycleclock.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = select({
"//absl:msvc_compiler": [
"-DEFAULTLIB:advapi32.lib",
@ -293,7 +290,6 @@ cc_library(
srcs = ["internal/throw_delegate.cc"],
hdrs = ["internal/throw_delegate.h"],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
visibility = [
"//absl:__subpackages__",
@ -713,7 +709,6 @@ cc_library(
srcs = ["internal/strerror.cc"],
hdrs = ["internal/strerror.h"],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
visibility = [
"//absl:__subpackages__",

@ -64,7 +64,7 @@ int64_t ExponentialBiased::GetSkipCount(int64_t mean) {
// Assume huge values are bias neutral, retain bias for next call.
return std::numeric_limits<int64_t>::max() / 2;
}
double value = std::round(interval);
double value = std::rint(interval);
bias_ = interval - value;
return value;
}

@ -66,7 +66,7 @@ namespace base_internal {
// Adjusting with rounding bias is relatively trivial:
//
// double value = bias_ + exponential_distribution(mean)();
// double rounded_value = std::round(value);
// double rounded_value = std::rint(value);
// bias_ = value - rounded_value;
// return rounded_value;
//

@ -505,7 +505,6 @@ cc_library(
],
hdrs = ["internal/hashtablez_sampler.h"],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
deps = [
":have_sse",

@ -51,7 +51,6 @@ cc_library(
"internal/program_name.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
visibility = [
"//absl/flags:__pkg__",
@ -75,7 +74,6 @@ cc_library(
"usage_config.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
deps = [
":path_util",
@ -96,7 +94,6 @@ cc_library(
"marshalling.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
deps = [
"//absl/base:config",
@ -116,7 +113,6 @@ cc_library(
"internal/commandlineflag.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
deps = [
"//absl/base:config",
@ -133,7 +129,6 @@ cc_library(
"commandlineflag.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
deps = [
":commandlineflag_internal",
@ -175,7 +170,6 @@ cc_library(
"reflection.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
deps = [
":commandlineflag",
@ -200,7 +194,6 @@ cc_library(
"internal/sequence_lock.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
visibility = ["//absl/base:__subpackages__"],
deps = [
@ -251,7 +244,6 @@ cc_library(
"internal/usage.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
visibility = [
"//absl/flags:__pkg__",
@ -281,7 +273,6 @@ cc_library(
"usage.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
deps = [
":usage_internal",
@ -300,7 +291,6 @@ cc_library(
"parse.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
deps = [
":commandlineflag",

@ -34,7 +34,6 @@ cc_library(
],
hdrs = ["hash.h"],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
deps = [
":city",

@ -62,7 +62,6 @@ cc_library(
],
hdrs = ["int128.h"],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
deps = [
":bits",

@ -40,7 +40,6 @@ cc_library(
"status_payload_printer.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
deps = [
"//absl/base:atomic_hook",
"//absl/base:config",
@ -77,7 +76,6 @@ cc_library(
"statusor.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
deps = [
":status",
"//absl/base:core_headers",

@ -66,7 +66,6 @@ cc_library(
"substitute.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
deps = [
":internal",
"//absl/base",
@ -97,7 +96,6 @@ cc_library(
"internal/utf8.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
deps = [
"//absl/base:config",
"//absl/base:core_headers",
@ -280,7 +278,6 @@ cc_library(
"internal/cord_rep_ring_reader.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
visibility = [
"//visibility:private",
],
@ -330,7 +327,6 @@ cc_library(
"cord.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
deps = [
":cord_internal",
":cordz_functions",
@ -359,7 +355,6 @@ cc_library(
srcs = ["internal/cordz_handle.cc"],
hdrs = ["internal/cordz_handle.h"],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
visibility = [
"//absl:__subpackages__",
],
@ -376,7 +371,6 @@ cc_library(
srcs = ["internal/cordz_info.cc"],
hdrs = ["internal/cordz_info.h"],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
visibility = [
"//absl:__subpackages__",
],
@ -1001,7 +995,6 @@ cc_library(
"internal/str_format/parser.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
visibility = ["//visibility:private"],
deps = [
":strings",

@ -36,7 +36,6 @@ cc_library(
"internal/graphcycles.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
visibility = [
"//absl:__subpackages__",
@ -88,7 +87,6 @@ cc_library(
"notification.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = select({
"//absl:msvc_compiler": [],
"//absl:clang-cl_compiler": [],

@ -43,7 +43,6 @@ cc_library(
"time.h",
],
copts = ABSL_DEFAULT_COPTS,
features = ["-no_undefined"],
linkopts = ABSL_DEFAULT_LINKOPTS,
deps = [
"//absl/base",

@ -45,7 +45,6 @@ cc_library(
hdrs = [
"include/cctz/civil_time.h",
],
features = ["-no_undefined"],
textual_hdrs = ["include/cctz/civil_time_detail.h"],
visibility = ["//visibility:public"],
deps = ["//absl/base:config"],
@ -75,7 +74,6 @@ cc_library(
"include/cctz/time_zone.h",
"include/cctz/zone_info_source.h",
],
features = ["-no_undefined"],
linkopts = select({
":osx": [
"-framework Foundation",

Loading…
Cancel
Save