Repository navigation
Commit 776cd83
authored
vulkan: use roundEven for UnaryOp round (#7119)
GLSL round() leaves the direction of halfway cases to the implementation.
MoltenVK rounds them away from zero, while every cpu implementation rounds
half to even, so 0.5 / 2.5 / -0.5 came out as 1 / 3 / -1 on Apple gpus.
Add exact halfway inputs to test_unaryop for op_type 18.1 parent 2cbb264 commit 776cd83
2 files changed
Lines changed: 11 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
49 | | - | |
| 49 | + | |
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
66 | 66 | | |
67 | 67 | | |
68 | 68 | | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
69 | 79 | | |
70 | 80 | | |
71 | 81 | | |
| |||
0 commit comments