shader: Implement SULD and SUST

This commit is contained in:
ReinUsesLisp 2021-04-09 01:45:39 -03:00 committed by ameerj
parent 094da34456
commit 7cb2ab3585
31 changed files with 739 additions and 209 deletions

View file

@ -1620,6 +1620,17 @@ Value IREmitter::ImageGradient(const Value& handle, const Value& coords, const V
return Inst(op, Flags{info}, handle, coords, derivates, offset, lod_clamp);
}
Value IREmitter::ImageRead(const Value& handle, const Value& coords, TextureInstInfo info) {
const Opcode op{handle.IsImmediate() ? Opcode::BoundImageRead : Opcode::BindlessImageRead};
return Inst(op, Flags{info}, handle, coords);
}
void IREmitter::ImageWrite(const Value& handle, const Value& coords, const Value& color,
TextureInstInfo info) {
const Opcode op{handle.IsImmediate() ? Opcode::BoundImageWrite : Opcode::BindlessImageWrite};
Inst(op, Flags{info}, handle, coords, color);
}
U1 IREmitter::VoteAll(const U1& value) {
return Inst<U1>(Opcode::VoteAll, value);
}