This is to avoid checking for the validity of a file that is not used.
We have some scenarios where we create a test build of a game, with CFI sanitizer activated but blacklist disabled.
Our build system uses FastBuild : it allows distributed compilation, by sending to remote workers the compiler executable + command line + preprocessed cpp.
Without this fix, the remote build fails as the remote build doesn't have a resource-dir structure with the default blacklist file.
This also contains a minor fix for the test, as the cfi sanitizer requires -flto and -fvisibility= arguments.
How do you feel about adding a test that driver doesn't pass -fsanitize-system-blacklist option to cc1?
IIUC your test checks that driver doesn't try to parse it but in theory it might still pass it.