Home | History | Annotate | Download | only in CodeGen

Lines Matching refs:Guard

1053     llvm::GlobalVariable *Guard;
1054 CallGuardAbort(llvm::GlobalVariable *Guard) : Guard(Guard) {}
1057 CGF.Builder.CreateCall(getGuardAbortFn(CGF.CGM, Guard->getType()), Guard)
1077 // are disabled, we can just let the guard variable be of type i8.
1084 // Guard variables are 64 bits in the generic ABI and 32 bits on ARM.
1089 // Create the guard variable if we don't already have it (as we
1091 llvm::GlobalVariable *guard = CGM.getStaticLocalDeclGuardAddress(&D);
1092 if (!guard) {
1093 // Mangle the name for the guard.
1101 // Create the guard variable with a zero-initializer.
1103 guard = new llvm::GlobalVariable(CGM.getModule(), guardTy,
1107 guard->setVisibility(var->getVisibility());
1109 CGM.setStaticLocalDeclGuardAddress(&D, guard);
1116 // To support the potential use of initialization guard variables
1119 // guard variable to be a 4-byte aligned, 4- byte word with the
1127 llvm::Value *V = Builder.CreateLoad(guard);
1129 isInitialized = Builder.CreateIsNull(V, "guard.uninitialized");
1146 // Load the first byte of the guard variable.
1148 Builder.CreateLoad(Builder.CreateBitCast(guard, CGM.Int8PtrTy));
1160 isInitialized = Builder.CreateIsNull(LI, "guard.uninitialized");
1166 // Check if the first byte of the guard variable is zero.
1175 = Builder.CreateCall(getGuardAcquireFn(CGM, guardPtrTy), guard);
1183 CGF.EHStack.pushCleanup<CallGuardAbort>(EHCleanup, guard);
1192 // Pop the guard-abort cleanup if we pushed one.
1196 Builder.CreateCall(getGuardReleaseFn(CGM, guardPtrTy), guard);
1198 Builder.CreateStore(llvm::ConstantInt::get(guardTy, 1), guard);