table_internal.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2009-2021, Google LLC
3  * All rights reserved.
4  *
5  * Redistribution and use in source and binary forms, with or without
6  * modification, are permitted provided that the following conditions are met:
7  * * Redistributions of source code must retain the above copyright
8  * notice, this list of conditions and the following disclaimer.
9  * * Redistributions in binary form must reproduce the above copyright
10  * notice, this list of conditions and the following disclaimer in the
11  * documentation and/or other materials provided with the distribution.
12  * * Neither the name of Google LLC nor the
13  * names of its contributors may be used to endorse or promote products
14  * derived from this software without specific prior written permission.
15  *
16  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
17  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
19  * ARE DISCLAIMED. IN NO EVENT SHALL Google LLC BE LIABLE FOR ANY DIRECT,
20  * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
21  * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
22  * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
23  * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
25  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26  */
27 
28 /*
29  * upb_table
30  *
31  * This header is INTERNAL-ONLY! Its interfaces are not public or stable!
32  * This file defines very fast int->upb_value (inttable) and string->upb_value
33  * (strtable) hash tables.
34  *
35  * The table uses chained scatter with Brent's variation (inspired by the Lua
36  * implementation of hash tables). The hash function for strings is Austin
37  * Appleby's "MurmurHash."
38  *
39  * The inttable uses uintptr_t as its key, which guarantees it can be used to
40  * store pointers or integers of at least 32 bits (upb isn't really useful on
41  * systems where sizeof(void*) < 4).
42  *
43  * The table must be homogeneous (all values of the same type). In debug
44  * mode, we check this on insert and lookup.
45  */
46 
47 #ifndef UPB_TABLE_H_
48 #define UPB_TABLE_H_
49 
50 #include <stdint.h>
51 #include <string.h>
52 
53 #include "upb/upb.h"
54 
55 // Must be last.
56 #include "upb/port_def.inc"
57 
58 #ifdef __cplusplus
59 extern "C" {
60 #endif
61 
62 /* upb_value ******************************************************************/
63 
64 typedef struct {
65  uint64_t val;
66 } upb_value;
67 
68 /* Variant that works with a length-delimited rather than NULL-delimited string,
69  * as supported by strtable. */
70 char* upb_strdup2(const char* s, size_t len, upb_Arena* a);
71 
72 UPB_INLINE void _upb_value_setval(upb_value* v, uint64_t val) { v->val = val; }
73 
74 /* For each value ctype, define the following set of functions:
75  *
76  * // Get/set an int32 from a upb_value.
77  * int32_t upb_value_getint32(upb_value val);
78  * void upb_value_setint32(upb_value *val, int32_t cval);
79  *
80  * // Construct a new upb_value from an int32.
81  * upb_value upb_value_int32(int32_t val); */
82 #define FUNCS(name, membername, type_t, converter, proto_type) \
83  UPB_INLINE void upb_value_set##name(upb_value* val, type_t cval) { \
84  val->val = (converter)cval; \
85  } \
86  UPB_INLINE upb_value upb_value_##name(type_t val) { \
87  upb_value ret; \
88  upb_value_set##name(&ret, val); \
89  return ret; \
90  } \
91  UPB_INLINE type_t upb_value_get##name(upb_value val) { \
92  return (type_t)(converter)val.val; \
93  }
94 
99 FUNCS(bool, _bool, bool, bool, UPB_CTYPE_BOOL)
100 FUNCS(cstr, cstr, char*, uintptr_t, UPB_CTYPE_CSTR)
102 FUNCS(constptr, constptr, const void*, uintptr_t, UPB_CTYPE_CONSTPTR)
103 
104 #undef FUNCS
105 
106 UPB_INLINE void upb_value_setfloat(upb_value* val, float cval) {
107  memcpy(&val->val, &cval, sizeof(cval));
108 }
109 
110 UPB_INLINE void upb_value_setdouble(upb_value* val, double cval) {
111  memcpy(&val->val, &cval, sizeof(cval));
112 }
113 
115  upb_value ret;
116  upb_value_setfloat(&ret, cval);
117  return ret;
118 }
119 
121  upb_value ret;
122  upb_value_setdouble(&ret, cval);
123  return ret;
124 }
125 
126 #undef SET_TYPE
127 
128 /* upb_tabkey *****************************************************************/
129 
130 /* Either:
131  * 1. an actual integer key, or
132  * 2. a pointer to a string prefixed by its uint32_t length, owned by us.
133  *
134  * ...depending on whether this is a string table or an int table. We would
135  * make this a union of those two types, but C89 doesn't support statically
136  * initializing a non-first union member. */
138 
140  char* mem = (char*)key;
141  if (len) memcpy(len, mem, sizeof(*len));
142  return mem + sizeof(*len);
143 }
144 
147  uint32_t len;
148  ret.data = upb_tabstr(key, &len);
149  ret.size = len;
150  return ret;
151 }
152 
153 /* upb_tabval *****************************************************************/
154 
155 typedef struct upb_tabval {
156  uint64_t val;
157 } upb_tabval;
158 
159 #define UPB_TABVALUE_EMPTY_INIT \
160  { -1 }
161 
162 /* upb_table ******************************************************************/
163 
164 typedef struct _upb_tabent {
165  upb_tabkey key;
166  upb_tabval val;
167 
168  /* Internal chaining. This is const so we can create static initializers for
169  * tables. We cast away const sometimes, but *only* when the containing
170  * upb_table is known to be non-const. This requires a bit of care, but
171  * the subtlety is confined to table.c. */
172  const struct _upb_tabent* next;
173 } upb_tabent;
174 
175 typedef struct {
176  size_t count; /* Number of entries in the hash part. */
177  uint32_t mask; /* Mask to turn hash value -> bucket. */
178  uint32_t max_count; /* Max count before we hit our load limit. */
179  uint8_t size_lg2; /* Size of the hashtable part is 2^size_lg2 entries. */
180  upb_tabent* entries;
181 } upb_table;
182 
183 typedef struct {
184  upb_table t;
185 } upb_strtable;
186 
187 typedef struct {
188  upb_table t; /* For entries that don't fit in the array part. */
189  const upb_tabval* array; /* Array part of the table. See const note above. */
190  size_t array_size; /* Array part size. */
191  size_t array_count; /* Array part number of elements. */
192 } upb_inttable;
193 
195  if (t->size_lg2 == 0)
196  return 0;
197  else
198  return 1 << t->size_lg2;
199 }
200 
201 /* Internal-only functions, in .h file only out of necessity. */
202 UPB_INLINE bool upb_tabent_isempty(const upb_tabent* e) { return e->key == 0; }
203 
204 /* Initialize and uninitialize a table, respectively. If memory allocation
205  * failed, false is returned that the table is uninitialized. */
207 bool upb_strtable_init(upb_strtable* table, size_t expected_size, upb_Arena* a);
208 
209 /* Returns the number of values in the table. */
210 size_t upb_inttable_count(const upb_inttable* t);
212  return t->t.count;
213 }
214 
216 
217 /* Inserts the given key into the hashtable with the given value. The key must
218  * not already exist in the hash table. For string tables, the key must be
219  * NULL-terminated, and the table will make an internal copy of the key.
220  * Inttables must not insert a value of UINTPTR_MAX.
221  *
222  * If a table resize was required but memory allocation failed, false is
223  * returned and the table is unchanged. */
225  upb_Arena* a);
226 bool upb_strtable_insert(upb_strtable* t, const char* key, size_t len,
227  upb_value val, upb_Arena* a);
228 
229 /* Looks up key in this table, returning "true" if the key was found.
230  * If v is non-NULL, copies the value for this key into *v. */
232 bool upb_strtable_lookup2(const upb_strtable* t, const char* key, size_t len,
233  upb_value* v);
234 
235 /* For NULL-terminated strings. */
236 UPB_INLINE bool upb_strtable_lookup(const upb_strtable* t, const char* key,
237  upb_value* v) {
238  return upb_strtable_lookup2(t, key, strlen(key), v);
239 }
240 
241 /* Removes an item from the table. Returns true if the remove was successful,
242  * and stores the removed item in *val if non-NULL. */
244 bool upb_strtable_remove2(upb_strtable* t, const char* key, size_t len,
245  upb_value* val);
246 
248  upb_value* v) {
249  return upb_strtable_remove2(t, key, strlen(key), v);
250 }
251 
252 /* Updates an existing entry in an inttable. If the entry does not exist,
253  * returns false and does nothing. Unlike insert/remove, this does not
254  * invalidate iterators. */
256 
257 /* Optimizes the table for the current set of entries, for both memory use and
258  * lookup time. Client should call this after all entries have been inserted;
259  * inserting more entries is legal, but will likely require a table resize. */
261 
262 /* Exposed for testing only. */
263 bool upb_strtable_resize(upb_strtable* t, size_t size_lg2, upb_Arena* a);
264 
265 /* Iterators ******************************************************************/
266 
267 /* Iteration over inttable.
268  *
269  * intptr_t iter = UPB_INTTABLE_BEGIN;
270  * uintptr_t key;
271  * upb_value val;
272  * while (upb_inttable_next2(t, &key, &val, &iter)) {
273  * // ...
274  * }
275  */
276 
277 #define UPB_INTTABLE_BEGIN -1
278 
280  intptr_t* iter);
282 
283 /* Iteration over strtable.
284  *
285  * intptr_t iter = UPB_INTTABLE_BEGIN;
286  * upb_StringView key;
287  * upb_value val;
288  * while (upb_strtable_next2(t, &key, &val, &iter)) {
289  * // ...
290  * }
291  */
292 
293 #define UPB_STRTABLE_BEGIN -1
294 
296  upb_value* val, intptr_t* iter);
298 
299 /* DEPRECATED iterators, slated for removal.
300  *
301  * Iterators for int and string tables. We are subject to some kind of unusual
302  * design constraints:
303  *
304  * For high-level languages:
305  * - we must be able to guarantee that we don't crash or corrupt memory even if
306  * the program accesses an invalidated iterator.
307  *
308  * For C++11 range-based for:
309  * - iterators must be copyable
310  * - iterators must be comparable
311  * - it must be possible to construct an "end" value.
312  *
313  * Iteration order is undefined.
314  *
315  * Modifying the table invalidates iterators. upb_{str,int}table_done() is
316  * guaranteed to work even on an invalidated iterator, as long as the table it
317  * is iterating over has not been freed. Calling next() or accessing data from
318  * an invalidated iterator yields unspecified elements from the table, but it is
319  * guaranteed not to crash and to return real table elements (except when done()
320  * is true). */
321 
322 /* upb_strtable_iter **********************************************************/
323 
324 /* upb_strtable_iter i;
325  * upb_strtable_begin(&i, t);
326  * for(; !upb_strtable_done(&i); upb_strtable_next(&i)) {
327  * const char *key = upb_strtable_iter_key(&i);
328  * const upb_value val = upb_strtable_iter_value(&i);
329  * // ...
330  * }
331  */
332 
333 typedef struct {
334  const upb_strtable* t;
335  size_t index;
337 
345  const upb_strtable_iter* i2);
346 
347 /* upb_inttable_iter **********************************************************/
348 
349 /* upb_inttable_iter i;
350  * upb_inttable_begin(&i, t);
351  * for(; !upb_inttable_done(&i); upb_inttable_next(&i)) {
352  * uintptr_t key = upb_inttable_iter_key(&i);
353  * upb_value val = upb_inttable_iter_value(&i);
354  * // ...
355  * }
356  */
357 
358 typedef struct {
359  const upb_inttable* t;
360  size_t index;
361  bool array_part;
363 
365  return &i->t->t.entries[i->index];
366 }
367 
375  const upb_inttable_iter* i2);
376 
377 uint32_t _upb_Hash(const void* p, size_t n, uint64_t seed);
378 
379 #ifdef __cplusplus
380 } /* extern "C" */
381 #endif
382 
383 #include "upb/port_undef.inc"
384 
385 #endif /* UPB_TABLE_H_ */
ptr
char * ptr
Definition: abseil-cpp/absl/base/internal/low_level_alloc_test.cc:45
upb_strtable_begin
void upb_strtable_begin(upb_strtable_iter *i, const upb_strtable *t)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1636
UPB_CTYPE_BOOL
@ UPB_CTYPE_BOOL
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:672
upb_strtable_resize
bool upb_strtable_resize(upb_strtable *t, size_t size_lg2, upb_Arena *a)
Definition: table.c:471
upb_strtable_lookup2
bool upb_strtable_lookup2(const upb_strtable *t, const char *key, size_t len, upb_value *v)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1612
UPB_CTYPE_INT64
@ UPB_CTYPE_INT64
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:669
upb_strtable_insert
bool upb_strtable_insert(upb_strtable *t, const char *key, size_t len, upb_value val, upb_Arena *a)
Definition: table.c:486
upb_tabent
struct _upb_tabent upb_tabent
google::protobuf::int64
int64_t int64
Definition: third_party/bloaty/third_party/protobuf/src/google/protobuf/stubs/port.h:151
upb_inttable_next2
bool upb_inttable_next2(const upb_inttable *t, uintptr_t *key, upb_value *val, intptr_t *iter)
Definition: table.c:800
upb_strtable_iter_setdone
void upb_strtable_iter_setdone(upb_strtable_iter *i)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1668
upb_value
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:681
string.h
seed
static const uint8_t seed[20]
Definition: dsa_test.cc:79
upb_strdup2
char * upb_strdup2(const char *s, size_t len, upb_Arena *a)
Definition: table.c:70
array
PHP_PROTO_OBJECT_FREE_END PHP_PROTO_OBJECT_DTOR_END intern array
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/array.c:111
upb_strtable_next2
bool upb_strtable_next2(const upb_strtable *t, upb_StringView *key, upb_value *val, intptr_t *iter)
Definition: table.c:855
str_tabent
const UPB_INLINE upb_tabent * str_tabent(const upb_strtable_iter *i)
Definition: table_internal.h:364
google::protobuf::uint32
uint32_t uint32
Definition: third_party/bloaty/third_party/protobuf/src/google/protobuf/stubs/port.h:155
upb_strtable_lookup
UPB_INLINE bool upb_strtable_lookup(const upb_strtable *t, const char *key, upb_value *v)
Definition: table_internal.h:236
FUNCS
#define FUNCS(name, membername, type_t, converter, proto_type)
Definition: table_internal.h:82
upb_inttable_begin
void upb_inttable_begin(upb_inttable_iter *i, const upb_inttable *t)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1936
upb_strtable_iter_isequal
bool upb_strtable_iter_isequal(const upb_strtable_iter *i1, const upb_strtable_iter *i2)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1673
upb_strtable_remove
UPB_INLINE bool upb_strtable_remove(upb_strtable *t, const char *key, upb_value *v)
Definition: table_internal.h:247
a
int a
Definition: abseil-cpp/absl/container/internal/hash_policy_traits_test.cc:88
upb_strtable_remove2
bool upb_strtable_remove2(upb_strtable *t, const char *key, size_t len, upb_value *val)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:976
xds_manager.p
p
Definition: xds_manager.py:60
uint8_t
unsigned char uint8_t
Definition: stdint-msvc2008.h:78
upb_tabent_isempty
UPB_INLINE bool upb_tabent_isempty(const upb_tabent *e)
Definition: table_internal.h:202
upb_inttable_next
void upb_inttable_next(upb_inttable_iter *i)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1943
upb_strtable_next
void upb_strtable_next(upb_strtable_iter *i)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1641
uint32_t
unsigned int uint32_t
Definition: stdint-msvc2008.h:80
upb_strtable_clear
void upb_strtable_clear(upb_strtable *t)
Definition: php-upb.c:2288
memcpy
memcpy(mem, inblock.get(), min(CONTAINING_RECORD(inblock.get(), MEMBLOCK, data) ->size, size))
google::protobuf::int32
int32_t int32
Definition: third_party/bloaty/third_party/protobuf/src/google/protobuf/stubs/port.h:150
upb_table_size
UPB_INLINE size_t upb_table_size(const upb_table *t)
Definition: table_internal.h:194
i1
int i1
Definition: abseil-cpp/absl/container/btree_test.cc:2772
int64_t
signed __int64 int64_t
Definition: stdint-msvc2008.h:89
UPB_CTYPE_INT32
@ UPB_CTYPE_INT32
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:668
upb_inttable_remove
bool upb_inttable_remove(upb_inttable *t, uintptr_t key, upb_value *val)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1817
_upb_tabent::val
upb_tabval val
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:809
upb.h
upb_strtable_init
bool upb_strtable_init(upb_strtable *table, size_t expected_size, upb_Arena *a)
Definition: table.c:456
setup.v
v
Definition: third_party/bloaty/third_party/capstone/bindings/python/setup.py:42
upb_inttable_iter
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:1113
upb_inttable_lookup
bool upb_inttable_lookup(const upb_inttable *t, uintptr_t key, upb_value *v)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1803
UPB_INLINE
#define UPB_INLINE
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:53
uint64_t
unsigned __int64 uint64_t
Definition: stdint-msvc2008.h:90
upb_tabkey
uintptr_t upb_tabkey
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:787
upb_inttable
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:848
upb_tabstr
UPB_INLINE char * upb_tabstr(upb_tabkey key, uint32_t *len)
Definition: table_internal.h:139
upb_tabval
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:798
_upb_value_setval
UPB_INLINE void _upb_value_setval(upb_value *v, uint64_t val)
Definition: table_internal.h:72
intptr_t
_W64 signed int intptr_t
Definition: stdint-msvc2008.h:118
google::protobuf::uint64
uint64_t uint64
Definition: third_party/bloaty/third_party/protobuf/src/google/protobuf/stubs/port.h:156
upb_inttable_iter_isequal
bool upb_inttable_iter_isequal(const upb_inttable_iter *i1, const upb_inttable_iter *i2)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1987
upb_inttable_removeiter
void upb_inttable_removeiter(upb_inttable *t, intptr_t *iter)
Definition: table.c:827
UPB_CTYPE_UINT32
@ UPB_CTYPE_UINT32
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:670
uintptr_t
_W64 unsigned int uintptr_t
Definition: stdint-msvc2008.h:119
upb_inttable_count
size_t upb_inttable_count(const upb_inttable *t)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1711
upb_tabstrview
UPB_INLINE upb_StringView upb_tabstrview(upb_tabkey key)
Definition: table_internal.h:145
upb_inttable_iter_value
upb_value upb_inttable_iter_value(const upb_inttable_iter *i)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1974
n
int n
Definition: abseil-cpp/absl/container/btree_test.cc:1080
stdint.h
upb_inttable_insert
bool upb_inttable_insert(upb_inttable *t, uintptr_t key, upb_value val, upb_Arena *a)
Definition: table.c:634
mem
void * mem
Definition: libc.cpp:91
upb_inttable_compact
void upb_inttable_compact(upb_inttable *t, upb_Arena *a)
Definition: table.c:710
_upb_tabent::next
const struct _upb_tabent * next
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:815
upb_strtable_count
UPB_INLINE size_t upb_strtable_count(const upb_strtable *t)
Definition: table_internal.h:211
UPB_CTYPE_CSTR
@ UPB_CTYPE_CSTR
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:673
upb_value::val
uint64_t val
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:682
_upb_Hash
uint32_t _upb_Hash(const void *p, size_t n, uint64_t seed)
Definition: table.c:436
key
const char * key
Definition: hpack_parser_table.cc:164
upb_StringView
Definition: upb/upb/upb.h:72
count
int * count
Definition: bloaty/third_party/googletest/googlemock/test/gmock_stress_test.cc:96
UPB_CTYPE_PTR
@ UPB_CTYPE_PTR
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:674
_upb_tabent
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:807
upb_table
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:818
absl::str_format_internal::LengthMod::t
@ t
index
int index
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/protobuf.h:1184
ret
UniquePtr< SSL_SESSION > ret
Definition: ssl_x509.cc:1029
upb_value_double
UPB_INLINE upb_value upb_value_double(double cval)
Definition: table_internal.h:120
upb_strtable_iter_value
upb_value upb_strtable_iter_value(const upb_strtable_iter *i)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1663
upb_inttable_iter_setdone
void upb_inttable_iter_setdone(upb_inttable_iter *i)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1981
upb_strtable_iter_key
upb_StringView upb_strtable_iter_key(const upb_strtable_iter *i)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1651
upb_value_float
UPB_INLINE upb_value upb_value_float(float cval)
Definition: table_internal.h:114
upb_strtable
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:844
upb_tabval::val
uint64_t val
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:799
upb_inttable_iter_key
uintptr_t upb_inttable_iter_key(const upb_inttable_iter *i)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1969
table
uint8_t table[256]
Definition: hpack_parser.cc:456
iter
Definition: test_winkernel.cpp:47
upb_strtable_removeiter
void upb_strtable_removeiter(upb_strtable *t, intptr_t *iter)
Definition: table.c:871
upb_tabval
struct upb_tabval upb_tabval
UPB_CTYPE_CONSTPTR
@ UPB_CTYPE_CONSTPTR
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:675
i2
int i2
Definition: abseil-cpp/absl/container/btree_test.cc:2773
upb_inttable_replace
bool upb_inttable_replace(upb_inttable *t, uintptr_t key, upb_value val)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1810
len
int len
Definition: abseil-cpp/absl/base/internal/low_level_alloc_test.cc:46
upb_strtable_iter
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:1086
upb_strtable_done
bool upb_strtable_done(const upb_strtable_iter *i)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1645
_upb_tabent::key
upb_tabkey key
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:808
upb_value_setdouble
UPB_INLINE void upb_value_setdouble(upb_value *val, double cval)
Definition: table_internal.h:110
int32_t
signed int int32_t
Definition: stdint-msvc2008.h:77
UPB_CTYPE_UINT64
@ UPB_CTYPE_UINT64
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.h:671
upb_tabkey
uintptr_t upb_tabkey
Definition: table_internal.h:137
upb_inttable_init
bool upb_inttable_init(upb_inttable *table, upb_Arena *a)
Definition: table.c:630
upb_inttable_done
bool upb_inttable_done(const upb_inttable_iter *i)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:1958
upb_Arena
Definition: upb_internal.h:36
i
uint64_t i
Definition: abseil-cpp/absl/container/btree_benchmark.cc:230
upb_value_setfloat
UPB_INLINE void upb_value_setfloat(upb_value *val, float cval)
Definition: table_internal.h:106


grpc
Author(s):
autogenerated on Fri May 16 2025 03:00:25