summaryrefslogtreecommitdiff
path: root/src/mapi/mapi/mapi_abi.py
AgeCommit message (Collapse)Author
2011-01-20mapi: Add support for bridge mode.Chia-I Wu
In bridge mode, mapi no longer implements glapi.h. It becomes a user of glapi.h. Imagine an app that uses both libGL.so and libGLESv2.so. There will be two copies of glapi in the app's memory. It is possible that _glapi_get_dispatch does not return what _glapi_set_dispatch set, if they access different copies of the global variables. The solution to this situation to build either one of the libraries as a bridge to the other. Or build both libraries as bridges to another shared glapi library.
2011-01-20mapi: Fix glapi printers for gl_and_es_API.xml.Chia-I Wu
Fix GLAPIPrinter, ES1APIPrinter, and ES2APIPrinter to output files that are ready for compilation. Since gl_and_es_API.xml is based on gl_API.xml, the hidden and handcode attributes of entries have to be overridden for ES1APIPrinter and ES2APIPrinter.
2011-01-20mapi: Allow prefix to be macro.Chia-I Wu
Treat prefix as macro when it is all uppercase. Generate PREFIX(name) instead of PREFIXname when it is a macro.
2011-01-20mapi: Add the ability to parse GLAPI XML.Chia-I Wu
A prerequisite if we want to convert vgapi.csv to vgapi.xml, or to use mapi for glapi.
2010-12-24mapi: Add and use entry_get_public.Chia-I Wu
Given a dispatch slot, entry_get_public returns the address of the corresponding public entry point. There may be more than one of them. But since they are all equivalent, it is fine to return any one of them. With entry_get_public, the address of any public entry point can be calculated at runtime when an assembly dispatcher is used. There is no need to have a mapping table in such case. This omits the unnecessary relocations from the binary.
2010-12-24mapi: Allow blocks to be disabled from the output.Chia-I Wu
For example, a printer may ask not to output noop dispatch table.
2010-12-24mapi: Fix hidden entries.Chia-I Wu
Hidden entries are just like normal entries except that they are not exported. Since it is not always possible to hide them, and two hidden aliases can share the same entry, the name of hidden aliases are mangled to '_dispatch_stub_<slot>'.
2010-12-24mapi: Add "handcode" attribute to the script.Chia-I Wu
Entries with handcode attribute will be handled normally, except no entry point will be generated for them.
2010-12-24mapi: Minor ABIPrinter refactoring.Chia-I Wu
Split out function name generation from _c_decl to _c_function, and use it everywhere. Add an optional 'export' argument to _cdecl. It is prepended to the returned string.
2010-12-24mapi: Store alias entry instead of alias name.Chia-I Wu
An entry can hold more info than plain name.
2010-12-06mapi: Rewrite mapi_abi.py to get rid of preprocessor magic.Chia-I Wu
The preprocessor magic in mapi was nothing but obfuscation. Rewrite mapi_abi.py to generate real C code. This commit removes the hack added in 43121f20866bb89e8dac92bd92ec85a943704b7e.
2010-05-07mapi: Add a generic C dispatcher.Chia-I Wu
The idea is to have an API generate a header using mapi_abi.py. The API can then use the header to build a dispatcher.