MCPcopy Create free account
hub / github.com/WheretIB/nullc / AllocateRegister

Function AllocateRegister

NULLC/CodeGen_X86.cpp:26–31  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

24 x86Reg regPool[] = { rEAX, rEBX, rECX, rEDX, rESI };
25 unsigned int regPoolPos = 0;
26 x86Reg AllocateRegister()
27 {
28 if(regPoolPos == 5)
29 regPoolPos = 0;
30 return regPool[regPoolPos++];
31 }
32
33 struct MemCache
34 {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected