Play-/Source/ee/VuBasicBlock.h

51 lines
1.3 KiB
C
Raw Permalink Normal View History

#pragma once
#include "../BasicBlock.h"
class CVuBasicBlock : public CBasicBlock
{
public:
2022-08-15 10:45:12 -04:00
CVuBasicBlock(CMIPS&, uint32, uint32, BLOCK_CATEGORY);
2018-04-30 21:01:23 +01:00
virtual ~CVuBasicBlock() = default;
void AddBlockCompileHints(uint32);
bool IsLinkable() const;
protected:
2018-04-30 21:01:23 +01:00
void CompileRange(CMipsJitter*) override;
private:
struct INTEGER_BRANCH_DELAY_INFO
{
unsigned int regIndex = 0;
2018-04-30 21:01:23 +01:00
uint32 saveRegAddress = MIPS_INVALID_PC;
uint32 useRegAddress = MIPS_INVALID_PC;
};
2018-04-30 21:01:23 +01:00
static bool IsConditionalBranch(uint32);
static bool IsNonConditionalBranch(uint32);
typedef uint32 FmacRegWriteTimes[32][4];
struct BlockFmacPipelineInfo
{
//State of the write times at the end of block
FmacRegWriteTimes regWriteTimes = {};
//Delays incurred during every instruction execution
std::vector<uint32> stallDelays;
//Pipe time at the end of block
uint32 pipeTime = 0;
};
INTEGER_BRANCH_DELAY_INFO ComputeIntegerBranchDelayInfo(const std::vector<uint32>&) const;
2024-01-22 23:28:49 +00:00
INTEGER_BRANCH_DELAY_INFO ComputeTrailingIntegerBranchDelayInfo(const std::vector<uint32>&) const;
bool CheckIsSpecialIntegerLoop(unsigned int) const;
void ComputeSkipFlagsHints(const std::vector<uint32>&, std::vector<uint32>&) const;
2023-10-16 18:03:42 -04:00
BlockFmacPipelineInfo ComputeFmacStallDelays(uint32, uint32) const;
2018-04-30 21:01:23 +01:00
static void EmitXgKick(CMipsJitter*);
bool m_isLinkable = true;
uint32 m_blockCompileHints = 0;
};