Index: docs/CommandGuide/FileCheck.rst =================================================================== --- docs/CommandGuide/FileCheck.rst +++ docs/CommandGuide/FileCheck.rst @@ -480,3 +480,45 @@ letting us set the :program:`FileCheck` variable ``DLOC`` to the desired value ``0x00000233``, extracted from the line immediately preceding "``intd``". + + +REQUIRES and REQUIRES-ANY directive +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +Some tests can be enabled only in specific situation - like having +debug build. Use ``REQUIRES`` directive to specify those requirements. + +.. code-block:: llvm + + ; This test will be only enabled in the build with asserts + ; REQUIRES asserts + +You can separate requirements by a coma. +If test depends on one of many requirements, use ``REQUIRES-ANY``. + +List of features that can be used in ``REQUIRES`` and ``REQUIRES-ANY``: +- asserts +- shell +- can-execute +- loadable_module +- asan +- not_asan +- msan +- not_msan +- ubsan +- not_ubsan +- long_tests +- object-emission +- zlib +- nozlib +- default_triple +- x86_64-linux +- native +- ld_emu_elf32ppc +- ld_plugin +- ld64_plugin +- fma3 +- system-windows +- debug_frame +- global-isel +- xar