mbox series

[v4,0/6] generated Go libxl bindings using IDL

Message ID cover.1577111872.git.rosbrookn@ainfosec.com (mailing list archive)
Headers show
Series generated Go libxl bindings using IDL | expand

Message

Nick Rosbrook Dec. 23, 2019, 3:17 p.m. UTC
After Xen summit, we started the discussion in this[1] RFC thread
to figure out how to generate Go bindings for libxl. This series
implements that Go code generation using the existing IDL, and updates
the existing hand-written code in xenlight.go to use the generated
code.

The goal of this series is to provide a good foundation for continued
development of the Go package.

The v1 series can be found on my GitHub branch[2].

Changes in v2:
- GitHub branch for v2 [3].
- Drop patch 01/24 from v1 since was committed as a bug fix for 4.13.
- The Makefile changes in 24/24 from v1 have been moved to the patches
  where the build changes are introduced.

Changes in v3:
- GitHub branch for v3 [4].
- Simplify a pattern for iterating over builtin types
  in their fromC functions.
- Try not to duplicate as much code in gengotypes.py, and
  use consistent style in generated code when calling fromC.

Changes in v4:
- GitHub branch for v4 [5].
- The first 16 patches were commited after v3.

[1] https://lists.xenproject.org/archives/html/xen-devel/2019-07/msg02259.html
[2] https://github.com/enr0n/xen/tree/golang-patches-v1
[3] https://github.com/enr0n/xen/tree/golang-patches-v2
[4] https://github.com/enr0n/xen/tree/golang-patches-v3
[5] https://github.com/enr0n/xen/tree/golang-patches-v4

Nick Rosbrook (6):
  golang/xenlight: implement array C to Go marshaling
  golang/xenlight: begin Go to C type marshaling
  golang/xenlight: implement keyed union Go to C marshaling
  golang/xenlight: implement array Go to C marshaling
  golang/xenlight: revise use of Context type
  golang/xenlight: add error return type to Context.Cpupoolinfo

 tools/golang/xenlight/gengotypes.py  |  232 ++-
 tools/golang/xenlight/helpers.gen.go | 1945 ++++++++++++++++++++++++++
 tools/golang/xenlight/xenlight.go    |  222 +--
 3 files changed, 2212 insertions(+), 187 deletions(-)