On 7/26/19 7:05 AM, Markus Armbruster wrote: > In my "build everything" tree, changing a type in qapi/common.json > triggers a recompile of some 3600 out of 6600 objects (not counting > tests and objects that don't depend on qemu/osdep.h). > > One common dependency is QapiErrorClass: it's used only in in > qapi/error.h, which uses nothing else, and is widely included. > > Move QapiErrorClass from common.json to new error.json. Touching > common.json now recompiles only some 2900 objects. > > Cc: Eric Blake <[email protected]> > Signed-off-by: Markus Armbruster <[email protected]> > --- > MAINTAINERS | 2 ++ > include/qapi/error.h | 2 +- > qapi/Makefile.objs | 2 +- > qapi/common.json | 24 ------------------------ > qapi/error.json | 29 +++++++++++++++++++++++++++++ > qapi/qapi-schema.json | 1 + > 6 files changed, 34 insertions(+), 26 deletions(-) > create mode 100644 qapi/error.json
> +++ b/qapi/qapi-schema.json
> @@ -80,6 +80,7 @@
> # stable order, it's best to include each sub-schema just once, or
> # include it first right here.
>
> +{ 'include': 'error.json' }
> { 'include': 'common.json' }
> { 'include': 'sockets.json' }
> { 'include': 'run-state.json' }
Any reason why error.json is needed before common.json? But I don't see
it as being a problem, so
Reviewed-by: Eric Blake <[email protected]>
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3226
Virtualization: qemu.org | libvirt.org
signature.asc
Description: OpenPGP digital signature
