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

IsThreadLocal fixes

This commit is contained in:
Brian Fiete 2024-03-02 06:04:44 -05:00
parent 5387313269
commit 43e718b24e
3 changed files with 4 additions and 8 deletions

View file

@ -3967,9 +3967,9 @@ void BfIRBuilder::CreateTypeDefinition(BfType* type, bool forceDbgDefine)
{
if (isDefiningModule)
{
fieldInstance->mIsThreadLocal = mModule->IsThreadLocal(fieldInstance);
bool isThreadLocal = mModule->IsThreadLocal(fieldInstance);
if (!resolvedFieldType->IsVoid())
mModule->CreateStaticField(fieldInstance, fieldInstance->mIsThreadLocal);
mModule->CreateStaticField(fieldInstance, isThreadLocal);
}
}
}

View file

@ -19959,7 +19959,7 @@ void BfModule::EmitGCMarkMembers()
auto fieldDef = fieldInst.GetFieldDef();
if (fieldDef == NULL)
continue;
if (fieldInst.mIsThreadLocal)
if (IsThreadLocal(&fieldInst))
continue;
if (fieldDef->mIsStatic == methodDef->mIsStatic)
@ -20038,7 +20038,7 @@ void BfModule::EmitGCFindTLSMembers()
auto fieldDef = fieldInst.GetFieldDef();
if (fieldDef == NULL)
continue;
if (!fieldInst.mIsThreadLocal)
if (!IsThreadLocal(&fieldInst))
continue;
// For extensions, only handle these fields in the appropriate extension

View file

@ -1393,7 +1393,6 @@ public:
int mDataSize;
bool mFieldIncluded;
bool mIsEnumPayloadCase;
bool mIsThreadLocal;
bool mIsInferredType;
bool mHadConstEval;
int mLastRevisionReferenced;
@ -1418,7 +1417,6 @@ public:
mDataSize = copyFrom.mDataSize;
mFieldIncluded = copyFrom.mFieldIncluded;
mIsEnumPayloadCase = copyFrom.mIsEnumPayloadCase;
mIsThreadLocal = copyFrom.mIsThreadLocal;
mIsInferredType = copyFrom.mIsInferredType;
mHadConstEval = copyFrom.mHadConstEval;
mLastRevisionReferenced = copyFrom.mLastRevisionReferenced;
@ -1440,7 +1438,6 @@ public:
mDataSize = copyFrom.mDataSize;
mFieldIncluded = copyFrom.mFieldIncluded;
mIsEnumPayloadCase = copyFrom.mIsEnumPayloadCase;
mIsThreadLocal = copyFrom.mIsThreadLocal;
mIsInferredType = copyFrom.mIsInferredType;
mHadConstEval = copyFrom.mHadConstEval;
mLastRevisionReferenced = copyFrom.mLastRevisionReferenced;
@ -1459,7 +1456,6 @@ public:
mDataOffset = -1;
mDataSize = 0;
mFieldIncluded = true;
mIsThreadLocal = false;
mIsInferredType = false;
mHadConstEval = false;
mLastRevisionReferenced = -1;