Files
metal2vulkan/crates/metal2vulkan-conformance/recordings/texture-shared-handles.json
T
Anees Iqbal ea02af47a4 Re-bless the cost records at d562bd4148
1135 recording(s) whose bounds moved. Cause: RT 1987 (206fbfba1c) makes a block ahead for a pool near its next block, and RT 1989 (d562bd4148) keeps a block's worth of bytes ahead per pool and has calls wait for a making instead of making a block in place, so made-ahead, made-in-place and waited-for block counts move. Contrast: pin 32's replay at 39b45dd232 (m3-max-12459) went over on blit-whole-texture-copy alone (buffer_blocks_made_ahead 1 where the record said 0); every value row matched the known-gaps ledger. The full list of moved bounds is in this commit's diff.
Measured on the M3 (s37-pl.sh rebless: cost --runs 8 --write over the whole
set, then cost --runs 8 --alone --write over the changed cases).

(cherry picked from commit ac01ee50d788bbd880e7f9d1a439bbf12c4e6bb7)
2026-11-09 15:47:53 -08:00

1102 lines
35 KiB
JSON

{
"format": 1,
"case": "texture-shared-handles",
"suite_version": 1,
"answers": [
{
"key": {
"chip": "apple-m3-max",
"os_version": "27.0.1",
"os_build": "26A434",
"metal_level": "27.0.1"
},
"provenance": "metal_run",
"device": "Apple M3 Max",
"runs": 3,
"outcomes": [
{
"runs": 3,
"transcript": {
"root": {
"name": "case",
"observed": {
"value": "absent"
},
"children": [
{
"name": "inputs",
"observed": {
"value": "absent"
},
"children": [
{
"name": "views",
"observed": {
"value": "absent",
"digest": {
"kind": "sha256",
"hex": "4a8fc301cf0dfe64d1d1af605c527506fd126e10fbbed98add065b0f73d48253"
}
}
},
{
"name": "asks",
"observed": {
"value": "absent",
"digest": {
"kind": "sha256",
"hex": "e68149d7e417af5ebf6c53fc9bb85397d2b408f875b7d545584f04784651fbc4"
}
}
}
]
},
{
"name": "parent-texture",
"observed": {
"value": {
"variant": {
"name": "Ok",
"payload": "absent"
}
}
}
},
{
"name": "parent",
"observed": {
"value": "absent"
},
"children": [
{
"name": "has_parent",
"observed": {
"value": {
"bool": false
}
}
},
{
"name": "expected_parent",
"observed": {
"value": {
"bool": false
}
}
},
{
"name": "parent_relative_level",
"observed": {
"value": {
"uint": 0
}
}
},
{
"name": "parent_relative_slice",
"observed": {
"value": {
"uint": 0
}
}
},
{
"name": "swizzle",
"observed": {
"value": {
"fields": {
"alpha": {
"uint": 1
},
"blue": {
"uint": 2
},
"green": {
"uint": 3
},
"red": {
"uint": 4
}
}
}
}
},
{
"name": "shareable",
"observed": {
"value": {
"bool": false
}
}
},
{
"name": "texture_type",
"observed": {
"value": {
"uint": 2
}
}
},
{
"name": "pixel_format",
"observed": {
"value": {
"uint": 70
}
}
},
{
"name": "mipmap_level_count",
"observed": {
"value": {
"uint": 4
}
}
},
{
"name": "array_length",
"observed": {
"value": {
"uint": 1
}
}
}
]
},
{
"name": "format-only/MTLPixelFormatRGBA8Unorm/Type2D/levels-0+4/slices-0+1/swizzle-2345",
"observed": {
"value": "absent"
},
"children": [
{
"name": "view",
"observed": {
"value": "absent"
},
"children": [
{
"name": "has_parent",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "expected_parent",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "parent_relative_level",
"observed": {
"value": {
"uint": 0
}
}
},
{
"name": "parent_relative_slice",
"observed": {
"value": {
"uint": 0
}
}
},
{
"name": "swizzle",
"observed": {
"value": {
"fields": {
"alpha": {
"uint": 1
},
"blue": {
"uint": 2
},
"green": {
"uint": 3
},
"red": {
"uint": 4
}
}
}
}
},
{
"name": "shareable",
"observed": {
"value": {
"bool": false
}
}
},
{
"name": "texture_type",
"observed": {
"value": {
"uint": 2
}
}
},
{
"name": "pixel_format",
"observed": {
"value": {
"uint": 70
}
}
},
{
"name": "mipmap_level_count",
"observed": {
"value": {
"uint": 4
}
}
},
{
"name": "array_length",
"observed": {
"value": {
"uint": 1
}
}
}
]
}
]
},
{
"name": "levels-slices/MTLPixelFormatRGBA8Unorm/Type2D/levels-1+2/slices-0+1/swizzle-2345",
"observed": {
"value": "absent"
},
"children": [
{
"name": "view",
"observed": {
"value": "absent"
},
"children": [
{
"name": "has_parent",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "expected_parent",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "parent_relative_level",
"observed": {
"value": {
"uint": 1
}
}
},
{
"name": "parent_relative_slice",
"observed": {
"value": {
"uint": 0
}
}
},
{
"name": "swizzle",
"observed": {
"value": {
"fields": {
"alpha": {
"uint": 1
},
"blue": {
"uint": 2
},
"green": {
"uint": 3
},
"red": {
"uint": 4
}
}
}
}
},
{
"name": "shareable",
"observed": {
"value": {
"bool": false
}
}
},
{
"name": "texture_type",
"observed": {
"value": {
"uint": 2
}
}
},
{
"name": "pixel_format",
"observed": {
"value": {
"uint": 70
}
}
},
{
"name": "mipmap_level_count",
"observed": {
"value": {
"uint": 2
}
}
},
{
"name": "array_length",
"observed": {
"value": {
"uint": 1
}
}
}
]
}
]
},
{
"name": "levels-slices/MTLPixelFormatRGBA8Unorm/Type2D/levels-1+3/slices-0+1/swizzle-2345/then/levels-slices/MTLPixelFormatRGBA8Unorm/Type2D/levels-1+2/slices-0+1/swizzle-2345",
"observed": {
"value": "absent"
},
"children": [
{
"name": "view",
"observed": {
"value": "absent"
},
"children": [
{
"name": "has_parent",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "expected_parent",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "parent_relative_level",
"observed": {
"value": {
"uint": 1
}
}
},
{
"name": "parent_relative_slice",
"observed": {
"value": {
"uint": 0
}
}
},
{
"name": "swizzle",
"observed": {
"value": {
"fields": {
"alpha": {
"uint": 1
},
"blue": {
"uint": 2
},
"green": {
"uint": 3
},
"red": {
"uint": 4
}
}
}
}
},
{
"name": "shareable",
"observed": {
"value": {
"bool": false
}
}
},
{
"name": "texture_type",
"observed": {
"value": {
"uint": 2
}
}
},
{
"name": "pixel_format",
"observed": {
"value": {
"uint": 70
}
}
},
{
"name": "mipmap_level_count",
"observed": {
"value": {
"uint": 3
}
}
},
{
"name": "array_length",
"observed": {
"value": {
"uint": 1
}
}
}
]
},
{
"name": "view-of-the-view",
"observed": {
"value": "absent"
},
"children": [
{
"name": "has_parent",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "expected_parent",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "parent_relative_level",
"observed": {
"value": {
"uint": 1
}
}
},
{
"name": "parent_relative_slice",
"observed": {
"value": {
"uint": 0
}
}
},
{
"name": "swizzle",
"observed": {
"value": {
"fields": {
"alpha": {
"uint": 1
},
"blue": {
"uint": 2
},
"green": {
"uint": 3
},
"red": {
"uint": 4
}
}
}
}
},
{
"name": "shareable",
"observed": {
"value": {
"bool": false
}
}
},
{
"name": "texture_type",
"observed": {
"value": {
"uint": 2
}
}
},
{
"name": "pixel_format",
"observed": {
"value": {
"uint": 70
}
}
},
{
"name": "mipmap_level_count",
"observed": {
"value": {
"uint": 2
}
}
},
{
"name": "array_length",
"observed": {
"value": {
"uint": 1
}
}
}
]
}
]
},
{
"name": "shared-texture",
"observed": {
"value": "absent"
},
"children": [
{
"name": "has_parent",
"observed": {
"value": {
"bool": false
}
}
},
{
"name": "expected_parent",
"observed": {
"value": {
"bool": false
}
}
},
{
"name": "parent_relative_level",
"observed": {
"value": {
"uint": 0
}
}
},
{
"name": "parent_relative_slice",
"observed": {
"value": {
"uint": 0
}
}
},
{
"name": "swizzle",
"observed": {
"value": {
"fields": {
"alpha": {
"uint": 5
},
"blue": {
"uint": 4
},
"green": {
"uint": 3
},
"red": {
"uint": 2
}
}
}
}
},
{
"name": "shareable",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "texture_type",
"observed": {
"value": {
"uint": 2
}
}
},
{
"name": "pixel_format",
"observed": {
"value": {
"uint": 70
}
}
},
{
"name": "mipmap_level_count",
"observed": {
"value": {
"uint": 4
}
}
},
{
"name": "array_length",
"observed": {
"value": {
"uint": 1
}
}
}
]
},
{
"name": "view-of-the-shared-texture",
"observed": {
"value": "absent"
},
"children": [
{
"name": "has_parent",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "expected_parent",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "parent_relative_level",
"observed": {
"value": {
"uint": 1
}
}
},
{
"name": "parent_relative_slice",
"observed": {
"value": {
"uint": 0
}
}
},
{
"name": "swizzle",
"observed": {
"value": {
"fields": {
"alpha": {
"uint": 5
},
"blue": {
"uint": 4
},
"green": {
"uint": 3
},
"red": {
"uint": 2
}
}
}
}
},
{
"name": "shareable",
"observed": {
"value": {
"bool": false
}
}
},
{
"name": "texture_type",
"observed": {
"value": {
"uint": 2
}
}
},
{
"name": "pixel_format",
"observed": {
"value": {
"uint": 70
}
}
},
{
"name": "mipmap_level_count",
"observed": {
"value": {
"uint": 2
}
}
},
{
"name": "array_length",
"observed": {
"value": {
"uint": 1
}
}
}
]
},
{
"name": "shared-handle",
"observed": {
"value": "absent"
},
"children": [
{
"name": "own_device",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "opens",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "opened_shareable",
"observed": {
"value": {
"bool": true
}
}
},
{
"name": "opened_width",
"observed": {
"value": {
"uint": 64
}
}
},
{
"name": "opened_height",
"observed": {
"value": {
"uint": 64
}
}
},
{
"name": "opened_levels",
"observed": {
"value": {
"uint": 4
}
}
}
]
},
{
"name": "notices",
"observed": {
"value": "absent"
},
"children": [
{
"name": "set",
"observed": {
"value": {
"nothing": "announced_nothing"
}
}
},
{
"name": "counts",
"observed": {
"value": {
"fields": {}
}
}
}
]
}
]
}
}
}
],
"validated": "ran"
}
],
"costs": [
{
"venue": "Apple M3 Max",
"runs": 8,
"measured": "8 run(s) of the whole selection on Apple M3 Max, in the case set's own order, the largest each count reached",
"contrasted": "8 run(s) of each case on its own on Apple M3 Max, nothing before it on the device, the largest each count reached",
"bounds": {
"addressable_buffers_made": 2,
"blocks_ahead_hurried": 1,
"blocks_ahead_waited_for": 4,
"buffer_blocks_made_ahead": 2,
"host_copy_blocks_made_in_place": 1,
"host_copy_blocks_readied": 1,
"image_blocks_made_ahead": 2,
"image_blocks_made_in_place": 1,
"images_started_on_the_host": 1,
"object_churn.images_own_memory": 2,
"object_churn.images_recycled": 1,
"object_churn.textures_image": 8,
"object_churn.vk_image_bindings": 1,
"object_churn.vk_images_destroyed": 2,
"object_churn.vk_images_made": 1,
"plain_buffer_blocks_made": 2,
"pooled_memory_blocks_made": 4
},
"composed": {
"blocks_ahead_hurried": 1,
"blocks_ahead_waited_for": 4,
"buffer_blocks_made_ahead": 2,
"host_copy_blocks_made_in_place": 1,
"host_copy_blocks_readied": 1,
"image_blocks_made_ahead": 2,
"image_blocks_made_in_place": 1,
"plain_buffer_blocks_made": 2
},
"ceilings": {
"addressable_buffers_made": 2,
"pooled_memory_blocks_made": 4
}
}
],
"times": [
{
"leg": "metal",
"venue": "native Metal",
"chip": "apple-m3-max",
"os_build": "26A434",
"rounds": 8,
"measured": "8 round(s) of the whole selection, in the case set's own order, each round on a fresh device, our shader cache carried over between the cases of a round; a figure is the median of the rounds' own medians; Metal's leg ran at a one-minute load average of 3.18 and ours at 2.63; the legs run one after the other, so the per-call margin is judged only when both are 26.0 or under and within 2.0x of each other",
"instrument": 236,
"times": {
"case": "texture-shared-handles",
"calls": 15,
"in_calls": 96499,
"on_cpu": 98459,
"blocked": 0,
"elsewhere": 1250,
"spend": 97415,
"spend_least": 90209,
"spend_most": 111959,
"per_call": [
{
"call": "shared_texture",
"least_calls": 1,
"most_calls": 1,
"wall": 78292,
"on_cpu": 78500,
"blocked": 0,
"wall_least": 71833,
"wall_most": 87208,
"wall_total": 78292,
"on_cpu_total": 78500,
"blocked_total": 0
},
{
"call": "shared_texture_handle",
"least_calls": 1,
"most_calls": 1,
"wall": 5625,
"on_cpu": 5750,
"blocked": 0,
"wall_least": 5292,
"wall_most": 5875,
"wall_total": 5625,
"on_cpu_total": 5750,
"blocked_total": 0
},
{
"call": "texture",
"least_calls": 1,
"most_calls": 1,
"wall": 7125,
"on_cpu": 7250,
"blocked": 0,
"wall_least": 6500,
"wall_most": 11542,
"wall_total": 7125,
"on_cpu_total": 7250,
"blocked_total": 0
},
{
"call": "texture_view",
"least_calls": 5,
"most_calls": 5,
"wall": 1000,
"on_cpu": 1084,
"blocked": 0,
"wall_least": 875,
"wall_most": 1042,
"wall_total": 5416,
"on_cpu_total": 6001,
"blocked_total": 0
},
{
"call": "texture_view_facts",
"least_calls": 7,
"most_calls": 7,
"wall": 42,
"on_cpu": 167,
"blocked": 0,
"wall_least": 42,
"wall_most": 83,
"wall_total": 417,
"on_cpu_total": 1291,
"blocked_total": 0
}
]
}
},
{
"leg": "ours",
"venue": "Apple M3 Max",
"chip": "apple-m3-max",
"os_build": "26A434",
"rounds": 8,
"measured": "8 round(s) of the whole selection, in the case set's own order, each round on a fresh device, our shader cache carried over between the cases of a round; a figure is the median of the rounds' own medians; Metal's leg ran at a one-minute load average of 3.18 and ours at 2.63; the legs run one after the other, so the per-call margin is judged only when both are 26.0 or under and within 2.0x of each other",
"instrument": 233,
"times": {
"case": "texture-shared-handles",
"calls": 15,
"in_calls": 15830,
"on_cpu": 17585,
"blocked": 0,
"elsewhere": 625,
"spend": 16419,
"spend_least": 15830,
"spend_most": 16707,
"per_call": [
{
"call": "shared_texture",
"least_calls": 1,
"most_calls": 1,
"wall": 1708,
"on_cpu": 1833,
"blocked": 0,
"wall_least": 1667,
"wall_most": 1750,
"wall_total": 1708,
"on_cpu_total": 1833,
"blocked_total": 0
},
{
"call": "shared_texture_handle",
"least_calls": 1,
"most_calls": 1,
"wall": 542,
"on_cpu": 667,
"blocked": 0,
"wall_least": 500,
"wall_most": 542,
"wall_total": 542,
"on_cpu_total": 667,
"blocked_total": 0
},
{
"call": "texture",
"least_calls": 1,
"most_calls": 1,
"wall": 11291,
"on_cpu": 11417,
"blocked": 0,
"wall_least": 11208,
"wall_most": 11750,
"wall_total": 11291,
"on_cpu_total": 11417,
"blocked_total": 0
},
{
"call": "texture_view",
"least_calls": 5,
"most_calls": 5,
"wall": 458,
"on_cpu": 542,
"blocked": 0,
"wall_least": 417,
"wall_most": 459,
"wall_total": 2167,
"on_cpu_total": 2750,
"blocked_total": 0
},
{
"call": "texture_view_facts",
"least_calls": 7,
"most_calls": 7,
"wall": 41,
"on_cpu": 125,
"blocked": 0,
"wall_least": 0,
"wall_most": 42,
"wall_total": 167,
"on_cpu_total": 959,
"blocked_total": 0
}
]
}
}
]
}