mirror of
https://github.com/yuzu-emu/sirit.git
synced 2024-11-25 17:15:41 +01:00
Add OpGroupNonUniformBroadcast subgroup op
This commit is contained in:
parent
aa292d5665
commit
da4ffce189
@ -1156,6 +1156,10 @@ public:
|
|||||||
/// TBD
|
/// TBD
|
||||||
Id OpSubgroupAllEqualKHR(Id result_type, Id predicate);
|
Id OpSubgroupAllEqualKHR(Id result_type, Id predicate);
|
||||||
|
|
||||||
|
// Result is the Value of the invocation identified by the id Id to all active invocations in
|
||||||
|
// the group.
|
||||||
|
Id OpGroupNonUniformBroadcast(Id result_type, Id scope, Id value, Id id);
|
||||||
|
|
||||||
/// Return the value of the invocation identified by the current invocation's id within the
|
/// Return the value of the invocation identified by the current invocation's id within the
|
||||||
/// group xor'ed with mask.
|
/// group xor'ed with mask.
|
||||||
Id OpGroupNonUniformShuffleXor(Id result_type, Id scope, Id value, Id mask);
|
Id OpGroupNonUniformShuffleXor(Id result_type, Id scope, Id value, Id mask);
|
||||||
|
@ -36,6 +36,12 @@ Id Module::OpSubgroupAllEqualKHR(Id result_type, Id predicate) {
|
|||||||
return *code << OpId{spv::Op::OpSubgroupAllEqualKHR, result_type} << predicate << EndOp{};
|
return *code << OpId{spv::Op::OpSubgroupAllEqualKHR, result_type} << predicate << EndOp{};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Id Module::OpGroupNonUniformBroadcast(Id result_type, Id scope, Id value, Id id) {
|
||||||
|
code->Reserve(6);
|
||||||
|
return *code << OpId{spv::Op::OpGroupNonUniformBroadcast, result_type} << scope << value
|
||||||
|
<< id << EndOp{};
|
||||||
|
}
|
||||||
|
|
||||||
Id Module::OpGroupNonUniformShuffleXor(Id result_type, Id scope, Id value, Id mask) {
|
Id Module::OpGroupNonUniformShuffleXor(Id result_type, Id scope, Id value, Id mask) {
|
||||||
code->Reserve(6);
|
code->Reserve(6);
|
||||||
return *code << OpId{spv::Op::OpGroupNonUniformShuffleXor, result_type} << scope << value
|
return *code << OpId{spv::Op::OpGroupNonUniformShuffleXor, result_type} << scope << value
|
||||||
|
Loading…
Reference in New Issue
Block a user