SPV: Correct semantics of atomic-counter decrement.

The semantics differ between GLSL/HLSL and SPIR-V.
Translate between these.
This commit is contained in:
John Kessenich 2017-10-06 21:21:48 -06:00
parent 592e8f0441
commit 48d6e798bc
3 changed files with 80 additions and 71 deletions

View file

@ -417,8 +417,8 @@ enum TOperator {
EOpAtomicExchange,
EOpAtomicCompSwap,
EOpAtomicCounterIncrement,
EOpAtomicCounterDecrement,
EOpAtomicCounterIncrement, // results in pre-increment value
EOpAtomicCounterDecrement, // results in post-decrement value
EOpAtomicCounter,
EOpAtomicCounterAdd,
EOpAtomicCounterSubtract,