roll: pigweed pw_bytes: Add PackedPtr
Every object types has an alignment requirement, and for most types this
is greater than one. As a result, pointers to these types have one or
more least significant bits that are always zero. For certain types,
such as intrusive container types, it is desirable to reuse these bits
and avoid creating additional fields.
This class facilitates those use cases by providing a wrapper type that
can be treated like a pointer in many cases, but that can also be used
to set and get a value from the unused bits.
This storage is not free: this class must perform bit operations on
every dereference, adding to its performance cost and code size. This
class should only be used when the benefits of saving memory overhead
outweigh these costs.
Original-Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/235104
Original-Revision: cda5ba673366d189e0ea326a0fa808df181730a7
Rolled-Repo: https://pigweed.googlesource.com/pigweed/pigweed
Rolled-Commits: faac61757b5428..cda5ba673366d1
Roller-URL: https://ci.chromium.org/b/8736437447468905537
GitWatcher: ignore
CQ-Do-Not-Cancel-Tryjobs: true
Change-Id: I6804cb041390b562226a5bd0f9645d196720abf9
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/showcase/sense/+/236834
Bot-Commit: Pigweed Roller <pigweed-roller@pigweed-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Pigweed Roller <pigweed-roller@pigweed-service-accounts.iam.gserviceaccount.com>
Lint: Lint 🤖 <android-build-ayeaye@system.gserviceaccount.com>
diff --git a/MODULE.bazel b/MODULE.bazel
index d8b7977..756c03f 100644
--- a/MODULE.bazel
+++ b/MODULE.bazel
@@ -50,8 +50,8 @@
module_name = "pigweed",
# ROLL: Warning: this entry is automatically updated.
# ROLL: Last updated 2024-09-18.
- # ROLL: By https://cr-buildbucket.appspot.com/build/8736438228202531889.
- commit = "faac61757b5428be3787729d328f6f2f3ebfa9f1",
+ # ROLL: By https://cr-buildbucket.appspot.com/build/8736437447468905537.
+ commit = "cda5ba673366d189e0ea326a0fa808df181730a7",
remote = "https://pigweed.googlesource.com/pigweed/pigweed",
)
@@ -59,8 +59,8 @@
module_name = "pw_toolchain",
# ROLL: Warning: this entry is automatically updated.
# ROLL: Last updated 2024-09-18.
- # ROLL: By https://cr-buildbucket.appspot.com/build/8736438228202531889.
- commit = "faac61757b5428be3787729d328f6f2f3ebfa9f1",
+ # ROLL: By https://cr-buildbucket.appspot.com/build/8736437447468905537.
+ commit = "cda5ba673366d189e0ea326a0fa808df181730a7",
remote = "https://pigweed.googlesource.com/pigweed/pigweed",
strip_prefix = "pw_toolchain_bazel",
)