1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-19 00:20:25 +02:00

Merge remote-tracking branch 'upstream/master' into HighlightCurrentLine

This commit is contained in:
blat-blatnik 2022-01-07 01:54:50 +01:00
commit 4e46b7eab3
2 changed files with 17 additions and 11 deletions

View file

@ -1387,17 +1387,7 @@ void BFGC::AdjustStackPtr(intptr& addr, int& size)
bool BFGC::ScanThreads()
{
BP_ZONE("BFGC::ScanThreads");
if (mStackScanIdx == 0)
{
// 'Prime' register capture
intptr regVals[128];
intptr stackPtr = 0;
BfpThreadResult threadResult;
int regValCount = 128;
BfpThread_GetIntRegisters(BfpThread_GetCurrent(), &stackPtr, regVals, &regValCount, &threadResult);
}
mUsingThreadUnlocked = true;
BF_FULL_MEMORY_FENCE();
@ -2403,6 +2393,16 @@ void BFGC::PerformCollection()
{
BP_ZONE("TriggerCollection");
if (mCollectIdx == 0)
{
// 'Prime' register capture
intptr regVals[128];
intptr stackPtr = 0;
BfpThreadResult threadResult;
int regValCount = 128;
BfpThread_GetIntRegisters(BfpThread_GetCurrent(), &stackPtr, regVals, &regValCount, &threadResult);
}
int prevMarkId = mCurMarkId;
DWORD startTick = BFTickCount();

View file

@ -14480,6 +14480,12 @@ BfIRValue BfModule::AllocLocalVariable(BfType* type, const StringImpl& name, boo
void BfModule::DoAddLocalVariable(BfLocalVariable* localVar)
{
while (localVar->mName.StartsWith('@'))
{
localVar->mNamePrefixCount++;
localVar->mName.Remove(0);
}
localVar->mLocalVarIdx = (int)mCurMethodState->mLocals.size();
mCurMethodState->mLocals.push_back(localVar);