SPIRV-Tools/test
Steven Perron 208921efe8 Fix finding constant with particular type. (#1724)
With current implementation, the constant manager does not keep around
two constant with the same value but different types when the types
hash to the same value. So when you start looking for that constant you
will get a constant with the wrong type back.

I've made a few changes to the constant manager to fix this.  First off,
I have changed the map from constant to ids to be an std::multimap.
This way a single constant can be mapped to mutiple ids each
representing a different type.

Then when asking for an id of a constant, we can search all of the ids
associated with that constant in order to find the one with the correct
type.
2018-07-16 12:36:53 -04:00
..
comp Change libspirv to spvtools namespace (#1678) 2018-07-07 09:38:00 -04:00
link Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
opt Fix finding constant with particular type. (#1724) 2018-07-16 12:36:53 -04:00
scripts Added --compact-ids to /tools/opt 2017-04-20 10:54:39 -04:00
stats Change libspirv to spvtools namespace (#1678) 2018-07-07 09:38:00 -04:00
util Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
val Add option to skip verifying block layout 2018-07-11 18:00:54 -04:00
assembly_context_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
assembly_format_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
binary_destroy_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
binary_endianness_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
binary_header_get_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
binary_parse_test.cpp Change libspirv to spvtools namespace (#1678) 2018-07-07 09:38:00 -04:00
binary_strnlen_s_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
binary_to_text_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
binary_to_text.literal_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
bit_stream.cpp Move utils/ to spvtools::utils 2018-07-06 16:47:46 -04:00
c_interface_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
CMakeLists.txt Add --time-report to spirv-opt 2018-03-20 21:30:06 -04:00
comment_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
cpp_interface_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
diagnostic_test.cpp Change libspirv to spvtools namespace (#1678) 2018-07-07 09:38:00 -04:00
enum_set_test.cpp Change libspirv to spvtools namespace (#1678) 2018-07-07 09:38:00 -04:00
enum_string_mapping_test.cpp Change libspirv to spvtools namespace (#1678) 2018-07-07 09:38:00 -04:00
ext_inst.debuginfo_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
ext_inst.glsl_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
ext_inst.opencl_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
fix_word_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
generator_magic_number_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
hex_float_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
huffman_codec.cpp Move utils/ to spvtools::utils 2018-07-06 16:47:46 -04:00
immediate_int_test.cpp Move utils/ to spvtools::utils 2018-07-06 16:47:46 -04:00
libspirv_macros_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
log_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
move_to_front_test.cpp Move utils/ to spvtools::utils 2018-07-06 16:47:46 -04:00
name_mapper_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
named_id_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
opcode_make_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
opcode_require_capabilities_test.cpp Change libspirv to spvtools namespace (#1678) 2018-07-07 09:38:00 -04:00
opcode_split_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
opcode_table_get_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
operand_capabilities_test.cpp Change libspirv to spvtools namespace (#1678) 2018-07-07 09:38:00 -04:00
operand_pattern_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
operand_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
operand-class-test-coverage.csv Fix operand class test coverage table. 2016-09-23 11:58:25 -04:00
parse_number_test.cpp Move utils/ to spvtools::utils 2018-07-06 16:47:46 -04:00
preserve_numeric_ids_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
software_version_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
string_utils_test.cpp Move utils/ to spvtools::utils 2018-07-06 16:47:46 -04:00
target_env_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
test_fixture.h Renaming test files to comply with Google style guide. 2016-11-07 14:41:51 -05:00
text_advance_test.cpp Change libspirv to spvtools namespace (#1678) 2018-07-07 09:38:00 -04:00
text_destroy_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_literal_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_start_new_inst_test.cpp Change libspirv to spvtools namespace (#1678) 2018-07-07 09:38:00 -04:00
text_to_binary_test.cpp Change libspirv to spvtools namespace (#1678) 2018-07-07 09:38:00 -04:00
text_to_binary.annotation_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.barrier_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.constant_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.control_flow_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.debug_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.device_side_enqueue_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.extension_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.function_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.group_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.image_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.literal_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.memory_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.misc_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.mode_setting_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.pipe_storage_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.reserved_sampling_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.subgroup_dispatch_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_to_binary.type_declaration_test.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
text_word_get_test.cpp Change libspirv to spvtools namespace (#1678) 2018-07-07 09:38:00 -04:00
timer_test.cpp Move utils/ to spvtools::utils 2018-07-06 16:47:46 -04:00
unit_spirv.cpp Move tests into namespaces (#1689) 2018-07-11 09:24:49 -04:00
unit_spirv.h Move validation files to val/ directory (#1692) 2018-07-11 10:27:34 -04:00