summaryrefslogtreecommitdiffstats
path: root/src/shader_recompiler/frontend/maxwell/control_flow.h
diff options
context:
space:
mode:
authorReinUsesLisp <reinuseslisp@airmail.cc>2021-03-30 03:13:37 +0200
committerameerj <52414509+ameerj@users.noreply.github.com>2021-07-23 03:51:25 +0200
commitb0d5572abfe1f14e02d8219f0a4d7dd09ff36fd1 (patch)
tree434c9473dafdf0a2b54e8f6d662141da71560005 /src/shader_recompiler/frontend/maxwell/control_flow.h
parentspirv: Fix default output attribute initialization (diff)
downloadyuzu-b0d5572abfe1f14e02d8219f0a4d7dd09ff36fd1.tar
yuzu-b0d5572abfe1f14e02d8219f0a4d7dd09ff36fd1.tar.gz
yuzu-b0d5572abfe1f14e02d8219f0a4d7dd09ff36fd1.tar.bz2
yuzu-b0d5572abfe1f14e02d8219f0a4d7dd09ff36fd1.tar.lz
yuzu-b0d5572abfe1f14e02d8219f0a4d7dd09ff36fd1.tar.xz
yuzu-b0d5572abfe1f14e02d8219f0a4d7dd09ff36fd1.tar.zst
yuzu-b0d5572abfe1f14e02d8219f0a4d7dd09ff36fd1.zip
Diffstat (limited to '')
-rw-r--r--src/shader_recompiler/frontend/maxwell/control_flow.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/shader_recompiler/frontend/maxwell/control_flow.h b/src/shader_recompiler/frontend/maxwell/control_flow.h
index 1e05fcb97..a8c90d27a 100644
--- a/src/shader_recompiler/frontend/maxwell/control_flow.h
+++ b/src/shader_recompiler/frontend/maxwell/control_flow.h
@@ -22,6 +22,8 @@
namespace Shader::Maxwell::Flow {
+struct Block;
+
using FunctionId = size_t;
enum class EndClass {
@@ -60,6 +62,11 @@ private:
boost::container::small_vector<StackEntry, 3> entries;
};
+struct IndirectBranch {
+ Block* block;
+ u32 address;
+};
+
struct Block : boost::intrusive::set_base_hook<
// Normal link is ~2.5% faster compared to safe link
boost::intrusive::link_mode<boost::intrusive::normal_link>> {
@@ -84,7 +91,7 @@ struct Block : boost::intrusive::set_base_hook<
Block* return_block;
s32 branch_offset;
};
- std::vector<Block*> indirect_branches;
+ std::vector<IndirectBranch> indirect_branches;
};
struct Label {