SPULLVMRecompiler: remove unnecessary bitcast

This commit is contained in:
oltolm 2024-09-06 00:32:05 +02:00 committed by Elad
parent e67d090c35
commit 42751cc8fb

View File

@ -543,9 +543,7 @@ class spu_llvm_recompiler : public spu_recompiler_base, public cpu_translator
template <typename T = u8>
llvm::Value* _ptr(llvm::Value* base, llvm::Value* offset)
{
const auto off = m_ir->CreateGEP(get_type<u8>(), base, offset);
const auto ptr = m_ir->CreateBitCast(off, get_type<T*>());
return ptr;
return m_ir->CreateGEP(get_type<u8>(), base, offset);
}
template <typename T, typename... Args>