On Wed, 2011-03-02 at 14:56 +0000, $BCzJ]ya(B wrote:
> Hi all,
> As we know, we package the privcmd, evtchn, gntdev,etc, IOCTL
> interface to implement libxc, are there any docs about how to
> implement libxl? It says libxl relies on libxc, libxenguest, xenstore,
> etc, to
> implement them, then why is libxl faster than libxc sometimes?(for
> example, "xl list" and "xm list") .
You aren't really comparing apples to apples here and the relationship
between libxc and libxl is not what you appear to think it is.
Perhaps it will help to describe the various components:
libxc is a low-level library which contains e.g. thin wrappers for
making hypercalls, the internal mechanics of save/restore etc.
libxl is implemented using libxc (as well as libxenstore and some
others) and provides a higher level interface for toolstack authors, it
contains e.g. functions to create and build entire domains, functions to
add a network device to a domain etc.
xend is a toolstack daemon implemented using python bindings to libxc
(as well as libxenstore and some others). In the future we hope it will
switch to using python bindings to libxl instead as libxl is intended to
be a common library for all toolstacks. xend provides an RPC interface
which allows you to build entire domains, add network devices to a
domain, fully manage domain lifecycles etc.
xm is a command line interface to xend, e.g. it makes RPC calls to xend
in order to do the things described above.
xl is a lightweight toolstack implemented in C using libxl. It is
intended as a drop in replacement for the xm interface to xend.
So xl is a lightweight toolstack which performs things like "xl list"
pretty directly via libxl, whereas xm is a interface to an RPC mechanism
to a toolstack daemon which is why "xm list" is not going to be as fast
as "xl list".
For completeness: xapi, the XCP toolstack, is a toolstack daemon
implemented largely in ocaml using the ocaml bindings to libxc (as well
as libxenstore and some others etc). In the future we hope it will
switch to using ocaml bindings to libxl instead as libxl is intended to
be a common library for all toolstacks. xapi provides the XenAPI RPC
interface (different to the xend RPC interface) which allows you to
build entire domains, add network devices to a domain, fully manage
domain lifecycles etc.
xe is the command line interface to XenAPI, e.g. it mapes RPC calls to
xapi etc etc.
Ian.
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|