Commit graph

14 commits

Author SHA1 Message Date
Abseil Team
cbfd0f0fe5 Export of internal Abseil changes
--
6a60bc6c79a3069f49986c2567dd51d2792f8ec1 by Abseil Team <absl-team@google.com>:

Internal cleanup

PiperOrigin-RevId: 311210039

--
a1049de1dd9071efa3a3dda1c3f25ab578b23e27 by Laramie Leavitt <lar@google.com>:

Internal change

PiperOrigin-RevId: 311188627

--
c2ccddd1cd89ef9d79c35bbe9e1813164db27031 by Matt Kulukundis <kfm@google.com>:

Migrate time parsing/formatting to string_view.

- make a copy before handing to cctz but handle local cases without

PiperOrigin-RevId: 311009254

--
d91d0cd68f3672a727ff76ee43f2da5226673d60 by Gennadiy Rozental <rogeeff@google.com>:

Eliminate public method absl::Flag<T>::IsSpecfiedOnCommandLine. This interface was never intended to be supported. Prefer to react to the current value of flag.

PiperOrigin-RevId: 310991916

--
8ad41e7ec24f43598ed232545314117802e7895c by Gennadiy Rozental <rogeeff@google.com>:

Internal change

PiperOrigin-RevId: 310757743

--
f091f77a13ce9481218cb356f8b4ceb49c1530f9 by Jorg Brown <jorg@google.com>:

Change #include of <iostream> to <iosfwd> from absl/strings/cord.h

PiperOrigin-RevId: 310657413

--
39419418af6be4ac9b9204ebe2c7a92a6c3a0bc9 by Derek Mauro <dmauro@google.com>:

Internal change

PiperOrigin-RevId: 310615554
GitOrigin-RevId: 6a60bc6c79a3069f49986c2567dd51d2792f8ec1
Change-Id: I57dd35424269d67740272c4f88b2de54d8022cb2
2020-05-12 21:04:49 -04:00
Abseil Team
d85783fd0b Export of internal Abseil changes
--
f34cd235a12ad0ee1fea3a1ee5a427272dc2b285 by Abseil Team <absl-team@google.com>:

Migrates uses of deprecated map types to recommended types.

PiperOrigin-RevId: 309945156

--
e3410a47ad32c0775b6911610bc47b22938decad by Matthew Brown <matthewbr@google.com>:

Internal Change

PiperOrigin-RevId: 309856021

--
a58cfa25e0bb59e7fa9647ac1aae65eaccff0086 by Greg Falcon <gfalcon@google.com>:

Internal change.

PiperOrigin-RevId: 309804612

--
cdc5ec310035fbe25f496bda283fe655d94d7769 by Mark Barolak <mbar@google.com>:

Standardize the header comments for friend functions in cord.h

PiperOrigin-RevId: 309779073

--
fe61602701be795e54477b0fdbf5ffc1df12a6b7 by Samuel Benzaquen <sbenza@google.com>:

Implement %f natively for any input.
It evaluates the input at runtime and allocates stack space accordingly.

This removes a potential fallback into snprintf, improves performance, and removes all memory allocations in this formatting path.

PiperOrigin-RevId: 309752501

--
79e2a24f3f959e8b06ddf1d440bbabbd5f89b5b7 by Greg Falcon <gfalcon@google.com>:

Add a Cord::swap() method.  Many other Abseil types already provide this, but it was missing here.

We already provided a two-argument free function form of `swap()`, but that API is better suited for generic code.  The swap member function is a better API when the types are known.

PiperOrigin-RevId: 309751740

--
85cdf60024f153fb4fcb7fe68ed2b14b9faf119d by Derek Mauro <dmauro@google.com>:

Cleanup uses of "linker initialized" SpinLocks

PiperOrigin-RevId: 309581867

--
9e5443bfcec4b94056b13c75326576e987ab88fb by Matt Kulukundis <kfm@google.com>:

Clarify intended mixing properties of `absl::Hash`

PiperOrigin-RevId: 309520174

--
a0630f0827b67f217aaeae68a448fe4c1101e17d by Greg Falcon <gfalcon@google.com>:

Comment out a test in Emscripten to sidestep `long double` issues.

PiperOrigin-RevId: 309482953
GitOrigin-RevId: f34cd235a12ad0ee1fea3a1ee5a427272dc2b285
Change-Id: Icce0c9d547117374d596b9d684e4054ddd118669
2020-05-05 13:52:13 -04:00
Abseil Team
cb52b05ea2 Export of internal Abseil changes
--
adcea274552c5671bdafae7f85797c49c9639b67 by Abseil Team <absl-team@google.com>:

change some const declarations to constexpr

PiperOrigin-RevId: 307516528

--
f828d23bdd437f38ae52ba232fd44c477643ddaf by Derek Mauro <dmauro@google.com>:

Use "-lrt" instead of the resolved find_library result when linking
librt. find_library defaults to shared objects. Imports #665.

PiperOrigin-RevId: 307465639
GitOrigin-RevId: adcea274552c5671bdafae7f85797c49c9639b67
Change-Id: I8f562ef8f57f5ed55192936c764fa6532e3b8adb
2020-04-21 14:10:36 -04:00
Abseil Team
df60c82df4 Export of internal Abseil changes
--
b885a238ec13effcc407e250583e293052bd7984 by Greg Falcon <gfalcon@google.com>:

Remove the dependency of //absl/hash on //absl/strings:cord.

The `AbslHashValue` definition should reside in cord.h, but the implementation currently needs internal details from the hash library.  This CL changes the way that Cord gains access to those internals.  Note that PiecewiseCombiner remains an internal namespace API, and we still reserve the right to make changes to it.

The cord_benchmark shows no statistically significant changes in hash<Cord> performance with this change.

PiperOrigin-RevId: 307393448

--
ca449f230ee719d069d9217ba28a07bf5b3bd8b1 by Derek Mauro <dmauro@google.com>:

Move the extension to use absl::Format() with absl::Cord as a sink to cord.h

PiperOrigin-RevId: 307077162
GitOrigin-RevId: b885a238ec13effcc407e250583e293052bd7984
Change-Id: If24a90782c786fa0b4343bc7d72d053b66c153ea
2020-04-20 12:56:42 -04:00
Abseil Team
bf6166a635 Export of internal Abseil changes
--
1eb20c4802ccaa316ecebc237877210b77ac84f7 by Abseil Team <absl-team@google.com>:

Use constraint_values to detect windows.

This resolves ambiguous copts when cross compiling with LLVM on Windows.

PiperOrigin-RevId: 305935379

--
47c96948132a577b14642ad4c910052768c41d62 by Abseil Team <absl-team@google.com>:

Add StrSplit conversion tests for the swisstable containers.

PiperOrigin-RevId: 305747160

--
0daea0f78b50d49520bd6e67d093cd87d057bb86 by Abseil Team <absl-team@google.com>:

Typo fix: Removes duplicate word.

PiperOrigin-RevId: 305502962
GitOrigin-RevId: 1eb20c4802ccaa316ecebc237877210b77ac84f7
Change-Id: I1bfa0beda0260027a22bc671344cc8b74315b77a
2020-04-11 06:40:20 -04:00
Abseil Team
73ea9a9572 Export of internal Abseil changes
--
87cdfd6aa40941e116cd79ef70f9a7a8271db163 by Abseil Team <absl-team@google.com>:

Fix a typo in random.h API documentation.

PiperOrigin-RevId: 305176308

--
8a38e1df49a18a954daca3ce617fd69045ff4c19 by Derek Mauro <dmauro@google.com>:

Import GitHub #647: Allow external add_subdirectory for using GoogleTest

PiperOrigin-RevId: 305156797

--
b1a2441536d4964fbe4e2329e74c322e6c41a4e6 by Gennadiy Rozental <rogeeff@google.com>:

temporary roll back.

PiperOrigin-RevId: 305149619

--
c78767577264348d2f881893f9407aadfe73ab75 by CJ Johnson <johnsoncj@google.com>:

Rollback update to linux_clang-latest container while investigating
a compiler bug.

PiperOrigin-RevId: 304897689

--
3c6fd38f53d2e982569fdba4043f75271c7b5de4 by Derek Mauro <dmauro@google.com>:

Update linux_clang-latest container to one based on Ubuntu 18.04,
which has libstdc++-8.

PiperOrigin-RevId: 304885120
GitOrigin-RevId: 87cdfd6aa40941e116cd79ef70f9a7a8271db163
Change-Id: Iefa6efee93907ec0eecb8add804c5cc2f052b64d
2020-04-07 00:10:49 -04:00
Abseil Team
62f05b1f57 Export of internal Abseil changes
--
3e6352709da9a529e608eabff862a12bfaecb587 by Gennadiy Rozental <rogeeff@google.com>:

Replace local copy of FastTypeId with one shared in absl/base/internal.

PiperOrigin-RevId: 304181357

--
c89ea428f732226f4dceb508cd6ba3955a1e49e1 by Andy Getzendanner <durandal@google.com>:

Typo fix: add a missing colon.

PiperOrigin-RevId: 304064210

--
de2ee7a96bdc7193ffcceb6a2fd6bf464955cbe7 by Samuel Benzaquen <sbenza@google.com>:

Reduce the overhead of the registration token by using an empty struct instead
of bool.

PiperOrigin-RevId: 304054311

--
222f05d24fb1df7e815946543a7dc78847c83f92 by Derek Mauro <dmauro@google.com>:

Turn off hashtablez in opensource builds.

Hashtablez is an unsupported, internal-only feature for collecting
information about hashtable usage and performance. By turning it off
in builds where it is unsupported, we get just a little more performance.

PiperOrigin-RevId: 304035460
GitOrigin-RevId: 3e6352709da9a529e608eabff862a12bfaecb587
Change-Id: I0bfe9b5df808a7e35c154b39e6c80e68b0da2b70
2020-04-01 15:19:51 -04:00
Abseil Team
fba8a316c3 Export of internal Abseil changes
--
2dd5008c7b4176859e320c7c337078adb173b662 by Tom Manshreck <shreck@google.com>:

Internal change

PiperOrigin-RevId: 304022549

--
6442abd78697b03cfe698b0d0dac7f1eb4b5cb38 by Andy Getzendanner <durandal@google.com>:

Internal change

PiperOrigin-RevId: 303890410

--
eb8b37b468b0f23da09d3de714272928ef61f942 by Gennadiy Rozental <rogeeff@google.com>:

Roll changes forward with ChunkIterator templatized.

This should facilitate usage of "small" chunk iterator for a regular usage and proper "big" iterator internally in Cord implementation. This way Cord users are not exposed to stack size overhead if they have a lot of chunk iterators or recursive implementation which relies on chunk iterators.

PiperOrigin-RevId: 303877118

--
9623c569e7c55b45254e95f2d14c5badf9c901aa by Gennadiy Rozental <rogeeff@google.com>:

Switch Flags implementation of fast type id to use absl/base/internal/fast_type_id.h

PiperOrigin-RevId: 303861019

--
e2931e8d53c86d0816da6bbc8ba58cf5a3a443bb by Matthew Brown <matthewbr@google.com>:

Internal Change

PiperOrigin-RevId: 303832407

--
b549ed6e441e920b8ad6f02a80b9fd543820ef86 by Tom Manshreck <shreck@google.com>:

Update Cord header file comments to Abseil standards

PiperOrigin-RevId: 303823232

--
fc633d4f31a2d058f2b6a7029fc7c9820cd71c92 by Evan Brown <ezb@google.com>:

Remove top-level const from K/V in map_slot_type::mutable_value and map_slot_type::key.

This allows us to move between `map_slot_type::mutable_value`s internally even when the key_type and/or mapped_type specified by the user are const.

PiperOrigin-RevId: 303811694

--
909b3ce7cb3583ee9c374d36ff5f82bba02a1b64 by Derek Mauro <dmauro@google.com>:

Add hardening assertions to the preconditions of absl::Cord

PiperOrigin-RevId: 303419537

--
9d32f79eabd54e6cb17bcc28b53e9bcfeb3cf6f4 by Greg Falcon <gfalcon@google.com>:

Don't use MSVC-specific bit manipulations when using Clang on Windows.

This fixes a compiler warning.  Note that we do not have continuous testing for this configuration; this CL is best-effort support.

PiperOrigin-RevId: 303322582

--
f6e0a35a2b9081d2a9eef73789b7bc1b5e46e5ad by Gennadiy Rozental <rogeeff@google.com>:

Introduce standlone FastTypeId utility to represent compile time unique type id.

PiperOrigin-RevId: 303180545

--
99120e9fbdb5b2d327139ab8f617533d7bc3345b by Abseil Team <absl-team@google.com>:

Changed absl's import of std::string_view to
using string_view = std::string_view.
This should help tools (e.g. include-what-you-use) discover where absl::string_view is defined.

PiperOrigin-RevId: 303169095
GitOrigin-RevId: 2dd5008c7b4176859e320c7c337078adb173b662
Change-Id: I1e18ae08e23686ac963e7ea5e5bd499e18d51048
2020-03-31 16:34:04 -04:00
Abseil Team
7853a7586c Export of internal Abseil changes
--
91ca367a7548270155721bdda74611aeea2a2153 by Abseil Team <absl-team@google.com>:

Replace the only usage of btree_node::swap with simpler logic using transfers and delete btree_node::swap.

Add a benchmark for constructing small containers.

PiperOrigin-RevId: 301169874

--
ff9d73a7125b7f8ab5733cda877204dfbfac138e by Derek Mauro <dmauro@google.com>:

Ensure ABSL_CXX_STANDARD is set.
Fixes #640

PiperOrigin-RevId: 301160106

--
14ca0beee8c109e532134e7e9da7b072da1bf911 by Abseil Team <absl-team@google.com>:

Rollback the change to make Cord iterators a fixed size.  That change increased the iterator size, which can cause a deep recursion call to hit the stack memory limit, in turn causing a signal 11 failure.

PiperOrigin-RevId: 301084915

--
619e3cd9e56408bdb8b3b5a1e08dda1e95242264 by Matthew Brown <matthewbr@google.com>:

Internal Change

PiperOrigin-RevId: 300832828

--
64f8d62ab4c4c78077dbe85a9595a8eeb6d16608 by Gennadiy Rozental <rogeeff@google.com>:

Fix for empty braces support.

We will call proper aggregate construction in case when {} is used as default value. In other words instead of "new T", we'll call "new T{}".

PiperOrigin-RevId: 300715686

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

Emscripten supports thread-local storage nowadays.

PiperOrigin-RevId: 300675185
GitOrigin-RevId: 91ca367a7548270155721bdda74611aeea2a2153
Change-Id: I3344f745f9c3fc78775532b1808442fabd98e34a
2020-03-16 15:11:38 -04:00
Abseil Team
c6954897f7 Export of internal Abseil changes
--
66a0a46462692378f77518f9db766a218bfac40b by Derek Mauro <dmauro@google.com>:

Internal change

PiperOrigin-RevId: 300565981

--
2a1ad67662b2e22beec7d3be019e6bba23c41c7f by Derek Mauro <dmauro@google.com>:

Fix CompressedTuple move constructor on MSVC
Imports GitHub #637

PiperOrigin-RevId: 300545840

--
a3ee3ad036bbb6b0031121fd58299e5c59a243e1 by Derek Mauro <dmauro@google.com>:

Disable LLVM's XRay instrumentation on Android
Fixes #626

PiperOrigin-RevId: 300540906

--
87999244b1f825e585ec12a431086cb60daeb24f by Gennadiy Rozental <rogeeff@google.com>:

Increase max cord depth by 2.
After reviewing of the paper we can prove that the algorithm in fact can lead to slightly larger max depth.

PiperOrigin-RevId: 300422376

--
98de175ee8ad33290ef883c167c2de4414a11007 by Abseil Team <absl-team@google.com>:

Use *opt/opt-> instead of opt.value() in an example, after checking the optional has a value.

PiperOrigin-RevId: 300253502

--
1107aa0acf0fe743ef50173e02e48f0d4eb572ef by Derek Mauro <dmauro@google.com>:

Stop overriding the default system C++ dialect in CMake

CMake on MacOS has some very strange defaults, like Wno-c++11-extensions,
and doesn't seem to respect CMAKE_CXX_STANDARD, so use CMAKE_CXX_FLAGS instead.

PiperOrigin-RevId: 300180753
GitOrigin-RevId: 66a0a46462692378f77518f9db766a218bfac40b
Change-Id: Icd7b84c49306441b012cb87f244cc92a11697db8
2020-03-12 12:46:00 -04:00
Abseil Team
a877af1f29 Export of internal Abseil changes
--
ea0cfebeb69b25bec343652bbe1a203f5476c51a by Mark Barolak <mbar@google.com>:

Change "std::string" to "string" in places where a "std::" qualification was incorrectly inserted by automation.

PiperOrigin-RevId: 300108520
GitOrigin-RevId: ea0cfebeb69b25bec343652bbe1a203f5476c51a
Change-Id: Ie3621e63a6ebad67b9fe56a3ebe33e1d50dac602
2020-03-10 13:59:49 -04:00
Abseil Team
cf3a1998e9 Export of internal Abseil changes
--
44ccc0320ffaa2106ba3c6393b5a40c3b4f7b901 by Abseil Team <absl-team@google.com>:

Clarify span iterator documentation.

PiperOrigin-RevId: 299110584

--
80d016d8026b8d6904aa0ff2d5e1c3ae27f129bb by Greg Falcon <gfalcon@google.com>:

Add Cord::TryFlat().

PiperOrigin-RevId: 298889772

--
da6900203f1e4131d5693cbca157b6dba099bbed by Greg Falcon <gfalcon@google.com>:

clang-format cord_test.cc.

PiperOrigin-RevId: 298851425
GitOrigin-RevId: 44ccc0320ffaa2106ba3c6393b5a40c3b4f7b901
Change-Id: Ia5394f6fbb473d206726fdd48a00eb07a6acad6a
2020-03-05 20:52:21 +00:00
Abseil Team
b19ba96766 Export of internal Abseil changes
--
a3e58c1870a9626039f4d178d2d599319bd9f8a8 by Matt Kulukundis <kfm@google.com>:

Allow MakeCordFromExternal to take a zero arg releaser.

PiperOrigin-RevId: 298650274

--
01897c4a9bb99f3dc329a794019498ad345ddebd by Samuel Benzaquen <sbenza@google.com>:

Reduce library bloat for absl::Flag by moving the definition of base virtual functions to a .cc file.
This removes the duplicate symbols in user translation units and  has the side effect of moving the vtable definition too (re key function)

PiperOrigin-RevId: 298617920

--
190f0d3782c63aed01046886d7fbc1be5bca2de9 by Derek Mauro <dmauro@google.com>:

Import GitHub #596: Unbreak stacktrace code for UWP apps

PiperOrigin-RevId: 298600834

--
cd5cf6f8c87b35b85a9584e94da2a99057345b73 by Gennadiy Rozental <rogeeff@google.com>:

Use union of heap allocated pointer, one word atomic and two word atomic to represent flags value.

Any type T, which is trivially copy-able and with with sizeof(T) <= 8, will be stored in atomic int64_t.
Any type T, which is trivially copy-able and with with 8 < sizeof(T) <= 16, will be stored in atomic AlignedTwoWords.

We also introducing value storage type to distinguish these cases.

PiperOrigin-RevId: 298497200

--
f8fe7bd53bfed601f002f521e34ab4bc083fc28b by Matthew Brown <matthewbr@google.com>:

Ensure a deep copy and proper equality on absl::Status::ErasePayload

PiperOrigin-RevId: 298482742

--
a5c9ccddf4b04f444e3f7e27dbc14faf1fcb5373 by Gennadiy Rozental <rogeeff@google.com>:

Change ChunkIterator implementation to use fixed capacity collection of CordRep*. We can now assume that depth never exceeds 91. That makes comparison operator exception safe.

I've tested that with this CL we do not observe an overhead of chunk_end. Compiler optimized this iterator completely.

PiperOrigin-RevId: 298458472

--
327ea5e8910bc388b03389c730763f9823abfce5 by Abseil Team <absl-team@google.com>:

Minor cleanups in b-tree code:
- Rename some variables: fix issues of different param names between definition/declaration, move away from `x` as a default meaningless variable name.
- Make init_leaf/init_internal be non-static methods (they already take the node as the first parameter).
- In internal_emplace/try_shrink, update root/rightmost the same way as in insert_unique/insert_multi.
- Replace a TODO with a comment.

PiperOrigin-RevId: 298432836

--
8020ce9ec8558ee712d9733ae3d660ac1d3ffe1a by Abseil Team <absl-team@google.com>:

Guard against unnecessary copy in case the buffer is empty. This is important in cases were the user is explicitly tuning their chunks to match PiecewiseChunkSize().

PiperOrigin-RevId: 298366044

--
89324441d1c0c697c90ba7d8fc63639805fcaa9d by Abseil Team <absl-team@google.com>:

Internal change

PiperOrigin-RevId: 298219363
GitOrigin-RevId: a3e58c1870a9626039f4d178d2d599319bd9f8a8
Change-Id: I28dffc684b6fd0292b94807b88ec6664d5d0e183
2020-03-03 17:32:55 -05:00
Abseil Team
3c81410510 Export of internal Abseil changes
--
97faa5fdfa4cd5d7a74cd9332cddd8a7c1e67b89 by Abseil Team <absl-team@google.com>:

Internal changes

PiperOrigin-RevId: 295164378

--
74990f100b3f4172c770ef8c76c05c8e99febdde by Xiaoyi Zhang <zhangxy@google.com>:

Release `absl::Cord`.

PiperOrigin-RevId: 295161959

--
6018c57f43c45c31dc1a61c0cd75fa2aa9be8dab by Gennadiy Rozental <rogeeff@google.com>:

Introduce independent notion of FlagStaticTypeID.

This change separates static flag value type identification from the type specific "vtable" with all the operations specific to value type. This change allows us to do the following:
* We can move most of "vtable" implementation from handle header, which will become public soon, into implementation details of Abseil Flag.
* We can combine back marshalling ops and general ops into a single vtable routine. They were split previously to facilitate type identification without requiring marshalling routines to be exposed in header.
* We do not need to store two vtable pointers. We can now store only one. The static type id can be deduced on request.

Overall we are saving 24 bytes per flag according to size_tester run.

PiperOrigin-RevId: 295149687

--
986b78e9ba571aa85154e70bda4580edd45bb7bf by Abseil Team <absl-team@google.com>:

Update internal comments.

PiperOrigin-RevId: 295030681

--
825412b29fd6015027bbc3e5f802706eee0d2837 by Matthew Brown <matthewbr@google.com>:

Change str_format_internal::ConversionChar to an enum (from a struct-wrapped enum).

PiperOrigin-RevId: 294987462

--
f9f88d91809d2cc33fc129df70fa93e7a2c35c69 by Derek Mauro <dmauro@google.com>:

Use more precise wording in the question on live-at-head

PiperOrigin-RevId: 294957679
GitOrigin-RevId: 97faa5fdfa4cd5d7a74cd9332cddd8a7c1e67b89
Change-Id: I081e70d148ffac7296d65e2a2f775f643eaf70bf
2020-02-14 12:54:19 -05:00