SPIRV-Tools/source/fuzz
Alastair Donaldson 77fb303e58
spirv-fuzz: Fuzzer pass to add function calls (#3178)
Adds a fuzzer pass that inserts function calls into the module at
random. Calls from dead blocks can be arbitrary (so long as they do
not introduce recursion), while calls from other blocks can only be to
livesafe functions.

The change fixes some oversights in transformations to replace
constants with uniforms and to obfuscate constants which testing of
this fuzzer pass identified.
2020-02-10 23:22:34 +00:00
..
protobufs spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
call_graph.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
call_graph.h spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
CMakeLists.txt spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
data_descriptor.cpp spirv-fuzz: improvements to representation of data synonym facts (#3006) 2019-11-01 17:50:01 +00:00
data_descriptor.h spirv-fuzz: improvements to representation of data synonym facts (#3006) 2019-11-01 17:50:01 +00:00
equivalence_relation.h spirv-fuzz: make equivalence classes deterministic (#3011) 2019-11-05 15:34:05 +00:00
fact_manager.cpp spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
fact_manager.h spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
force_render_red.cpp spirv-fuzz: Rework id descriptors (#2959) 2019-10-11 10:13:06 +01:00
force_render_red.h spirv-fuzz: option to convert shader into a form that renders red (#2934) 2019-10-03 19:10:50 +01:00
fuzzer_context.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer_context.h spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer_pass_add_composite_types.cpp spirv-fuzz: Fuzzer pass to add composite types (#3171) 2020-02-04 14:00:19 +00:00
fuzzer_pass_add_composite_types.h spirv-fuzz: Fuzzer pass to add composite types (#3171) 2020-02-04 14:00:19 +00:00
fuzzer_pass_add_dead_blocks.cpp spirv-fuzz: add dead blocks (#3135) 2020-01-13 22:04:01 +00:00
fuzzer_pass_add_dead_blocks.h spirv-fuzz: add dead blocks (#3135) 2020-01-13 22:04:01 +00:00
fuzzer_pass_add_dead_breaks.cpp Add fuzzer pass to replace ids with synonyms (#2857) 2019-09-18 20:47:08 +01:00
fuzzer_pass_add_dead_breaks.h Fix end comments in header files (#2829) 2019-09-02 17:31:27 -04:00
fuzzer_pass_add_dead_continues.cpp Add fuzzer pass to replace ids with synonyms (#2857) 2019-09-18 20:47:08 +01:00
fuzzer_pass_add_dead_continues.h Fix end comments in header files (#2829) 2019-09-02 17:31:27 -04:00
fuzzer_pass_add_function_calls.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer_pass_add_function_calls.h spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer_pass_add_global_variables.cpp spirv-fuzz: Fuzzer passes to add local and global variables (#3175) 2020-02-05 21:07:44 +00:00
fuzzer_pass_add_global_variables.h spirv-fuzz: Fuzzer passes to add local and global variables (#3175) 2020-02-05 21:07:44 +00:00
fuzzer_pass_add_loads.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer_pass_add_loads.h spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
fuzzer_pass_add_local_variables.cpp spirv-fuzz: Fuzzer passes to add local and global variables (#3175) 2020-02-05 21:07:44 +00:00
fuzzer_pass_add_local_variables.h spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
fuzzer_pass_add_no_contraction_decorations.cpp spirv-fuzz: Eliminate spurious semicolons (#3025) 2019-11-08 17:58:59 +00:00
fuzzer_pass_add_no_contraction_decorations.h spirv-fuzz: Add fuzzer pass to add NoContraction decorations (#2950) 2019-10-11 09:15:47 +01:00
fuzzer_pass_add_stores.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer_pass_add_stores.h spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
fuzzer_pass_add_useful_constructs.cpp spirv-fuzz: Eliminate spurious semicolons (#3025) 2019-11-08 17:58:59 +00:00
fuzzer_pass_add_useful_constructs.h Fix end comments in header files (#2829) 2019-09-02 17:31:27 -04:00
fuzzer_pass_adjust_function_controls.cpp spirv-fuzz: Eliminate spurious semicolons (#3025) 2019-11-08 17:58:59 +00:00
fuzzer_pass_adjust_function_controls.h spirv-fuzz: Add fuzzer pass to change function controls (#2951) 2019-10-11 07:10:47 +01:00
fuzzer_pass_adjust_loop_controls.cpp spirv-fuzz: Eliminate spurious semicolons (#3025) 2019-11-08 17:58:59 +00:00
fuzzer_pass_adjust_loop_controls.h spirv-fuzz: Add fuzzer pass to change loop controls (#2949) 2019-10-10 13:34:38 +01:00
fuzzer_pass_adjust_memory_operands_masks.cpp spirv-fuzz: fuzzer pass to adjust memory access operands (#2968) 2019-10-22 18:05:35 +01:00
fuzzer_pass_adjust_memory_operands_masks.h spirv-fuzz: fuzzer pass to adjust memory access operands (#2968) 2019-10-22 18:05:35 +01:00
fuzzer_pass_adjust_selection_controls.cpp spirv-fuzz: Eliminate spurious semicolons (#3025) 2019-11-08 17:58:59 +00:00
fuzzer_pass_adjust_selection_controls.h spirv-fuzz: Add fuzzer pass to change selection controls (#2944) 2019-10-08 11:25:34 +01:00
fuzzer_pass_apply_id_synonyms.cpp spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
fuzzer_pass_apply_id_synonyms.h Add fuzzer pass to replace ids with synonyms (#2857) 2019-09-18 20:47:08 +01:00
fuzzer_pass_construct_composites.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer_pass_construct_composites.h spirv-fuzz: add transformation and pass to construct composites (#2941) 2019-10-08 14:04:10 +01:00
fuzzer_pass_copy_objects.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer_pass_copy_objects.h Add fuzzer pass to copy objects (#2853) 2019-09-11 23:45:20 +01:00
fuzzer_pass_donate_modules.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer_pass_donate_modules.h spirv-fuzz: Make functions "livesafe" during donation (#3146) 2020-01-29 15:52:31 +00:00
fuzzer_pass_merge_blocks.cpp spirv-fuzz: Fuzzer pass to merge blocks (#3097) 2019-12-12 15:27:40 +00:00
fuzzer_pass_merge_blocks.h spirv-fuzz: Fuzzer pass to merge blocks (#3097) 2019-12-12 15:27:40 +00:00
fuzzer_pass_obfuscate_constants.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer_pass_obfuscate_constants.h Fix end comments in header files (#2829) 2019-09-02 17:31:27 -04:00
fuzzer_pass_outline_functions.cpp spirv-fuzz: function outlining fuzzer pass (#3078) 2019-12-10 14:47:42 +00:00
fuzzer_pass_outline_functions.h spirv-fuzz: function outlining fuzzer pass (#3078) 2019-12-10 14:47:42 +00:00
fuzzer_pass_permute_blocks.cpp Rework management of probabilities in spirv-fuzz (#2839) 2019-09-10 15:02:25 +01:00
fuzzer_pass_permute_blocks.h Fix end comments in header files (#2829) 2019-09-02 17:31:27 -04:00
fuzzer_pass_split_blocks.cpp spirv-fuzz: Refactor 'split blocks' to identify instructions differently (#2961) 2019-10-14 17:00:46 +01:00
fuzzer_pass_split_blocks.h Fix end comments in header files (#2829) 2019-09-02 17:31:27 -04:00
fuzzer_pass.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer_pass.h spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer_util.cpp spirv-fuzz: Ensure that donated variables are always initialized (#3181) 2020-02-10 20:10:41 +00:00
fuzzer_util.h spirv-fuzz: Ensure that donated variables are always initialized (#3181) 2020-02-10 20:10:41 +00:00
fuzzer.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
fuzzer.h spirv-fuzz: Add fuzzer pass to perform module donation (#3117) 2020-01-07 08:39:55 +00:00
id_use_descriptor.cpp Avoid uninit warning in GCC (#3044) 2019-11-13 17:15:11 -05:00
id_use_descriptor.h spirv-fuzz: Rework id descriptors (#2959) 2019-10-11 10:13:06 +01:00
instruction_descriptor.cpp spirv-fuzz: simplify transformation for replacing an id with a synonym (#3020) 2019-11-07 16:19:06 +00:00
instruction_descriptor.h spirv-fuzz: simplify transformation for replacing an id with a synonym (#3020) 2019-11-07 16:19:06 +00:00
instruction_message.cpp spirv-fuzz: Add fuzzer pass to perform module donation (#3117) 2020-01-07 08:39:55 +00:00
instruction_message.h spirv-fuzz: Add fuzzer pass to perform module donation (#3117) 2020-01-07 08:39:55 +00:00
pseudo_random_generator.cpp Add "split block" transformation. (#2633) 2019-05-29 16:42:46 +01:00
pseudo_random_generator.h Add library for spirv-fuzz (#2618) 2019-05-27 14:34:55 +01:00
random_generator.cpp Add library for spirv-fuzz (#2618) 2019-05-27 14:34:55 +01:00
random_generator.h Add library for spirv-fuzz (#2618) 2019-05-27 14:34:55 +01:00
replayer.cpp Allow validation during spirv-fuzz replay (#2873) 2019-09-20 10:54:09 +01:00
replayer.h Allow validation during spirv-fuzz replay (#2873) 2019-09-20 10:54:09 +01:00
shrinker.cpp Allow validation during spirv-fuzz replay (#2873) 2019-09-20 10:54:09 +01:00
shrinker.h Allow validation during spirv-fuzz replay (#2873) 2019-09-20 10:54:09 +01:00
transformation_add_constant_boolean.cpp Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_add_constant_boolean.h Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_add_constant_composite.cpp spirv-fuzz: Transformations to add types, constants and variables (#3101) 2019-12-16 23:54:13 +00:00
transformation_add_constant_composite.h spirv-fuzz: Transformations to add types, constants and variables (#3101) 2019-12-16 23:54:13 +00:00
transformation_add_constant_scalar.cpp Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_add_constant_scalar.h Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_add_dead_block.cpp spirv-fuzz: add dead blocks (#3135) 2020-01-13 22:04:01 +00:00
transformation_add_dead_block.h spirv-fuzz: add dead blocks (#3135) 2020-01-13 22:04:01 +00:00
transformation_add_dead_break.cpp spirv-fuzz: add dead blocks (#3135) 2020-01-13 22:04:01 +00:00
transformation_add_dead_break.h spirv-fuzz: Use validator to check break/continue dominance conditions (#3089) 2019-12-06 16:38:17 +00:00
transformation_add_dead_continue.cpp spirv-fuzz: add dead blocks (#3135) 2020-01-13 22:04:01 +00:00
transformation_add_dead_continue.h spirv-fuzz: Use validator to check break/continue dominance conditions (#3089) 2019-12-06 16:38:17 +00:00
transformation_add_function.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
transformation_add_function.h spirv-fuzz: Make functions "livesafe" during donation (#3146) 2020-01-29 15:52:31 +00:00
transformation_add_global_undef.cpp spirv-fuzz: Transformations to add types, constants and variables (#3101) 2019-12-16 23:54:13 +00:00
transformation_add_global_undef.h spirv-fuzz: Transformations to add types, constants and variables (#3101) 2019-12-16 23:54:13 +00:00
transformation_add_global_variable.cpp spirv-fuzz: Ensure that donated variables are always initialized (#3181) 2020-02-10 20:10:41 +00:00
transformation_add_global_variable.h spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
transformation_add_local_variable.cpp spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
transformation_add_local_variable.h spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
transformation_add_no_contraction_decoration.cpp spirv-fuzz: Add fuzzer pass to add NoContraction decorations (#2950) 2019-10-11 09:15:47 +01:00
transformation_add_no_contraction_decoration.h spirv-fuzz: Add fuzzer pass to add NoContraction decorations (#2950) 2019-10-11 09:15:47 +01:00
transformation_add_type_array.cpp spirv-fuzz: Transformations to add types, constants and variables (#3101) 2019-12-16 23:54:13 +00:00
transformation_add_type_array.h spirv-fuzz: Transformations to add types, constants and variables (#3101) 2019-12-16 23:54:13 +00:00
transformation_add_type_boolean.cpp Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_add_type_boolean.h Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_add_type_float.cpp Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_add_type_float.h Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_add_type_function.cpp spirv-fuzz: Transformations to add types, constants and variables (#3101) 2019-12-16 23:54:13 +00:00
transformation_add_type_function.h spirv-fuzz: Transformations to add types, constants and variables (#3101) 2019-12-16 23:54:13 +00:00
transformation_add_type_int.cpp Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_add_type_int.h Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_add_type_matrix.cpp spirv-fuzz: Transformations to add types, constants and variables (#3101) 2019-12-16 23:54:13 +00:00
transformation_add_type_matrix.h spirv-fuzz: Fuzzer pass to add composite types (#3171) 2020-02-04 14:00:19 +00:00
transformation_add_type_pointer.cpp Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_add_type_pointer.h Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_add_type_struct.cpp spirv-fuzz: Transformations to add types, constants and variables (#3101) 2019-12-16 23:54:13 +00:00
transformation_add_type_struct.h spirv-fuzz: Transformations to add types, constants and variables (#3101) 2019-12-16 23:54:13 +00:00
transformation_add_type_vector.cpp spirv-fuzz: Transformations to add types, constants and variables (#3101) 2019-12-16 23:54:13 +00:00
transformation_add_type_vector.h spirv-fuzz: Fuzzer pass to add composite types (#3171) 2020-02-04 14:00:19 +00:00
transformation_composite_construct.cpp spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
transformation_composite_construct.h spirv-fuzz: rename class, and fix bug related to dominance (#2990) 2019-10-27 18:11:07 +00:00
transformation_composite_extract.cpp spirv-fuzz: better computation of data synonym facts (#3010) 2019-11-05 16:45:14 +00:00
transformation_composite_extract.h spirv-fuzz: Transformation to extract from a composite object (#2991) 2019-10-28 09:33:08 +00:00
transformation_copy_object.cpp spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
transformation_copy_object.h spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
transformation_function_call.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
transformation_function_call.h spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
transformation_load.cpp spirv-fuzz: Ensure that donated variables are always initialized (#3181) 2020-02-10 20:10:41 +00:00
transformation_load.h spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
transformation_merge_blocks.cpp spirv-fuzz: Fuzzer pass to merge blocks (#3097) 2019-12-12 15:27:40 +00:00
transformation_merge_blocks.h spirv-fuzz: Fuzzer pass to merge blocks (#3097) 2019-12-12 15:27:40 +00:00
transformation_move_block_down.cpp spirv-fuzz: preserve some analyses when permuting blocks (#2918) 2019-09-26 10:56:43 +01:00
transformation_move_block_down.h Disallow movement of unreachable blocks. (#2700) 2019-06-26 15:32:25 +01:00
transformation_outline_function.cpp spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
transformation_outline_function.h spirv-fuzz: Arbitrary variable facts (#3165) 2020-01-30 11:25:29 +00:00
transformation_replace_boolean_constant_with_constant_binary.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
transformation_replace_boolean_constant_with_constant_binary.h spirv-fuzz: do not replace boolean constant argument to OpPhi instruction (#2903) 2019-09-25 12:16:25 +01:00
transformation_replace_constant_with_uniform.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
transformation_replace_constant_with_uniform.h Refactor fuzzer transformations (#2694) 2019-06-25 20:49:46 +01:00
transformation_replace_id_with_synonym.cpp spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
transformation_replace_id_with_synonym.h spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
transformation_set_function_control.cpp spirv-fuzz: Add fuzzer pass to change function controls (#2951) 2019-10-11 07:10:47 +01:00
transformation_set_function_control.h spirv-fuzz: Add fuzzer pass to change function controls (#2951) 2019-10-11 07:10:47 +01:00
transformation_set_loop_control.cpp spirv-fuzz: Add fuzzer pass to change loop controls (#2949) 2019-10-10 13:34:38 +01:00
transformation_set_loop_control.h spirv-fuzz: Add fuzzer pass to change loop controls (#2949) 2019-10-10 13:34:38 +01:00
transformation_set_memory_operands_mask.cpp spirv-fuzz: fuzzer pass to adjust memory access operands (#2968) 2019-10-22 18:05:35 +01:00
transformation_set_memory_operands_mask.h spirv-fuzz: fuzzer pass to adjust memory access operands (#2968) 2019-10-22 18:05:35 +01:00
transformation_set_selection_control.cpp spirv-fuzz: Add fuzzer pass to change selection controls (#2944) 2019-10-08 11:25:34 +01:00
transformation_set_selection_control.h spirv-fuzz: Add fuzzer pass to change selection controls (#2944) 2019-10-08 11:25:34 +01:00
transformation_split_block.cpp spirv-fuzz: add dead blocks (#3135) 2020-01-13 22:04:01 +00:00
transformation_split_block.h spirv-fuzz: add dead blocks (#3135) 2020-01-13 22:04:01 +00:00
transformation_store.cpp spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
transformation_store.h spirv-fuzz: Add fuzzer passes to add loads/stores (#3176) 2020-02-06 16:54:34 +00:00
transformation_vector_shuffle.cpp spirv-fuzz: vector shuffle transformation (#3015) 2019-11-06 17:11:54 +00:00
transformation_vector_shuffle.h spirv-fuzz: vector shuffle transformation (#3015) 2019-11-06 17:11:54 +00:00
transformation.cpp spirv-fuzz: Fuzzer pass to add function calls (#3178) 2020-02-10 23:22:34 +00:00
transformation.h spirv-fuzz: Refactoring and type-related fixes (#3144) 2020-01-21 05:59:57 -08:00
uniform_buffer_element_descriptor.cpp Add 'copy object' transformation (#2766) 2019-08-05 18:00:13 +01:00
uniform_buffer_element_descriptor.h Fix end comments in header files (#2829) 2019-09-02 17:31:27 -04:00