Joshua Haberman
7dd113baa8
Added upb_data.*, left out of last commit.
15 years ago
Joshua Haberman
c241976485
In the midst of a major refactoring.
15 years ago
Joshua Haberman
c6cba2af37
Clarified comment.
15 years ago
Joshua Haberman
dc4246db78
Refined interface of upb_symtab.
15 years ago
Joshua Haberman
2a8ba6f3a2
Updated upbc to new dyncasts.
15 years ago
Joshua Haberman
0a6fc5fad3
Truly fixed type cyclic refcounting.
15 years ago
Joshua Haberman
e15f834a91
Circular references truly work now, along with a test.
...
One simplification to come.
15 years ago
Joshua Haberman
08b4a91204
Add a test for circularly-linked descriptors.
...
The test currently triggers valgrind-detected memory errors.
15 years ago
Joshua Haberman
651c92ab33
Scheme for collecting circular refs.
...
"make descriptorgen" is now valgrind-clean again.
15 years ago
Joshua Haberman
18291eedc3
Make defs refcounted, rename upb_context->upbsymtab.
...
There is currently a memory leak when type definitions
form cycles. This will need to be dealt with.
15 years ago
Joshua Haberman
a95ab58e79
Overhaul defs to derive from a common base.
15 years ago
Joshua Haberman
246a36998b
WIP of cleaning up defs.
15 years ago
Joshua Haberman
d160380736
Update upbc to use self-describing upb_msg instead of void*.
15 years ago
Joshua Haberman
6191fe3ae2
Reference-count upb_msgdef and upb_enumdef.
...
The context owns a reference on each def, defs own references
on defs they reference, and msgs own refs on their def.
15 years ago
Joshua Haberman
cb6c34275f
Fix memory leak in test.
15 years ago
Joshua Haberman
9e3f5e343b
Make upb_msgdef own all its data.
...
This is in anticipation of making upb_msgdef's easy
to dup. This involved removing all traces of any
descriptors from the defs.
15 years ago
Joshua Haberman
f231856c48
Defined Pick Parser interface.
15 years ago
Joshua Haberman
868f118797
Changed parse API to know about msgdefs.
...
This should make it both easier to use and easier to
optimize, in exchange for a small amount of generality.
In practice, any remotely normal case is still very
natural.
15 years ago
Joshua Haberman
7cde43ea0a
Renamed upb_msg_fielddef -> upb_fielddef, upb_enum -> upb_enumdef.
15 years ago
Joshua Haberman
e252432a41
Refactoring: split defs into their own file, move private parsing funcs out of .h file.
15 years ago
Joshua Haberman
33a68acb14
Use a status object for errors so a message can be returned.
...
Also delay deletion of subfields until the entire message is
deleted.
15 years ago
Joshua Haberman
4b47002198
Update Python C extension for new upb_array API.
15 years ago
Joshua Haberman
1fe9414757
Change upb_msg to work with messages that have 0 fields.
15 years ago
Joshua Haberman
46fac0f58d
Tests use valgrind, chdir in test.
15 years ago
Joshua Haberman
d05eac2890
Properly free dynamic memory that has not been reused during parsing.
15 years ago
Joshua Haberman
a022e6ebdb
Fixes for more discerning compilers.
15 years ago
Joshua Haberman
00ba0d1ac1
Unit test comparing parsed results with proto2.
15 years ago
Joshua Haberman
75134e6f9d
Small stylistic improvements in benchmarks.
15 years ago
Joshua Haberman
9b67b322da
Small C++ header fixes.
15 years ago
Joshua Haberman
527a544b04
Small bugfix: enums are int32, not uint32.
15 years ago
Joshua Haberman
085aa44fcd
Small bugfix.
15 years ago
Joshua Haberman
cd2f77d392
Incremental improvements to cbparser, and a test.
15 years ago
Joshua Haberman
22dd1980f6
Added TODO.
15 years ago
Joshua Haberman
f6ee945409
Renamed upb_stream_parser -> upb_cbparser, and API cleanup.
15 years ago
Joshua Haberman
2bad79f721
Fix upbc for upb_array API change.
15 years ago
Joshua Haberman
f17ed90f77
Some cleanup and reformatting, fixed the benchmarks.
15 years ago
Joshua Haberman
b276aa78b6
Updated/corrected comments in pb.c.
15 years ago
Joshua Haberman
bf2082acaa
Add .py files for Python extension (they are just shells).
15 years ago
Joshua Haberman
040f7e6ba2
Significant memory-management refactoring any Python extension.
15 years ago
Joshua Haberman
a223f9af30
More work on Python extension, build libupb PIC.
16 years ago
Joshua Haberman
f00091f340
Beginnings of a Python extension.
16 years ago
Joshua Haberman
cfd67dda49
Various fixes.
16 years ago
Joshua Haberman
1e82f0ebd6
A few more thread-safety fixes.
16 years ago
Joshua Haberman
7fa19a3f95
Finish upb_context thread-safety.
16 years ago
Joshua Haberman
71d82d06d1
Add refcounting and thread-safety to message definitions.
16 years ago
Joshua Haberman
2282d2489b
Refactoring: unify upb_msg.
...
The cost is that a upb_msg will now always have an overhead
of 2*sizeof(void*). This is comparable to proto2 overhead.
The benefit is that upb_msg is now self-describing, and
read-only algorithms can now operate on a upb_msg regardless
of the memory-management scheme.
Also, upb_array and upb_string now know inherently if they
own their associated memory, and upb_array has a generic
pointer for memory management purposes like upb_msg does.
16 years ago
Joshua Haberman
89a6c6d71f
Whoops, re-add static to MurmurHash.
16 years ago
Joshua Haberman
eb67fb9109
Fixed memory leaks in upbc.
16 years ago
Joshua Haberman
8fa6a92f53
Major refactoring of upb_msg. Temporary functionality regression.
...
There is significant refactoring here, as well as some more trivial
name changes. upb_msg has become upb_msgdef, to reflect the fact
that a upb_msg is not *itself* a message, it describes a message.
There are other renamings, such as upb_parse_state -> upb_stream_parser.
More significantly, the upb_msg class and parser have been refactored
to reflect my recent realization about how memory management should
work. upb_msg now has no memory management, and a memory mangement
scheme (that works beautifully with multiple language runtimes) will
be layered on top of it.
This iteration has the new, read-only upb_msg. upb_mm_msg (a
memory-managed message class) will come in the next change.
16 years ago
Joshua Haberman
952ea88db2
Remove perf-cppflags from repository.
16 years ago