| Index: src/IceGlobalContext.h
|
| diff --git a/src/IceGlobalContext.h b/src/IceGlobalContext.h
|
| index 2d60f4845466f879ebc50a407ca021edab29a01f..4788423ec988bba9f296ed6513e129c048d0fbb4 100644
|
| --- a/src/IceGlobalContext.h
|
| +++ b/src/IceGlobalContext.h
|
| @@ -482,6 +482,12 @@ public:
|
| return LockedPtr<StringPool>(Strings.get(), &StringsLock);
|
| }
|
|
|
| + LockedPtr<VariableDeclarationList> getGlobals() {
|
| + return LockedPtr<VariableDeclarationList>(&Globals, &InitAllocLock);
|
| + }
|
| +
|
| + bool getGlobalsReceived() { return GlobalsReceived; }
|
| +
|
| /// Number of function blocks that can be queued before waiting for
|
| /// translation
|
| /// threads to consume.
|
| @@ -500,6 +506,7 @@ private:
|
| // Managed by getInitializerAllocator()
|
| mutable GlobalLockType InitAllocLock;
|
| VariableDeclarationList Globals;
|
| + std::atomic<bool> GlobalsReceived;
|
|
|
| ICE_CACHELINE_BOUNDARY;
|
| // Managed by getDestructors()
|
| @@ -612,6 +619,7 @@ private:
|
| LockedPtr<VariableDeclarationList> _(&Globals, &InitAllocLock);
|
| if (Globls != nullptr) {
|
| Globals.merge(Globls.get());
|
| + GlobalsReceived = true;
|
| }
|
| }
|
|
|
|
|