Browse Source
Merge pull request #3980 from ReinUsesLisp/red-op
shader/memory: Implement non-addition operations in RED
pull/15/merge
bunnei
6 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
1 additions and
2 deletions
-
src/video_core/shader/decode/memory.cpp
|
|
|
@ -387,7 +387,6 @@ u32 ShaderIR::DecodeMemory(NodeBlock& bb, u32 pc) { |
|
|
|
} |
|
|
|
case OpCode::Id::RED: { |
|
|
|
UNIMPLEMENTED_IF_MSG(instr.red.type != GlobalAtomicType::U32); |
|
|
|
UNIMPLEMENTED_IF_MSG(instr.red.operation != AtomicOp::Add); |
|
|
|
const auto [real_address, base_address, descriptor] = |
|
|
|
TrackGlobalMemory(bb, instr, true, true); |
|
|
|
if (!real_address || !base_address) { |
|
|
|
@ -396,7 +395,7 @@ u32 ShaderIR::DecodeMemory(NodeBlock& bb, u32 pc) { |
|
|
|
} |
|
|
|
Node gmem = MakeNode<GmemNode>(real_address, base_address, descriptor); |
|
|
|
Node value = GetRegister(instr.gpr0); |
|
|
|
bb.push_back(Operation(OperationCode::ReduceIAdd, move(gmem), move(value))); |
|
|
|
bb.push_back(Operation(GetAtomOperation(instr.red.operation), move(gmem), move(value))); |
|
|
|
break; |
|
|
|
} |
|
|
|
case OpCode::Id::ATOM: { |
|
|
|
|