#6818·ncnn

YOLOv8 detection results on Mali-G720 Vulkan GPU (CPU results are correct)

Author: taiji1985Created Jul 12, 2026Updated Sep 15, 2026

Inaccurate YOLOv8 detection results on Mali-G720 Vulkan GPU (CPU results are correct)

Environment

  • Device: Xiaomi M531DA
  • SoC: MediaTek MT6899
  • GPU: ARM Mali-G720 MC8
  • Vulkan: ro.hardware.vulkan=mali
  • GLES: OpenGL ES 3.2 (Mali-G720 MC8, driver v1.r49p1-...)
  • OS: Android 16
  • App ABI: arm64-v8a
  • Model: YOLOv8 (ncnn, 640 input)
  • Task: Object detection (localization)

ncnn GPU device info (from logcat)

W/ncnn: [0 Mali-G720 MC8]  queueC=0[2]  queueG=0[2]  queueT=0[2]
W/ncnn: [0 Mali-G720 MC8]  bugsbn1=0  bugbilz=0  bugcopc=0  bugihfa=0
W/ncnn: [0 Mali-G720 MC8]  fp16-p/s/u/a=1/1/1/1  int8-p/s/u/a=1/1/1/1
W/ncnn: [0 Mali-G720 MC8]  subgroup=16(16~16)  ops=1/1/1/1/1/1/1/1/1/1
W/ncnn: [0 Mali-G720 MC8]  fp16-8x8x16/16x8x8/16x8x16/16x16x16=0/0/0/0
Vulkan initialization succeeds. Model load succeeds. Inference runs without crash.

Options used
ncnn::Option opt;
opt.lightmode = true;
opt.num_threads = 4;
opt.use_packing_layout = true;
opt.use_vulkan_compute = true;  // when useGPU=true
No custom FP16 flags are set beyond ncnn defaults.

Symptom
With use_vulkan_compute = true (GPU): YOLOv8 detection boxes / localization are inaccurate (wrong boxes, missed objects, or shifted results).
With use_vulkan_compute = false (CPU): same model + same preprocessing produces correct results.
There is no hard Vulkan / ncnn error in logcat during init or inference (no VkResult failures, no shader/pipeline errors, no E/ncnn). Detection is continuously invoked (~0.8–1.1s interval) and completes normally.

So this looks like a silent numerical / precision mismatch on Mali Vulkan (possibly FP16-related), not a failed GPU path.

What we already checked
GPU is actually selected (USE GPU logged).
Model init succeeds on GPU path.
Inference keeps running; app does not crash.
Forcing CPU restores accuracy.
Questions
Is inaccurate YOLOv8 output on Mali-G720 / MediaTek MT6899 a known Vulkan issue?
Are there recommended ncnn::Option settings for Mali (e.g. disable FP16 storage/arithmetic / packing) to improve numerical stability for detection models?
Any known driver bugs or ncnn GPU bug flags we should force for Mali-G720?
Workaround
Disable Vulkan compute and run on CPU (use_vulkan_compute = false). Accuracy is restored, at the cost of performance.