diff --git a/.github/workflows/macos-vulkan-research.yml b/.github/workflows/macos-vulkan-research.yml index adea87de5..e0d1d4f26 100644 --- a/.github/workflows/macos-vulkan-research.yml +++ b/.github/workflows/macos-vulkan-research.yml @@ -1,6 +1,11 @@ name: macOS Vulkan research on: workflow_dispatch: + inputs: + world: + description: Create or open disposable demo worlds instead of title probes + type: boolean + default: false permissions: contents: read jobs: @@ -18,15 +23,19 @@ jobs: - name: Build original mod and private probe dependencies run: python tools/build_mod.py - name: Probe vanilla, core and distant-terrain Vulkan cases + env: + HORIZON_GRAPHICS_WORLD: ${{ inputs.world }} run: | python - <<'PY' - import json, subprocess, sys + import json, os, subprocess, sys from pathlib import Path cases = [ ['--profile', 'baseline', '--backend', 'vulkan'], ['--profile', 'core-performance', '--backend', 'vulkan'], ['--profile', 'vulkan'], ] + if os.environ.get('HORIZON_GRAPHICS_WORLD') == 'true': + cases = [case + ['--world'] for case in cases] observations = [] for case in cases: result = subprocess.run([sys.executable, 'tools/test_client_graphics.py', '--native-display', *case], capture_output=True, text=True) diff --git a/benchmarks/mac-vulkan-2026-10-04/live-observations.json b/benchmarks/mac-vulkan-2026-10-04/live-observations.json new file mode 100644 index 000000000..1868ebde2 --- /dev/null +++ b/benchmarks/mac-vulkan-2026-10-04/live-observations.json @@ -0,0 +1,930 @@ +{ + "schema": 1, + "measurement": "Failed hosted macOS Vulkan graphics probes, not performance measurements", + "source_commit": "8282a731ecc08691f798a3ec596c7cc1d4f1dad1", + "run_url": "https://github.com/ludovic111/minecraft-optimization-lab/actions/runs/37193558884", + "original_mod_sha256": "e651ef49bc97486e8dacfd4b640465c442525cd645e2dba71ddea9fb64347dd8", + "cases": [ + { + "case": [ + "--profile", + "baseline", + "--backend", + "vulkan" + ], + "exit_code": 1, + "failure": [ + { + "exit_code": 1, + "result_count": 0, + "java_exception_types": [ + "java.lang.AssertionError", + "java.lang.RuntimeException" + ], + "expected_demo_authentication_errors_observed": true, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ], + "created_devices": [ + { + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2" + } + ], + "client_initializer_reached": true, + "readback_requested": true, + "vulkan_error_codes": [ + "VK_ERROR_FEATURE_NOT_PRESENT" + ], + "fatal_jvm_error": false, + "profile": "baseline", + "preferred_backend": "vulkan" + } + ] + }, + { + "case": [ + "--profile", + "core-performance", + "--backend", + "vulkan" + ], + "exit_code": 1, + "failure": [ + { + "exit_code": 1, + "result_count": 0, + "java_exception_types": [ + "java.lang.AssertionError", + "java.lang.RuntimeException" + ], + "expected_demo_authentication_errors_observed": true, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ], + "created_devices": [ + { + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2" + } + ], + "client_initializer_reached": true, + "readback_requested": true, + "vulkan_error_codes": [ + "VK_ERROR_FEATURE_NOT_PRESENT" + ], + "fatal_jvm_error": false, + "profile": "core-performance", + "preferred_backend": "vulkan" + } + ] + }, + { + "case": [ + "--profile", + "vulkan" + ], + "exit_code": 1, + "failure": [ + { + "exit_code": 1, + "result_count": 0, + "java_exception_types": [ + "java.lang.AssertionError", + "java.lang.RuntimeException" + ], + "expected_demo_authentication_errors_observed": true, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ], + "created_devices": [ + { + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2" + } + ], + "client_initializer_reached": true, + "readback_requested": true, + "vulkan_error_codes": [ + "VK_ERROR_FEATURE_NOT_PRESENT" + ], + "fatal_jvm_error": false, + "profile": "vulkan", + "preferred_backend": "vulkan" + } + ] + } + ], + "limits": [ + "Apple Paravirtual device and MoltenVK on a hosted ARM Mac; not physical M2 Pro GPU testing.", + "Library/device creation and readback request were observed, but no completed nonuniform readback report was produced.", + "All failures retained; neither successful rendering nor a screenshot-specific root cause is established.", + "Baseline includes the same original measurement mod and private test fixture; no core optimization mods or distant terrain.", + "Full logs, screenshots, game binaries and assets remain private.", + "Later selected stack locations place the observed failures in the screenshot callback; the independently logged Vulkan identifier is not established as their cause.", + "Actual assertions rejected uniform callback images in all three cases. Overlay state was not recorded, and displayed-window correctness is not established.", + "After guarding overlays, core/distant-terrain title readbacks pass but vanilla remains uniform; the aggregate research run fails. No world-rendering or physical-M2 claim.", + "Later world probes pass all three Vulkan cases on the hosted Mac; failed title cases remain retained. These are short startup/readback/save probes, not physical-GPU performance tests." + ], + "later_stack_run": { + "source_commit": "a77476b54e7bf4a1b3a96cb9d8108ed7c1c7b2b0", + "run_url": "https://github.com/ludovic111/minecraft-optimization-lab/actions/runs/37193954843", + "cases": [ + { + "case": [ + "--profile", + "baseline", + "--backend", + "vulkan" + ], + "exit_code": 1, + "failure": [ + { + "exit_code": 1, + "result_count": 0, + "java_exception_types": [ + "java.lang.AssertionError", + "java.lang.RuntimeException" + ], + "expected_demo_authentication_errors_observed": true, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ], + "created_devices": [ + { + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2" + } + ], + "client_initializer_reached": true, + "readback_requested": true, + "vulkan_error_codes": [ + "VK_ERROR_FEATURE_NOT_PRESENT" + ], + "fatal_jvm_error": false, + "observed_graphics_stack_methods": [ + "net.minecraft.client.Screenshot.lambda$takeScreenshot$1", + "com.mojang.renderpearl.backend.vulkan.DestructionQueue.rotate", + "com.mojang.renderpearl.backend.vulkan.VulkanCommandEncoder.submit", + "com.mojang.renderpearl.frontend.FrontendCommandEncoder.submit" + ], + "profile": "baseline", + "preferred_backend": "vulkan" + } + ] + }, + { + "case": [ + "--profile", + "core-performance", + "--backend", + "vulkan" + ], + "exit_code": 1, + "failure": [ + { + "exit_code": 1, + "result_count": 0, + "java_exception_types": [ + "java.lang.AssertionError", + "java.lang.RuntimeException" + ], + "expected_demo_authentication_errors_observed": true, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ], + "created_devices": [ + { + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2" + } + ], + "client_initializer_reached": true, + "readback_requested": true, + "vulkan_error_codes": [ + "VK_ERROR_FEATURE_NOT_PRESENT" + ], + "fatal_jvm_error": false, + "observed_graphics_stack_methods": [ + "net.minecraft.client.Screenshot.lambda$takeScreenshot$1", + "com.mojang.renderpearl.backend.vulkan.DestructionQueue.rotate", + "com.mojang.renderpearl.backend.vulkan.VulkanCommandEncoder.submit", + "com.mojang.renderpearl.frontend.FrontendCommandEncoder.submit" + ], + "profile": "core-performance", + "preferred_backend": "vulkan" + } + ] + }, + { + "case": [ + "--profile", + "vulkan" + ], + "exit_code": 1, + "failure": [ + { + "exit_code": 1, + "result_count": 0, + "java_exception_types": [ + "java.lang.AssertionError", + "java.lang.RuntimeException" + ], + "expected_demo_authentication_errors_observed": true, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ], + "created_devices": [ + { + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2" + } + ], + "client_initializer_reached": true, + "readback_requested": true, + "vulkan_error_codes": [ + "VK_ERROR_FEATURE_NOT_PRESENT" + ], + "fatal_jvm_error": false, + "observed_graphics_stack_methods": [ + "net.minecraft.client.Screenshot.lambda$takeScreenshot$1", + "com.mojang.renderpearl.backend.vulkan.DestructionQueue.rotate", + "com.mojang.renderpearl.backend.vulkan.VulkanCommandEncoder.submit", + "com.mojang.renderpearl.frontend.FrontendCommandEncoder.submit" + ], + "profile": "vulkan", + "preferred_backend": "vulkan" + } + ] + } + ] + }, + "later_pixel_run": { + "source_commit": "213498c77ed643617083dacf4aaa283a1cb4815a", + "run_url": "https://github.com/ludovic111/minecraft-optimization-lab/actions/runs/37194354615", + "cases": [ + { + "case": [ + "--profile", + "baseline", + "--backend", + "vulkan" + ], + "exit_code": 1, + "failure": [ + { + "exit_code": 1, + "result_count": 0, + "java_exception_types": [ + "java.lang.AssertionError", + "java.lang.RuntimeException" + ], + "expected_demo_authentication_errors_observed": true, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ], + "created_devices": [ + { + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2" + } + ], + "client_initializer_reached": true, + "readback_requested": true, + "readback_callback_received": true, + "readback_inspections": [ + { + "framebuffer_width": 1280, + "framebuffer_height": 646, + "sampled_pixels": 4160, + "distinct_sampled_rgb": 1 + } + ], + "probe_failure_categories": [ + "uniform_readback" + ], + "vulkan_error_codes": [ + "VK_ERROR_FEATURE_NOT_PRESENT" + ], + "fatal_jvm_error": false, + "observed_graphics_stack_methods": [ + "net.minecraft.client.Screenshot.lambda$takeScreenshot$1", + "com.mojang.renderpearl.backend.vulkan.DestructionQueue.rotate", + "com.mojang.renderpearl.backend.vulkan.VulkanCommandEncoder.submit", + "com.mojang.renderpearl.frontend.FrontendCommandEncoder.submit" + ], + "profile": "baseline", + "preferred_backend": "vulkan" + } + ] + }, + { + "case": [ + "--profile", + "core-performance", + "--backend", + "vulkan" + ], + "exit_code": 1, + "failure": [ + { + "exit_code": 1, + "result_count": 0, + "java_exception_types": [ + "java.lang.AssertionError", + "java.lang.RuntimeException" + ], + "expected_demo_authentication_errors_observed": true, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ], + "created_devices": [ + { + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2" + } + ], + "client_initializer_reached": true, + "readback_requested": true, + "readback_callback_received": true, + "readback_inspections": [ + { + "framebuffer_width": 1280, + "framebuffer_height": 646, + "sampled_pixels": 4160, + "distinct_sampled_rgb": 1 + } + ], + "probe_failure_categories": [ + "uniform_readback" + ], + "vulkan_error_codes": [ + "VK_ERROR_FEATURE_NOT_PRESENT" + ], + "fatal_jvm_error": false, + "observed_graphics_stack_methods": [ + "net.minecraft.client.Screenshot.lambda$takeScreenshot$1", + "com.mojang.renderpearl.backend.vulkan.DestructionQueue.rotate", + "com.mojang.renderpearl.backend.vulkan.VulkanCommandEncoder.submit", + "com.mojang.renderpearl.frontend.FrontendCommandEncoder.submit" + ], + "profile": "core-performance", + "preferred_backend": "vulkan" + } + ] + }, + { + "case": [ + "--profile", + "vulkan" + ], + "exit_code": 1, + "failure": [ + { + "exit_code": 1, + "result_count": 0, + "java_exception_types": [ + "java.lang.AssertionError", + "java.lang.RuntimeException" + ], + "expected_demo_authentication_errors_observed": true, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ], + "created_devices": [ + { + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2" + } + ], + "client_initializer_reached": true, + "readback_requested": true, + "readback_callback_received": true, + "readback_inspections": [ + { + "framebuffer_width": 1280, + "framebuffer_height": 646, + "sampled_pixels": 4160, + "distinct_sampled_rgb": 1 + } + ], + "probe_failure_categories": [ + "uniform_readback" + ], + "vulkan_error_codes": [ + "VK_ERROR_FEATURE_NOT_PRESENT" + ], + "fatal_jvm_error": false, + "observed_graphics_stack_methods": [ + "net.minecraft.client.Screenshot.lambda$takeScreenshot$1", + "com.mojang.renderpearl.backend.vulkan.DestructionQueue.rotate", + "com.mojang.renderpearl.backend.vulkan.VulkanCommandEncoder.submit", + "com.mojang.renderpearl.frontend.FrontendCommandEncoder.submit" + ], + "profile": "vulkan", + "preferred_backend": "vulkan" + } + ] + } + ] + }, + "later_overlay_run": { + "source_commit": "a1d8c1b8246008ac4076cdcaf0f64c71eaf4c767", + "run_url": "https://github.com/ludovic111/minecraft-optimization-lab/actions/runs/37194690645", + "cases": [ + { + "case": [ + "--profile", + "baseline", + "--backend", + "vulkan" + ], + "exit_code": 1, + "failure": [ + { + "exit_code": 1, + "result_count": 0, + "java_exception_types": [ + "java.lang.AssertionError", + "java.lang.RuntimeException" + ], + "expected_demo_authentication_errors_observed": true, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ], + "created_devices": [ + { + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2" + } + ], + "client_initializer_reached": true, + "readback_requested": true, + "readback_callback_received": true, + "readback_inspections": [ + { + "framebuffer_width": 1280, + "framebuffer_height": 646, + "sampled_pixels": 4160, + "distinct_sampled_rgb": 1 + } + ], + "probe_failure_categories": [ + "uniform_readback" + ], + "vulkan_error_codes": [ + "VK_ERROR_FEATURE_NOT_PRESENT" + ], + "fatal_jvm_error": false, + "observed_graphics_stack_methods": [ + "net.minecraft.client.Screenshot.lambda$takeScreenshot$1", + "com.mojang.renderpearl.backend.vulkan.DestructionQueue.rotate", + "com.mojang.renderpearl.backend.vulkan.VulkanCommandEncoder.submit", + "com.mojang.renderpearl.frontend.FrontendCommandEncoder.submit" + ], + "profile": "baseline", + "preferred_backend": "vulkan" + } + ] + }, + { + "case": [ + "--profile", + "core-performance", + "--backend", + "vulkan" + ], + "exit_code": 0, + "report": { + "schema": 1, + "platform": "macOS-26.6.2-arm64-arm-64bit", + "architecture": "arm64", + "minecraft": "26.3", + "original_mod_sha256": "e651ef49bc97486e8dacfd4b640465c442525cd645e2dba71ddea9fb64347dd8", + "results": [ + { + "observed_mode": "title", + "title_screen_observed": true, + "world_loaded": false, + "ready_client_ticks": 42, + "window_active": true, + "overlay_present": false, + "overlay_wait_ticks": 105, + "framebuffer_width": 1280, + "framebuffer_height": 646, + "sampled_pixels": 4160, + "distinct_sampled_rgb": 163, + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2", + "private_png_sha256": "3c802923766cf9e7f45020bc2d858c23de655cb8e35fa058a050e7b09a1d3708", + "profile": "core-performance", + "preferred_backend": "vulkan", + "launcher_exit_code": 0, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ] + } + ], + "limits": [ + "Short scene startup and nonuniform framebuffer readback only.", + "World mode uses the ordinary limited demo; world files remain private.", + "No exhaustive gameplay, visual-correctness, FPS or M2 Pro performance claim.", + "Vulkan preference can fall back; inspect the observed backend.", + "PNG images, assets and full logs remain in the private runtime directory." + ] + } + }, + { + "case": [ + "--profile", + "vulkan" + ], + "exit_code": 0, + "report": { + "schema": 1, + "platform": "macOS-26.6.2-arm64-arm-64bit", + "architecture": "arm64", + "minecraft": "26.3", + "original_mod_sha256": "e651ef49bc97486e8dacfd4b640465c442525cd645e2dba71ddea9fb64347dd8", + "results": [ + { + "observed_mode": "title", + "title_screen_observed": true, + "world_loaded": false, + "ready_client_ticks": 42, + "window_active": true, + "overlay_present": false, + "overlay_wait_ticks": 122, + "framebuffer_width": 1280, + "framebuffer_height": 646, + "sampled_pixels": 4160, + "distinct_sampled_rgb": 163, + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2", + "private_png_sha256": "3c802923766cf9e7f45020bc2d858c23de655cb8e35fa058a050e7b09a1d3708", + "profile": "vulkan", + "preferred_backend": "vulkan", + "launcher_exit_code": 0, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ] + } + ], + "limits": [ + "Short scene startup and nonuniform framebuffer readback only.", + "World mode uses the ordinary limited demo; world files remain private.", + "No exhaustive gameplay, visual-correctness, FPS or M2 Pro performance claim.", + "Vulkan preference can fall back; inspect the observed backend.", + "PNG images, assets and full logs remain in the private runtime directory." + ] + } + } + ] + }, + "later_world_run": { + "source_commit": "5f9f973295c5cc948a6999a849c2c843f5e831f6", + "run_url": "https://github.com/ludovic111/minecraft-optimization-lab/actions/runs/37195149166", + "cases": [ + { + "case": [ + "--profile", + "baseline", + "--backend", + "vulkan", + "--world" + ], + "exit_code": 0, + "report": { + "schema": 1, + "platform": "macOS-26.6.2-arm64-arm-64bit", + "architecture": "arm64", + "minecraft": "26.3", + "original_mod_sha256": "e651ef49bc97486e8dacfd4b640465c442525cd645e2dba71ddea9fb64347dd8", + "results": [ + { + "observed_mode": "world", + "title_screen_observed": false, + "world_loaded": true, + "ready_client_ticks": 42, + "window_active": true, + "overlay_present": false, + "overlay_wait_ticks": 323, + "framebuffer_width": 1280, + "framebuffer_height": 646, + "sampled_pixels": 4160, + "distinct_sampled_rgb": 1278, + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2", + "private_png_sha256": "9e9be2562390f24fe8c8e0442ef9cdfd47910febd95d8f0c0f5706191a53f1f6", + "profile": "baseline", + "preferred_backend": "vulkan", + "launcher_exit_code": 0, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ] + } + ], + "limits": [ + "Short scene startup and nonuniform framebuffer readback only.", + "World mode uses the ordinary limited demo; world files remain private.", + "No exhaustive gameplay, visual-correctness, FPS or M2 Pro performance claim.", + "Vulkan preference can fall back; inspect the observed backend.", + "PNG images, assets and full logs remain in the private runtime directory." + ] + } + }, + { + "case": [ + "--profile", + "core-performance", + "--backend", + "vulkan", + "--world" + ], + "exit_code": 0, + "report": { + "schema": 1, + "platform": "macOS-26.6.2-arm64-arm-64bit", + "architecture": "arm64", + "minecraft": "26.3", + "original_mod_sha256": "e651ef49bc97486e8dacfd4b640465c442525cd645e2dba71ddea9fb64347dd8", + "results": [ + { + "observed_mode": "world", + "title_screen_observed": false, + "world_loaded": true, + "ready_client_ticks": 51, + "window_active": true, + "overlay_present": false, + "overlay_wait_ticks": 90, + "framebuffer_width": 1280, + "framebuffer_height": 646, + "sampled_pixels": 4160, + "distinct_sampled_rgb": 1024, + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2", + "private_png_sha256": "e0a6ad253ca0490b35217ce9ad799dc7d4c04e4ecf446eeacd1aa5196db317bb", + "profile": "core-performance", + "preferred_backend": "vulkan", + "launcher_exit_code": 0, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ] + } + ], + "limits": [ + "Short scene startup and nonuniform framebuffer readback only.", + "World mode uses the ordinary limited demo; world files remain private.", + "No exhaustive gameplay, visual-correctness, FPS or M2 Pro performance claim.", + "Vulkan preference can fall back; inspect the observed backend.", + "PNG images, assets and full logs remain in the private runtime directory." + ] + } + }, + { + "case": [ + "--profile", + "vulkan", + "--world" + ], + "exit_code": 0, + "report": { + "schema": 1, + "platform": "macOS-26.6.2-arm64-arm-64bit", + "architecture": "arm64", + "minecraft": "26.3", + "original_mod_sha256": "e651ef49bc97486e8dacfd4b640465c442525cd645e2dba71ddea9fb64347dd8", + "results": [ + { + "observed_mode": "world", + "title_screen_observed": false, + "world_loaded": true, + "ready_client_ticks": 53, + "window_active": true, + "overlay_present": false, + "overlay_wait_ticks": 88, + "framebuffer_width": 1280, + "framebuffer_height": 646, + "sampled_pixels": 4160, + "distinct_sampled_rgb": 1287, + "gpu": "Apple Paravirtual device", + "graphics_backend": "Vulkan", + "graphics_driver": "1.2.350 MoltenVK 1.4.2", + "private_png_sha256": "a17d1740e34cc9f49b67a4c56f51d0843f756e9d2eb3d19d6a926ad5f8f0ed36", + "profile": "vulkan", + "preferred_backend": "vulkan", + "launcher_exit_code": 0, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ] + } + ], + "limits": [ + "Short scene startup and nonuniform framebuffer readback only.", + "World mode uses the ordinary limited demo; world files remain private.", + "No exhaustive gameplay, visual-correctness, FPS or M2 Pro performance claim.", + "Vulkan preference can fall back; inspect the observed backend.", + "PNG images, assets and full logs remain in the private runtime directory." + ] + } + } + ] + }, + "local_linux_core_vulkan_world": { + "schema": 1, + "platform": "Linux-7.0.0-31-generic-x86_64-with-glibc2.43", + "architecture": "x86_64", + "minecraft": "26.3", + "original_mod_sha256": "e651ef49bc97486e8dacfd4b640465c442525cd645e2dba71ddea9fb64347dd8", + "results": [ + { + "observed_mode": "world", + "title_screen_observed": false, + "world_loaded": true, + "ready_client_ticks": 47, + "window_active": true, + "overlay_present": false, + "overlay_wait_ticks": 111, + "framebuffer_width": 1280, + "framebuffer_height": 800, + "sampled_pixels": 4288, + "distinct_sampled_rgb": 1895, + "gpu": "llvmpipe (LLVM 21.1.8, 256 bits)", + "graphics_backend": "Vulkan", + "graphics_driver": "1.4.335 llvmpipe Mesa 26.0.8-1ubuntu0.3 (LLVM 21.1.8)", + "private_png_sha256": "52b26102b3037cab4ab6b7011a6c1255eebaa808d1d3dd5e77ff23fcde092acb", + "profile": "core-performance", + "preferred_backend": "vulkan", + "launcher_exit_code": 0, + "backend_attempts": [ + { + "backend": "Vulkan", + "operation": "load_library", + "result": "success" + }, + { + "backend": "Vulkan", + "operation": "create_device", + "result": "success" + } + ] + } + ], + "limits": [ + "Short scene startup and nonuniform framebuffer readback only.", + "World mode uses the ordinary limited demo; world files remain private.", + "No exhaustive gameplay, visual-correctness, FPS or M2 Pro performance claim.", + "Vulkan preference can fall back; inspect the observed backend.", + "PNG images, assets and full logs remain in the private runtime directory." + ] + } +} diff --git a/docs/client-graphics-smoke.md b/docs/client-graphics-smoke.md index 740f9dab9..7367cfaab 100644 --- a/docs/client-graphics-smoke.md +++ b/docs/client-graphics-smoke.md @@ -10,13 +10,18 @@ The required macOS CI cases use the recommended OpenGL `core-performance` and separate instance, creates or opens an ordinary limited-demo world. World mode dismisses the demo-help popup, waits for focused, unpaused gameplay, reads back the main render target, and stops the client so its integrated server saves. -Private screenshots must have a nonuniform sample grid and a verified file hash; +The readiness counter resets while a loading overlay is present: a title screen +object can already exist underneath asynchronous loading. Private screenshots +must have a nonuniform sample grid and a verified file hash; world mode also checks for saved world data after a clean process exit. The startup wrapper observes backend library/device creation and preserves the original calls and thrown exceptions. Selected diagnostics contain initialization stages, bounded exception type names, Vulkan error-code identifiers and device -labels. Expected demo authentication errors are reported separately. Full log +labels. Failed probes also select up to eight graphics stack method names, without +module prefixes, filenames, line numbers or messages. Those observed locations +do not by themselves identify a root cause. Expected demo authentication errors +are reported separately. Full log messages, raw screenshots, assets and world files stay under gitignored `.local/`. Nonuniform pixels are not proof of correct visuals, full LOD completion or exhaustive gameplay equivalence. @@ -57,14 +62,50 @@ The manual **macOS Vulkan research** workflow separately probes vanilla, core an the distant-terrain Vulkan profile. It runs every case, retains selected successful and failed outcomes, and exits unsuccessfully when a case fails. Its exploratory results do not count as passing the required OpenGL checks. +Its optional `world` input selects disposable demo-world probes for every case; +the default still probes titles. Local Linux software OpenGL/Vulkan title readbacks passed. Early macOS OpenGL title checks for core and balanced also passed with **Apple Software Renderer**. The macOS runner's **Apple Paravirtual device**, using MoltenVK 1.4.2, created Vulkan devices but all three Vulkan cases failed with `VK_ERROR_FEATURE_NOT_PRESENT`. The failure also occurs with vanilla; these observations do not isolate an -optimization-mod fault or prove behavior on a physical M2 GPU. Later diagnostics -identify whether readback was requested before failure. +optimization-mod fault or prove behavior on a physical M2 GPU. + +The separate [readback-stage observations](../benchmarks/mac-vulkan-2026-10-04/live-observations.json) +from manual run 37193558884 show that all three cases reached the client test +initializer and requested readback before failing. They produced no completed +readback report. This narrows the observed sequence; it does not establish whether +the screenshot operation itself or subsequent rendering failed. Graphics stack +locations from the next run, 37193954843, place each observed failure in the +screenshot callback after Vulkan submission. Later probes also record callback +entry, a whitelist of numeric readback dimensions/sample counts, and fixed failure +categories from our own assertions. Separately logged Vulkan codes are not +treated as the cause of a probe assertion. + +Run 37194354615 identifies the actual probe assertion: each callback received a +1280×646 image, but its 4,160 sampled pixels had only one distinct RGB colour. +The strict nonuniform-readback assertion rejected all three cases. Overlay state +was not recorded in those failures; later probes wait for its removal before +counting readiness. This tests an initialization hypothesis while preserving the +same nonuniform-image requirement. It is not evidence that the game's displayed +Vulkan window was uniform or that a physical M2 GPU has the same problem. + +After the overlay guard, run 37194690645 has mixed results: core and distant-terrain +title probes pass on the Apple Paravirtual Vulkan device, with no overlay and +nonuniform readback, then exit cleanly. Vanilla still fails the uniform-readback +assertion. The overall research run therefore remains failed. These outcomes +justify retaining the readiness guard; they do not establish the cause of the +remaining failure, full visual correctness, world rendering or physical M2 speed. + +The subsequent world-mode run 37195149166 passes all three cases on the hosted +Apple Paravirtual Vulkan device. Each reaches focused gameplay without an overlay, +returns a nonuniform framebuffer, produces saved demo-world data and exits with +code zero. This verifies short Vulkan world startup on that runner, while the +failed title observations remain retained. A local Linux core Vulkan world probe +also passes, and its private screenshot was visually inspected. These checks do +not prove exhaustive graphics/gameplay equivalence, completed distant terrain, +physical M2 GPU compatibility or an FPS improvement. For an isolated private preference override: diff --git a/mods/horizon-lab/src/test/java/dev/horizonlab/metrics/ClientGraphicsIntegration.java b/mods/horizon-lab/src/test/java/dev/horizonlab/metrics/ClientGraphicsIntegration.java index 4ec9d35bf..b7c7515e5 100644 --- a/mods/horizon-lab/src/test/java/dev/horizonlab/metrics/ClientGraphicsIntegration.java +++ b/mods/horizon-lab/src/test/java/dev/horizonlab/metrics/ClientGraphicsIntegration.java @@ -22,12 +22,21 @@ public final class ClientGraphicsIntegration implements ClientModInitializer { private int titleTicks; private boolean requested; private boolean opening; + private int overlayWaitTicks; private final boolean worldMode = Files.exists(FabricLoader.getInstance().getConfigDir().resolve("client-graphics-world.flag")); @Override public void onInitializeClient() { System.out.println("HORIZON_CLIENT_GRAPHICS_INITIALIZER_READY"); ClientTickEvents.END_CLIENT_TICK.register(client -> { if (requested) return; + // TitleScreen can exist beneath the asynchronous loading overlay. + // Count readiness only after it clears, for both title and world mode. + if (client.gui.overlay() != null) { + overlayWaitTicks++; + titleStarted = 0; + titleTicks = 0; + return; + } if (worldMode) { if (!opening && client.gui.screen() instanceof TitleScreen screen) { opening = true; @@ -55,6 +64,7 @@ public final class ClientGraphicsIntegration implements ClientModInitializer { requested = true; System.out.println("HORIZON_CLIENT_GRAPHICS_READBACK_REQUESTED"); Screenshot.takeScreenshot(client.gameRenderer.mainRenderTarget(), image -> { + System.out.println("HORIZON_CLIENT_GRAPHICS_READBACK_RECEIVED"); try (image) { int width = image.getWidth(), height = image.getHeight(); if (width < 64 || height < 64) throw new AssertionError("Incomplete title framebuffer"); @@ -66,6 +76,12 @@ public final class ClientGraphicsIntegration implements ClientModInitializer { samples++; } } + var inspection = new JsonObject(); + inspection.addProperty("framebuffer_width", width); + inspection.addProperty("framebuffer_height", height); + inspection.addProperty("sampled_pixels", samples); + inspection.addProperty("distinct_sampled_rgb", colors.size()); + System.out.println("HORIZON_CLIENT_GRAPHICS_READBACK_INSPECTED " + inspection); if (samples < 256 || colors.size() < 8) throw new AssertionError("Uniform title readback"); var screenshot = client.gameDirectory.toPath().resolve("client-graphics-private.png"); image.writeToFile(screenshot); @@ -76,6 +92,8 @@ public final class ClientGraphicsIntegration implements ClientModInitializer { result.addProperty("world_loaded", worldMode && client.level != null); result.addProperty("ready_client_ticks", titleTicks); result.addProperty("window_active", client.isWindowActive()); + result.addProperty("overlay_present", client.gui.overlay() != null); + result.addProperty("overlay_wait_ticks", overlayWaitTicks); result.addProperty("framebuffer_width", width); result.addProperty("framebuffer_height", height); result.addProperty("sampled_pixels", samples); diff --git a/tests/test_fixtures.py b/tests/test_fixtures.py index 4b10553bc..3569f29f6 100644 --- a/tests/test_fixtures.py +++ b/tests/test_fixtures.py @@ -39,6 +39,41 @@ class FixtureDiagnosticTests(unittest.TestCase): 'java_exception_types': ['java.lang.NoClassDefFoundError', 'java.lang.ClassNotFoundException']}) self.assertNotIn('private', json.dumps(report)) + def test_graphics_stack_locations_are_selected_and_bounded(self): + frames = [' at knot//com.mojang.renderpearl.backend.vulkan.Buffer.method%d(PrivateFile.java:42)' % index + for index in range(12)] + output = '\n'.join([ + 'message: at com.mojang.blaze3d.Bad.message(Private.java:1)', + ' at com.mojang.authlib.Auth.privateToken(PrivateFile.java:2)', + ' at net.minecraft.client.Screenshot.takeScreenshot(/private/file.java:3)', + *frames, *frames, + ]) + result = graphics_failure_summary(subprocess.CompletedProcess([], 1, output), 0) + methods = result['observed_graphics_stack_methods'] + self.assertEqual(len(methods), 8) + self.assertEqual(methods[0], 'net.minecraft.client.Screenshot.takeScreenshot') + self.assertEqual(methods[1], 'com.mojang.renderpearl.backend.vulkan.Buffer.method0') + self.assertNotIn('private', json.dumps(result)) + self.assertNotIn('Private', json.dumps(result)) + self.assertNotIn('Bad', json.dumps(result)) + + def test_owned_probe_failure_is_separate_from_logged_vulkan_codes(self): + output = '\n'.join([ + 'logged separately: VK_ERROR_FEATURE_NOT_PRESENT private-message', + 'java.lang.AssertionError: Uniform title readback', + 'HORIZON_CLIENT_GRAPHICS_READBACK_RECEIVED', + 'HORIZON_CLIENT_GRAPHICS_READBACK_INSPECTED {"framebuffer_width":1280,"framebuffer_height":646,"sampled_pixels":4160,"distinct_sampled_rgb":1,"ignored":"private-token"}', + 'HORIZON_CLIENT_GRAPHICS_READBACK_INSPECTED {"framebuffer_width":"private-path"}', + 'HORIZON_CLIENT_GRAPHICS_READBACK_INSPECTED private-malformed', + ]) + result = graphics_failure_summary(subprocess.CompletedProcess([], 1, output), 0) + self.assertEqual(result['probe_failure_categories'], ['uniform_readback']) + self.assertTrue(result['readback_callback_received']) + self.assertEqual(result['readback_inspections'][0]['distinct_sampled_rgb'], 1) + self.assertEqual(len(result['readback_inspections']), 1) + self.assertEqual(result['vulkan_error_codes'], ['VK_ERROR_FEATURE_NOT_PRESENT']) + self.assertNotIn('private', json.dumps(result)) + def test_type_list_and_names_are_bounded(self): output = '\n'.join('Caused by: sample.Failure%d: private-message' % index for index in range(20)) output = 'Caused by: sample.' + 'A' * 201 + ': private-message\n' + output diff --git a/tools/test_client_graphics.py b/tools/test_client_graphics.py index dbd86a383..f963687c5 100644 --- a/tools/test_client_graphics.py +++ b/tools/test_client_graphics.py @@ -23,7 +23,7 @@ except ImportError: def graphics_failure_summary(run, report_count): - """Selected stages/types/codes only; messages, paths and raw logs stay private.""" + """Selected stages/types/codes/methods only; messages and paths stay private.""" result = failure_summary(run, report_count) pattern = r'(?]{1,180})\(') + methods = re.findall(stack_pattern, run.stdout, re.MULTILINE | re.ASCII) + result['observed_graphics_stack_methods'] = list(dict.fromkeys(methods))[:8] return result @@ -92,6 +124,8 @@ def main(): report = reports[0] if report['observed_mode'] != ('world' if args.world else 'title') or report['ready_client_ticks'] < 40: raise AssertionError('Client never reached the requested graphics scene') + if report['overlay_present'] is not False: + raise AssertionError('Client graphics scene still has a loading overlay') if args.world: if report['world_loaded'] is not True or report['window_active'] is not True: raise AssertionError('Client never reached focused demo-world gameplay')