File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -3564,6 +3564,16 @@ void Verifier::visitCallBase(CallBase &Call) {
3564
3564
Check (BU.Inputs [1 ]->getType ()->isIntegerTy (64 ),
3565
3565
" Ptrauth bundle discriminator operand must be an i64" , Call);
3566
3566
} else if (Tag == LLVMContext::OB_kcfi) {
3567
+ // If the call has a grandparent and is associated with a module that has
3568
+ // the "Disable CFI Check" flag,
3569
+ // skip further processing for this call.
3570
+ if (Call.getParent () && Call.getParent ()->getParent () &&
3571
+ Call.getModule ()) {
3572
+ if (Call.getModule ()->getModuleFlag (" Disable CFI Check" )) {
3573
+ continue ;
3574
+ }
3575
+ }
3576
+
3567
3577
Check (!FoundKCFIBundle, " Multiple kcfi operand bundles" , Call);
3568
3578
FoundKCFIBundle = true ;
3569
3579
Check (BU.Inputs .size () == 1 , " Expected exactly one kcfi bundle operand" ,
You can’t perform that action at this time.
0 commit comments