Skip to content

V3DRender 0.15

Choose a tag to compare

@adyoull adyoull released this 16 Nov 16:03
· 25 commits to main since this release

V3DRender 0.15

A native RISC OS driver for the Raspberry Pi 4's GPU (Broadcom V3D 4.2), following Linux's v3d driver. Programs reach it through RISC3D.

This release is about speed in real programs. YSFlight's log showed it spent most of each frame in V3DRender's CPU cache work rather than on the GPU. 0.15 cuts that work. It includes 0.14 and 0.13 (0.13 was tagged but not published).

New in 0.15

  • Big buffers' cache work done by the whole cache. A program's window picture imported into the GPU's address space, or a cached buffer, had its CPU cache lines cleaned before every job and invalidated after it, line by line. That is hundreds of thousands of lines for a large window, several times a frame. Above the kernel's own threshold, V3DRender now uses the kernel's whole-cache routines (Cache_CleanAll, Cache_CleanInvalidateAll).
  • Invalidated once its last job is done: a buffer that more queued jobs will write is invalidated after the last of them, not after each one.
  • *V3DRender shows the cache work: cleans, invalidates, how many were put off, CPU time, and whole-cache counts.

New in 0.14

  • After a job, cached and imported buffers are cleaned and invalidated, not only invalidated. This is safe for a cached screen that other programs draw on meanwhile.
  • *V3DRender shows the ARM's clock and the firmware's maximum for it.

New in 0.13

  • Uncached imports: DRM_RISCOS_IMPORT_UNCACHED for screen memory and screen banks skips the cache work altogether.
  • Big pages, as Linux: buffers of 64 KB and 1 MB or more are aligned so that the GPU's MMU uses 64 KB and 1 MB entries.
  • GPU time per program: DRM_IOCTL_RISCOS_FILE_STATS, and totals in *V3DRender.
  • After a hang, only the guilty job fails; jobs on the other queues run again, as Linux does.
  • Refuses to start where there's no V3D 4.2, touching nothing else. RISC3D's package carries it to every machine.

See CHANGELOG.md for the details.

Status

  • 0.13 passed the full test kit on a Pi 4.
  • 0.15 runs ClassiCube and YSFlight on the Pi; its own kit (17) is the same as 0.13's plus the timing of CPU writes.
  • Programs now spend most of each frame outside the GPU: in the game, in Mesa, and in showing the frame on one CPU core. That work continues in riscos-mesa.

Downloads

  • V3DRender-0.15.zip: the module, with its licence.
  • V3DRenderTest-17.zip: the test kit. Run Check, then read Results.

Requirements

  • A Raspberry Pi 4, Pi 400 or CM4 with RISC OS 5.30 or later.
  • RISC3D 0.03 or later. Programs reach the GPU through RISC3D only.
  • Rob Heaton's V3DDriver not loaded.

The SWI chunk (&C3D40) and error block (&81D340) are provisional.

Licence

GNU GPL version 2 or later, as the Linux v3d driver it follows. See NOTICE.