It checks every pixel in its 200x200 test area and makes an ok() call for each, typically resulting in 40000 failures when something goes wrong. At 96 bytes each that's a whopping 3.6 MB; way above the 1.5 MB report size limit, thus ensuring that if this one test fails the results from every other Wine test will be lost. So this patch modifies test_depth_bias() to only the report the first failure unless a developper manually runs it with a debug level of 2 or more.
Signed-off-by: Francois Gouget fgouget@codeweavers.com --- dlls/d3d10core/tests/d3d10core.c | 30 ++++++++++++++++++++++-------- 1 file changed, 22 insertions(+), 8 deletions(-)
diff --git a/dlls/d3d10core/tests/d3d10core.c b/dlls/d3d10core/tests/d3d10core.c index b9b83f4060d..7b563379f5c 100644 --- a/dlls/d3d10core/tests/d3d10core.c +++ b/dlls/d3d10core/tests/d3d10core.c @@ -15595,7 +15595,12 @@ static void test_depth_bias(void) for (x = 0; x < texture_desc.Width; ++x) { u16 = get_readback_data(&rb, x, y, sizeof(*u16)); - ok(*u16 == 0xffff, "Got unexpected value %#x.\n", *u16); + if (*u16 != 0xffff) + { + ok(0, "Got unexpected value %#x.\n", *u16); + if (winetest_debug <= 1) + break; + } } } release_resource_readback(&rb); @@ -15648,10 +15653,14 @@ static void test_depth_bias(void) { u32 = get_readback_data(&rb, x, y, sizeof(*u32)); u32_value = *u32 >> shift; - ok(abs(u32_value - expected_value) <= 1, - "Got value %#x (%.8e), expected %#x (%.8e).\n", - u32_value, u32_value / 16777215.0f, - expected_value, expected_value / 16777215.0f); + if (abs(u32_value - expected_value) > 1) + { + ok(0, "Got value %#x (%.8e), expected %#x (%.8e).\n", + u32_value, u32_value / 16777215.0f, + expected_value, expected_value / 16777215.0f); + if (winetest_debug <= 1) + break; + } } } release_resource_readback(&rb); @@ -15668,9 +15677,14 @@ static void test_depth_bias(void) for (x = 0; x < texture_desc.Width; ++x) { u16 = get_readback_data(&rb, x, y, sizeof(*u16)); - ok(abs(*u16 - expected_value) <= 1, - "Got value %#x (%.8e), expected %#x (%.8e).\n", - *u16, *u16 / 65535.0f, expected_value, expected_value / 65535.0f); + if (abs(*u16 - expected_value) > 1) + { + ok(0, "Got value %#x (%.8e), expected %#x (%.8e).\n", + *u16, *u16 / 65535.0f, + expected_value, expected_value / 65535.0f); + if (winetest_debug <= 1) + break; + } } } release_resource_readback(&rb);
Hi,
While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check?
Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=50292
Your paranoid android.
=== debian9 (32 bit report) ===
d3d10core: Unhandled exception: page fault on read access to 0x00000228 in 32-bit code (0x7ed89898).
=== debian9 (32 bit French report) ===
d3d10core: Unhandled exception: page fault on read access to 0x2e2f2e56 in 32-bit code (0x7ed89898).
=== debian9 (32 bit Chinese:China report) ===
d3d10core: Unhandled exception: page fault on execute access to 0x00000000 in 32-bit code (0x00000000).
=== debian9 (64 bit WoW report) ===
d3d10core: d3d10core.c:12479: Test failed: Got {-1.00787401e+00, 0.00000000e+00, 1.00000000e+00, 5.03937006e-01}, expected {-1.00000000e+00, 0.00000000e+00, 1.00000000e+00, 5.03937006e-01} at (0, 0), sub-resource 0.
It checks every pixel in its 200x200 test area and makes an ok() call for each, typically resulting in 40000 failures when something goes wrong. At 96 bytes each that's a whopping 3.6 MB; way above the 1.5 MB report size limit, thus ensuring that if this one test fails the results from every other Wine test will be lost. So this patch modifies test_depth_bias() to only the report the first failure unless a developper manually runs it with a debug level of 2 or more.
Signed-off-by: Francois Gouget fgouget@codeweavers.com ---
This version takes care of a few more messages. Also it indicates which round of a loop caused the failure.
Finally, as far as I can tell, the crash on line 102 is random and not caused by this patch.
dlls/d3d10core/tests/d3d10core.c | 53 +++++++++++++++++++++++--------- 1 file changed, 39 insertions(+), 14 deletions(-)
diff --git a/dlls/d3d10core/tests/d3d10core.c b/dlls/d3d10core/tests/d3d10core.c index b9b83f4060d..59c90a697bb 100644 --- a/dlls/d3d10core/tests/d3d10core.c +++ b/dlls/d3d10core/tests/d3d10core.c @@ -15595,7 +15595,12 @@ static void test_depth_bias(void) for (x = 0; x < texture_desc.Width; ++x) { u16 = get_readback_data(&rb, x, y, sizeof(*u16)); - ok(*u16 == 0xffff, "Got unexpected value %#x.\n", *u16); + if (*u16 != 0xffff) + { + ok(0, "Got unexpected value %#x.\n", *u16); + if (winetest_debug <= 1) + break; + } } } release_resource_readback(&rb); @@ -15648,10 +15653,14 @@ static void test_depth_bias(void) { u32 = get_readback_data(&rb, x, y, sizeof(*u32)); u32_value = *u32 >> shift; - ok(abs(u32_value - expected_value) <= 1, - "Got value %#x (%.8e), expected %#x (%.8e).\n", - u32_value, u32_value / 16777215.0f, - expected_value, expected_value / 16777215.0f); + if (abs(u32_value - expected_value) > 1) + { + ok(0, "Got value %#x (%.8e), expected %#x (%.8e).\n", + u32_value, u32_value / 16777215.0f, + expected_value, expected_value / 16777215.0f); + if (winetest_debug <= 1) + break; + } } } release_resource_readback(&rb); @@ -15668,9 +15677,14 @@ static void test_depth_bias(void) for (x = 0; x < texture_desc.Width; ++x) { u16 = get_readback_data(&rb, x, y, sizeof(*u16)); - ok(abs(*u16 - expected_value) <= 1, - "Got value %#x (%.8e), expected %#x (%.8e).\n", - *u16, *u16 / 65535.0f, expected_value, expected_value / 65535.0f); + if (abs(*u16 - expected_value) > 1) + { + ok(0, "Got value %#x (%.8e), expected %#x (%.8e).\n", + *u16, *u16 / 65535.0f, + expected_value, expected_value / 65535.0f); + if (winetest_debug <= 1) + break; + } } } release_resource_readback(&rb); @@ -15742,28 +15756,37 @@ static void test_depth_bias(void) case DXGI_FORMAT_D32_FLOAT: data = get_readback_float(&rb, 0, y); ok(compare_float(data, depth, 64), - "Got depth %.8e, expected %.8e.\n", data, depth); + "%d,%d,%d,%d Got depth %.8e, expected %.8e.\n", i, j, k, y, data, depth); + if (winetest_debug <= 1) + goto next_clamp_test; break; case DXGI_FORMAT_D24_UNORM_S8_UINT: u32 = get_readback_data(&rb, 0, y, sizeof(*u32)); u32_value = *u32 >> shift; expected_value = depth * 16777215.0f + 0.5f; ok(abs(u32_value - expected_value) <= 3, - "Got value %#x (%.8e), expected %#x (%.8e).\n", - u32_value, u32_value / 16777215.0f, - expected_value, expected_value / 16777215.0f); + "%d,%d,%d,%d Got value %#x (%.8e), expected %#x (%.8e).\n", + i, j, k, y, + u32_value, u32_value / 16777215.0f, + expected_value, expected_value / 16777215.0f); + if (winetest_debug <= 1) + goto next_clamp_test; break; case DXGI_FORMAT_D16_UNORM: u16 = get_readback_data(&rb, 0, y, sizeof(*u16)); expected_value = depth * 65535.0f + 0.5f; ok(abs(*u16 - expected_value) <= 1, - "Got value %#x (%.8e), expected %#x (%.8e).\n", - *u16, *u16 / 65535.0f, expected_value, expected_value / 65535.0f); + "%d,%d,%d,%d Got value %#x (%.8e), expected %#x (%.8e).\n", + i, j, k, y, *u16, *u16 / 65535.0f, + expected_value, expected_value / 65535.0f); + if (winetest_debug <= 1) + goto next_clamp_test; break; default: break; } } + next_clamp_test: release_resource_readback(&rb); ID3D10RasterizerState_Release(rs); } @@ -16810,6 +16833,8 @@ static void test_generate_mips(void) ok(color == expected_color, "Resource type %u, test %u: pixel (%u, %u) " "has color %08x, expected %08x.\n", i, j, expected[k].pos.x, expected[k].pos.y, color, expected_color); + if (winetest_debug <= 1) + break; } release_resource_readback(&rb);
Hi,
While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check?
Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=50356
Your paranoid android.
=== wvistau64 (32 bit report) ===
d3d10core: d3d10core.c:4848: Test failed: Got unexpected NumPrimitivesWritten: 4244635547. d3d10core.c:4851: Test failed: Got unexpected PrimitivesStorageNeeded: 0.
=== debian9 (32 bit report) ===
d3d10core: Unhandled exception: page fault on read access to 0x0000000b in 32-bit code (0x7ed938b3).
=== debian9 (32 bit French report) ===
d3d10core: Unhandled exception: page fault on execute access to 0x00000000 in 32-bit code (0x00000000).
=== debian9 (32 bit Japanese:Japan report) ===
d3d10core: d3d10core.c:4626: Test failed: Got unexpected hr 0x8876086a. Unhandled exception: page fault on read access to 0x6976656c in 32-bit code (0x7eda18b8).
=== debian9 (32 bit Chinese:China report) ===
d3d10core: Unhandled exception: page fault on execute access to 0x00000000 in 32-bit code (0x00000000).
=== debian9 (32 bit WoW report) ===
d3d10core: Unhandled exception: page fault on execute access to 0x00000000 in 32-bit code (0x00000000).
=== debian9 (64 bit WoW report) ===
d3d10core: d3d10core.c:12479: Test failed: Got {-1.00003052e+00, 0.00000000e+00, 1.00000000e+00, 0.00000000e+00}, expected {-1.00000000e+00, 0.00000000e+00, 1.00000000e+00, 0.00000000e+00} at (0, 0), sub-resource 0. d3d10core.c:12839: Test failed: Got {0x00000000, 0x00000000, 0x00000000, 0x00000000}, expected {0x00000000, 0xffffffff, 0x00000000, 0x00000000} at (0, 0), sub-resource 0. d3d10core.c:12839: Test failed: Got {0x00000000, 0x00000000, 0x00000000, 0x00000000}, expected {0xffffffff, 0x00000000, 0x00000000, 0x00000000} at (0, 0), sub-resource 0. d3d10core.c:12839: Test failed: Got {0xffffffff, 0x00000001, 0x00000000, 0x00000000}, expected {0x00000000, 0x00000001, 0x00000000, 0x00000000} at (0, 0), sub-resource 0. d3d10core.c:12839: Test failed: Got {0x00000001, 0xffffffff, 0x00000000, 0x00000000}, expected {0x00000001, 0x00000000, 0x00000000, 0x00000000} at (0, 0), sub-resource 0. d3d10core.c:12479: Test failed: Got {-1.00787401e+00, 0.00000000e+00, 1.00000000e+00, 5.03937006e-01}, expected {-1.00000000e+00, 0.00000000e+00, 1.00000000e+00, 5.03937006e-01} at (0, 0), sub-resource 0. d3d10core.c:16833: Test failed: Resource type 1, test 7: pixel (200, 200) has color 00000000, expected ffff0000. d3d10core.c:16833: Test failed: Resource type 1, test 8: pixel (200, 200) has color 00000000, expected ffff0000. d3d10core.c:16833: Test failed: Resource type 2, test 7: pixel (200, 200) has color 00000000, expected ffff0000. d3d10core.c:16833: Test failed: Resource type 2, test 8: pixel (200, 200) has color 00000000, expected ffff0000. d3d10core.c:16833: Test failed: Resource type 3, test 7: pixel (200, 200) has color 00000000, expected ffff0000. d3d10core.c:16833: Test failed: Resource type 3, test 8: pixel (200, 200) has color 00000000, expected ffff0000. d3d10core.c:15758: Test failed: 1,1,0,0 Got depth 2.51951814e-03, expected 2.51948950e-03. d3d10core.c:15758: Test failed: 1,1,1,0 Got depth 2.51951814e-03, expected 2.51948950e-03. d3d10core.c:15758: Test failed: 1,1,2,0 Got depth 1.27950311e-03, expected 1.27948953e-03. d3d10core.c:15758: Test failed: 1,2,2,0 Got depth 1.27950311e-03, expected 1.27948953e-03. d3d10core.c:15758: Test failed: 1,3,2,0 Got depth 1.27950311e-03, expected 1.27948953e-03. d3d10core.c:15758: Test failed: 1,4,2,0 Got depth 1.27950311e-03, expected 1.27948953e-03. d3d10core.c:15758: Test failed: 1,5,2,0 Got depth 1.27950311e-03, expected 1.27948953e-03. d3d10core.c:15758: Test failed: 1,6,2,0 Got depth 1.27950311e-03, expected 1.27948953e-03. d3d10core.c:15758: Test failed: 2,1,0,0 Got depth 5.03277779e-03, expected 5.03897900e-03. d3d10core.c:15758: Test failed: 2,1,1,0 Got depth 5.03277779e-03, expected 5.03897900e-03. d3d10core.c:15758: Test failed: 2,1,2,0 Got depth 2.54905224e-03, expected 2.54897905e-03. d3d10core.c:15758: Test failed: 2,2,0,0 Got depth 7.52645731e-03, expected 7.53897894e-03. d3d10core.c:15758: Test failed: 2,2,1,0 Got depth 7.52645731e-03, expected 7.53897894e-03. d3d10core.c:15758: Test failed: 2,2,2,0 Got depth 2.54905224e-03, expected 2.54897905e-03. d3d10core.c:15758: Test failed: 2,3,0,0 Got depth 1.25139356e-02, expected 1.25389788e-02. d3d10core.c:15758: Test failed: 2,3,1,0 Got depth 1.25139356e-02, expected 1.25389788e-02. d3d10core.c:15758: Test failed: 2,3,2,0 Got depth 2.54905224e-03, expected 2.54897905e-03. d3d10core.c:15758: Test failed: 2,4,0,0 Got depth 6.40938997e-01, expected 6.42538965e-01. d3d10core.c:15758: Test failed: 2,4,1,0 Got depth 6.40938997e-01, expected 6.42538965e-01. d3d10core.c:15758: Test failed: 2,4,2,0 Got depth 2.54905224e-03, expected 2.54897905e-03. d3d10core.c:15758: Test failed: 2,5,2,0 Got depth 2.54905224e-03, expected 2.54897905e-03. d3d10core.c:15758: Test failed: 2,6,2,0 Got depth 2.54905224e-03, expected 2.54897905e-03. d3d10core.c:15767: Test failed: 2,1,0,0 Got value 0x149d4 (5.03277825e-03), expected 0x14a3c (5.03897713e-03). d3d10core.c:15767: Test failed: 2,1,1,0 Got value 0x149d4 (5.03277825e-03), expected 0x14a3c (5.03897713e-03). d3d10core.c:15767: Test failed: 2,2,0,0 Got value 0x1ed41 (7.52645778e-03), expected 0x1ee13 (7.53897475e-03). d3d10core.c:15767: Test failed: 2,2,1,0 Got value 0x1ed41 (7.52645778e-03), expected 0x1ee13 (7.53897475e-03). d3d10core.c:15767: Test failed: 2,3,0,0 Got value 0x3341d (1.25139365e-02), expected 0x335c1 (1.25389704e-02). d3d10core.c:15767: Test failed: 2,3,1,0 Got value 0x3341d (1.25139365e-02), expected 0x335c1 (1.25389704e-02). d3d10core.c:15767: Test failed: 2,4,0,0 Got value 0xa41493 (6.40938997e-01), expected 0xa47d6e (6.42538965e-01). d3d10core.c:15767: Test failed: 2,4,1,0 Got value 0xa41493 (6.40938997e-01), expected 0xa47d6e (6.42538965e-01). d3d10core.c:15778: Test failed: 2,4,0,0 Got value 0xa414 (6.40939951e-01), expected 0xa47c (6.42526865e-01). d3d10core.c:15778: Test failed: 2,4,1,0 Got value 0xa414 (6.40939951e-01), expected 0xa47c (6.42526865e-01).