diff options
| author | Pokechu22 <Pokechu022@gmail.com> | 2022-04-13 16:12:53 -0700 |
|---|---|---|
| committer | Pokechu22 <Pokechu022@gmail.com> | 2022-04-22 16:54:38 -0700 |
| commit | 97d0ff58c8dbe374a1b87e1a72f1f245ed27ed96 (patch) | |
| tree | 70031f58df4bfbfc6222257bebaf3bced14cf24e /Source/Core/VideoCommon/VertexLoaderX64.cpp | |
| parent | f722bdf7f1ab5913d035f257ff82865a686b08d6 (diff) | |
Convert vertex loader position cache to std::array
Diffstat (limited to 'Source/Core/VideoCommon/VertexLoaderX64.cpp')
| -rw-r--r-- | Source/Core/VideoCommon/VertexLoaderX64.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/Source/Core/VideoCommon/VertexLoaderX64.cpp b/Source/Core/VideoCommon/VertexLoaderX64.cpp index 734fa0819c..91889c83d9 100644 --- a/Source/Core/VideoCommon/VertexLoaderX64.cpp +++ b/Source/Core/VideoCommon/VertexLoaderX64.cpp @@ -119,8 +119,9 @@ int VertexLoaderX64::ReadVertex(OpArg data, VertexComponentFormat attribute, Com { CMP(32, R(count_reg), Imm8(3)); FixupBranch dont_store = J_CC(CC_A); - LEA(32, scratch3, MScaled(count_reg, SCALE_4, -4)); - MOVUPS(MPIC(VertexLoaderManager::position_cache, scratch3, SCALE_4), coords); + LEA(32, scratch3, + MScaled(count_reg, SCALE_4, -int(VertexLoaderManager::position_cache[0].size()))); + MOVUPS(MPIC(VertexLoaderManager::position_cache.data(), scratch3, SCALE_4), coords); SetJumpTarget(dont_store); } }; @@ -408,7 +409,8 @@ void VertexLoaderX64::GenerateVertexLoader() // zfreeze CMP(32, R(count_reg), Imm8(3)); FixupBranch dont_store = J_CC(CC_A); - MOV(32, MPIC(VertexLoaderManager::position_matrix_index, count_reg, SCALE_4), R(scratch1)); + MOV(32, MPIC(VertexLoaderManager::position_matrix_index_cache.data(), count_reg, SCALE_4), + R(scratch1)); SetJumpTarget(dont_store); m_native_vtx_decl.posmtx.components = 4; |
