Commit graph

11 commits

Author SHA1 Message Date
Bill Currie
e4f75791ce [vulkan] Clean up some tangled dependencies
Dependencies on vkparse.hinc were spreading through the code which I
didn't want as that removes a lot of the automation from the automake
files. This keeps all parser code internal to vkparse.c's scope, and any
accesses required for enum and struct (not yet) definitions can be
fetched by name.
2021-01-04 17:26:39 +09:00
Bill Currie
c0c728b188 [vulkan] Fix a few code generation issues
QC's int type is named "integer" (didn't feel like changing that right
now), so special case it to be "int".

Output the parse func name (instead of "fix me").

Output a parse func for enums (needed for arrays of enums
(VkDynamicState)).
2020-12-25 00:17:20 +09:00
Bill Currie
cb2bdb0224 [util] Rename PL_ParseDictionary to PL_ParseStruct
Struct is far more appropriate for its function, and I need to parse a
dictionary into a hash table.
2020-12-24 13:33:37 +09:00
Bill Currie
017d2c1f44 [vulkan] Refactor vkgen struct generation
The addition of data an then string support made keeping track of things
in struct's writeTable a nightmare.
2020-12-23 22:13:50 +09:00
Bill Currie
f1848bb5b7 [vulkan] Add support for parsing binary data 2020-12-23 14:08:53 +09:00
Bill Currie
96df447c45 [vulkan] Hook up the expression parser
The pipeline parser still isn't hooked up yet as something isn't quite
right, but it seems all the parsing works.
2020-12-21 18:38:31 +09:00
Bill Currie
ab04a1915e [build] Fix a pile of gcc 10 issues
gcc got stricter about array accesses, complicating progs macros, and
much better at detecting buffer overflows.
2020-12-21 14:14:29 +09:00
Bill Currie
f4c8d341e1 [vulkan] Implement most of the parser
This gets renderpass parsing almost working (not hooked up, though). The
missing bits are support for expressions for flags (namely support for
the | operator) and references (eg $swapchain.format). However, this
shows that the basic concept for the parser is working.
2020-07-17 00:29:53 +09:00
Bill Currie
0945f30731 [vulkan] Use a property list to drive code gen
The property list specifies the base structures for which parser code
will be generated (along with any structures and enums upon which those
structures depend). It also defines option specialized parsers for
better control.
2020-07-05 16:53:35 +09:00
Bill Currie
e4ee5c70e0 [vulkan] Rework vkgen alias handling
This is much cleaner and now that all the types are there properly,
doing a parser generator should be easier.
2020-07-05 16:53:35 +09:00
Bill Currie
2ca9f80d56 [vulkan] Split up vkgen
It worked as a proof of concept, but as the code itself needs to be a
bit smarter, it would be a lot smarter to break up that code to make it
easier to work on the individual parts.
2020-07-05 16:53:35 +09:00