Command line

warm-system-aarch64

The command line that builds a machine: qemu-system-aarch64's from QEMU 11.1.1, for its virt machine, with the few differences and additions listed here.

warm-system-aarch64 takes the same command line as QEMU 11.1.1's qemu-system-aarch64 does for the virt machine. That means the same options and sub-options, the same defaults, the same error messages for a line it can't accept, and the same exit status. The same line works in a shell and in WARM.launch(), which takes it as one string or as an argv array.

warm-system-aarch64 -M virt -cpu cortex-a76 -m 1G -kernel vmlinuz-virt -initrd initramfs-virt \
  -append "console=ttyAMA0 root=/dev/vda rw" -drive file=rootfs.img,if=virtio -nographic

The options

Every option is described in QEMU's documentation:

QEMU's online documentation follows its newest release, while Warm64 follows 11.1.1. The program's own listings match it exactly:

CommandLists
warm-system-aarch64 -helpEvery option, as QEMU 11.1.1's -help prints it.
-device help, -device DRIVER,helpThe devices, and one device's properties.
-M help, -M virt,helpThe machines, and the virt machine's properties.
-cpu helpThe CPU models.
-accel help, -display help, -audiodev help, -netdev help, -object help, -chardev helpThe backends of each kind.

The listings go to standard output, and the command exits with status 0, as QEMU's does.

Differences from QEMU

WARM
MachinesOnly virt, in its versions virt-5.2 to virt-11.1 (virt means virt-11.1). -M help lists QEMU's other boards, and naming one gets machine type 'NAME' is not emulated by this program (virt is).
AcceleratorsThe emulated CPU, tcg, and Warm64's own wapi (see Warm64's additions). -accel hvf with a CPU the hypervisor accepts (-cpu host or max) gets the hypervisor is not available here (the CPU is emulated, as with -accel tcg); with a named model, it gets QEMU's Invalid CPU model first. -accel kvm gets QEMU's invalid accelerator kvm, as with QEMU on macOS, and -cpu host on its own gets QEMU's Invalid CPU model: host.
apple-gfx-pciRefused with 'apple-gfx-pci' is not a valid device model name. QEMU's macOS build runs it through a macOS framework that browsers and Node don't have.
NamesThe program and its tools say WARM where QEMU says QEMU: -version prints WARM emulator version 1.0.0 (QEMU 11.1.1), the monitor opens with WARM 1.0.0 (QEMU 11.1.1) monitor at a (warm) prompt, and the image tool is warm-img. QMP's query-version reports QEMU 11.1.1, as QEMU's does.

Warm64's additions

A few options and values are Warm64's own, alongside QEMU's:

OptionDescription
-accel wapiWarm64's own accelerator. The CPU is emulated as with tcg, but the machine uses the web platform's APIs, so a 3D display is drawn with the host's GPU through WebGPU or WebGL2. With tcg, QEMU's default, a 3D display is drawn in software. wapi takes no properties: -accel wapi,thread=multi gets Property 'wapi-accel.thread' not found. See What renders it.
-wapi API[,API...]With -accel wapi, the web APIs the machine may use: threads (shared memory, for more than one core), memory64 (64-bit memory, for more than about 1.5 GiB of RAM), webgpu and webgl2 (renderers for a 3D display), and workers (the GPU's render workers). Without -wapi, it may use every one the host has. A machine that needs an API you left out is refused: -smp 2 without threads gets -wapi: -smp 2 needs the threads API (shared memory), and -m 2G without memory64 gets -wapi: 2048 MiB of RAM needs the memory64 API. -wapi help lists them, and without -accel wapi, -wapi gets -wapi: needs -accel wapi (the accelerator is tcg).
-drive file=wision:installer,if=virtioAttaches the installer for wision, Warm64's 3D guest driver, as a read-only disk. See Installing wision.
-netdev user,…,wision=onAlso answers to the name wision on the guest's network and serves the wision installer there.
-netdev socket,id=ID,connect=ws://HOST:PORTJoins an Ethernet hub of guests over a WebSocket (ws:// or wss://), such as examples/net/relay-hub.mjs in the Warm64 repository. QEMU's own socket forms (listen=, connect=HOST:PORT, mcast=, udp=, fd=) work as they do in QEMU. See Networking.
-device virtio-gpu-pci,refresh_rate=MHZThe refresh rate of the display mode offered to the guest, in millihertz (60000 for 60 Hz); the default is 75 Hz, as in QEMU's EDID. It works on virtio-gpu-gl-pci too. QEMU 11.1.1's devices have no such property.
-icount …,x-elastic=on|off, x-elastic-cap=MSWith -icount, the guest's clock stretches while its cores are busy, so animations show every frame, and catches up when the guest is idle. It falls at most x-elastic-cap milliseconds behind the host's clock (500 by default). x-elastic=off keeps the host's time. See Smooth animations.

In Node and in a browser

What QEMU gets from the computer it runs on (files, sockets, a window, a sound card), Warm64 gets from the host you launch the machine with.

  • In a shell, warm-system-aarch64 runs on Node with nodeWARMHost(), which provides files, real sockets, the terminal, and the Mac's sound output for -audiodev coreaudio. -display cocoa, the default display as with QEMU on macOS, opens the machine's window as a page in your default browser. -display curses draws it in the terminal, and -nographic puts the serial console and the monitor on the terminal.
  • In a web page, browserWARMHost() fetches files by URL, carries TCP through a relay, draws the display on the canvas you give it, and plays sound through Web Audio.

When a host lacks what an option needs, WARM says so and names the WARMHost member that would provide it. A TAP, bridge or stream netdev in a web page is refused (this platform has no sockets for a tap netdev (WARMHost.netSockets)), and an -audiodev with no sound output gets a warning (this platform has no sound output (WARMHost.audio); the sound is dropped).

Exit status

StatusWhen
0quit, Ctrl+A x, the guest powered off, -help, -version and the help listings.
1The command line was refused, the machine couldn't start, or the guest panicked with -action panic=exit-failure.

See also