diff options
author | Weiyi Wang <wwylele@gmail.com> | 2017-05-12 17:02:45 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-05-12 17:02:45 +0200 |
commit | 9bd3986540a990abc82ef2b03fc4d621d78c2e03 (patch) | |
tree | 7f10b237188546c98cc6ca54518cb63261216260 /src/video_core/shader/shader_jit_x64_compiler.h | |
parent | Merge pull request #2669 from jroweboy/async_file_watcher (diff) | |
parent | Pica: Write GS registers (diff) | |
download | yuzu-9bd3986540a990abc82ef2b03fc4d621d78c2e03.tar yuzu-9bd3986540a990abc82ef2b03fc4d621d78c2e03.tar.gz yuzu-9bd3986540a990abc82ef2b03fc4d621d78c2e03.tar.bz2 yuzu-9bd3986540a990abc82ef2b03fc4d621d78c2e03.tar.lz yuzu-9bd3986540a990abc82ef2b03fc4d621d78c2e03.tar.xz yuzu-9bd3986540a990abc82ef2b03fc4d621d78c2e03.tar.zst yuzu-9bd3986540a990abc82ef2b03fc4d621d78c2e03.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/shader/shader_jit_x64_compiler.h | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/video_core/shader/shader_jit_x64_compiler.h b/src/video_core/shader/shader_jit_x64_compiler.h index f27675560..31af0ca48 100644 --- a/src/video_core/shader/shader_jit_x64_compiler.h +++ b/src/video_core/shader/shader_jit_x64_compiler.h @@ -22,8 +22,8 @@ namespace Pica { namespace Shader { -/// Memory allocated for each compiled shader (64Kb) -constexpr size_t MAX_SHADER_SIZE = 1024 * 64; +/// Memory allocated for each compiled shader +constexpr size_t MAX_SHADER_SIZE = MAX_PROGRAM_CODE_LENGTH * 64; /** * This class implements the shader JIT compiler. It recompiles a Pica shader program into x86_64 @@ -37,8 +37,8 @@ public: program(&setup, &state, instruction_labels[offset].getAddress()); } - void Compile(const std::array<u32, 1024>* program_code, - const std::array<u32, 1024>* swizzle_data); + void Compile(const std::array<u32, MAX_PROGRAM_CODE_LENGTH>* program_code, + const std::array<u32, MAX_SWIZZLE_DATA_LENGTH>* swizzle_data); void Compile_ADD(Instruction instr); void Compile_DP3(Instruction instr); @@ -104,11 +104,11 @@ private: */ void FindReturnOffsets(); - const std::array<u32, 1024>* program_code = nullptr; - const std::array<u32, 1024>* swizzle_data = nullptr; + const std::array<u32, MAX_PROGRAM_CODE_LENGTH>* program_code = nullptr; + const std::array<u32, MAX_SWIZZLE_DATA_LENGTH>* swizzle_data = nullptr; /// Mapping of Pica VS instructions to pointers in the emitted code - std::array<Xbyak::Label, 1024> instruction_labels; + std::array<Xbyak::Label, MAX_PROGRAM_CODE_LENGTH> instruction_labels; /// Offsets in code where a return needs to be inserted std::vector<unsigned> return_offsets; |