mirror of
https://github.com/KhronosGroup/SPIRV-Tools
synced 2024-11-21 19:20:07 +00:00
Cleanup includes. (#1795)
This Cl cleans up the include paths to be relative to the top level directory. Various include-what-you-use fixes have been added.
This commit is contained in:
parent
2d9a325264
commit
eda2cfbe12
@ -305,7 +305,6 @@ include $(CLEAR_VARS)
|
|||||||
LOCAL_MODULE := SPIRV-Tools
|
LOCAL_MODULE := SPIRV-Tools
|
||||||
LOCAL_C_INCLUDES := \
|
LOCAL_C_INCLUDES := \
|
||||||
$(LOCAL_PATH)/include \
|
$(LOCAL_PATH)/include \
|
||||||
$(LOCAL_PATH)/source \
|
|
||||||
$(LOCAL_PATH)/external/spirv-headers/include \
|
$(LOCAL_PATH)/external/spirv-headers/include \
|
||||||
$(SPVTOOLS_OUT_PATH)
|
$(SPVTOOLS_OUT_PATH)
|
||||||
LOCAL_EXPORT_C_INCLUDES := \
|
LOCAL_EXPORT_C_INCLUDES := \
|
||||||
|
1
BUILD.gn
1
BUILD.gn
@ -262,7 +262,6 @@ config("spvtools_config") {
|
|||||||
include_dirs = [
|
include_dirs = [
|
||||||
".",
|
".",
|
||||||
"include",
|
"include",
|
||||||
"source",
|
|
||||||
"$target_gen_dir",
|
"$target_gen_dir",
|
||||||
"${spirv_headers}/include",
|
"${spirv_headers}/include",
|
||||||
]
|
]
|
||||||
|
@ -101,7 +101,6 @@ elseif(MSVC)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/source)
|
|
||||||
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/)
|
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/)
|
||||||
|
|
||||||
option(SPIRV_COLOR_TERMINAL "Enable color terminal output" ON)
|
option(SPIRV_COLOR_TERMINAL "Enable color terminal output" ON)
|
||||||
|
@ -19,9 +19,6 @@ for more details about the presubmit API built into depot_tools.
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
LINT_FILTERS = [
|
LINT_FILTERS = [
|
||||||
"-build/include",
|
|
||||||
"-build/include_order",
|
|
||||||
"-build/include_what_you_use",
|
|
||||||
"-build/storage_class",
|
"-build/storage_class",
|
||||||
"-readability/braces",
|
"-readability/braces",
|
||||||
"-readability/casting",
|
"-readability/casting",
|
||||||
|
@ -12,16 +12,16 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "assembly_grammar.h"
|
#include "source/assembly_grammar.h"
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
|
|
||||||
#include "ext_inst.h"
|
#include "source/ext_inst.h"
|
||||||
#include "opcode.h"
|
#include "source/opcode.h"
|
||||||
#include "operand.h"
|
#include "source/operand.h"
|
||||||
#include "table.h"
|
#include "source/table.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace {
|
namespace {
|
||||||
|
@ -15,11 +15,11 @@
|
|||||||
#ifndef SOURCE_ASSEMBLY_GRAMMAR_H_
|
#ifndef SOURCE_ASSEMBLY_GRAMMAR_H_
|
||||||
#define SOURCE_ASSEMBLY_GRAMMAR_H_
|
#define SOURCE_ASSEMBLY_GRAMMAR_H_
|
||||||
|
|
||||||
#include "enum_set.h"
|
#include "source/enum_set.h"
|
||||||
#include "latest_version_spirv_header.h"
|
#include "source/latest_version_spirv_header.h"
|
||||||
#include "operand.h"
|
#include "source/operand.h"
|
||||||
|
#include "source/table.h"
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
#include "table.h"
|
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
|
|
||||||
|
@ -12,24 +12,25 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "binary.h"
|
#include "source/binary.h"
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
#include <iterator>
|
#include <iterator>
|
||||||
#include <limits>
|
#include <limits>
|
||||||
|
#include <string>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "assembly_grammar.h"
|
#include "source/assembly_grammar.h"
|
||||||
#include "diagnostic.h"
|
#include "source/diagnostic.h"
|
||||||
#include "ext_inst.h"
|
#include "source/ext_inst.h"
|
||||||
#include "latest_version_spirv_header.h"
|
#include "source/latest_version_spirv_header.h"
|
||||||
#include "opcode.h"
|
#include "source/opcode.h"
|
||||||
#include "operand.h"
|
#include "source/operand.h"
|
||||||
#include "spirv_constant.h"
|
#include "source/spirv_constant.h"
|
||||||
#include "spirv_endian.h"
|
#include "source/spirv_endian.h"
|
||||||
|
|
||||||
spv_result_t spvBinaryHeaderGet(const spv_const_binary binary,
|
spv_result_t spvBinaryHeaderGet(const spv_const_binary binary,
|
||||||
const spv_endianness_t endian,
|
const spv_endianness_t endian,
|
||||||
|
@ -15,8 +15,8 @@
|
|||||||
#ifndef SOURCE_BINARY_H_
|
#ifndef SOURCE_BINARY_H_
|
||||||
#define SOURCE_BINARY_H_
|
#define SOURCE_BINARY_H_
|
||||||
|
|
||||||
|
#include "source/spirv_definition.h"
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
#include "spirv_definition.h"
|
|
||||||
|
|
||||||
// Functions
|
// Functions
|
||||||
|
|
||||||
|
@ -24,7 +24,7 @@
|
|||||||
#include <string>
|
#include <string>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "comp/markv_model.h"
|
#include "source/comp/markv_model.h"
|
||||||
#include "spirv-tools/libspirv.hpp"
|
#include "spirv-tools/libspirv.hpp"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
|
@ -26,39 +26,41 @@
|
|||||||
#include <functional>
|
#include <functional>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <iterator>
|
#include <iterator>
|
||||||
|
#include <limits>
|
||||||
#include <list>
|
#include <list>
|
||||||
|
#include <map>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
#include <numeric>
|
#include <numeric>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "latest_version_glsl_std_450_header.h"
|
|
||||||
#include "latest_version_opencl_std_header.h"
|
|
||||||
#include "latest_version_spirv_header.h"
|
|
||||||
|
|
||||||
#include "binary.h"
|
|
||||||
#include "diagnostic.h"
|
|
||||||
#include "enum_string_mapping.h"
|
|
||||||
#include "ext_inst.h"
|
|
||||||
#include "extensions.h"
|
|
||||||
#include "id_descriptor.h"
|
|
||||||
#include "instruction.h"
|
|
||||||
#include "markv.h"
|
|
||||||
#include "markv_model.h"
|
|
||||||
#include "opcode.h"
|
|
||||||
#include "operand.h"
|
|
||||||
#include "source/assembly_grammar.h"
|
#include "source/assembly_grammar.h"
|
||||||
|
#include "source/binary.h"
|
||||||
|
#include "source/comp/markv.h"
|
||||||
|
#include "source/comp/markv_model.h"
|
||||||
|
#include "source/diagnostic.h"
|
||||||
|
#include "source/enum_string_mapping.h"
|
||||||
|
#include "source/ext_inst.h"
|
||||||
|
#include "source/extensions.h"
|
||||||
|
#include "source/id_descriptor.h"
|
||||||
|
#include "source/instruction.h"
|
||||||
|
#include "source/latest_version_glsl_std_450_header.h"
|
||||||
|
#include "source/latest_version_opencl_std_header.h"
|
||||||
|
#include "source/latest_version_spirv_header.h"
|
||||||
|
#include "source/opcode.h"
|
||||||
|
#include "source/operand.h"
|
||||||
|
#include "source/spirv_endian.h"
|
||||||
|
#include "source/spirv_validator_options.h"
|
||||||
|
#include "source/util/bit_stream.h"
|
||||||
|
#include "source/util/huffman_codec.h"
|
||||||
|
#include "source/util/move_to_front.h"
|
||||||
|
#include "source/util/parse_number.h"
|
||||||
|
#include "source/val/instruction.h"
|
||||||
|
#include "source/val/validate.h"
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
#include "spirv_endian.h"
|
|
||||||
#include "spirv_validator_options.h"
|
|
||||||
#include "util/bit_stream.h"
|
|
||||||
#include "util/huffman_codec.h"
|
|
||||||
#include "util/move_to_front.h"
|
|
||||||
#include "util/parse_number.h"
|
|
||||||
#include "val/instruction.h"
|
|
||||||
#include "val/validate.h"
|
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace comp {
|
namespace comp {
|
||||||
|
@ -16,12 +16,15 @@
|
|||||||
#define SOURCE_COMP_MARKV_MODEL_H_
|
#define SOURCE_COMP_MARKV_MODEL_H_
|
||||||
|
|
||||||
#include <map>
|
#include <map>
|
||||||
|
#include <memory>
|
||||||
|
#include <string>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "latest_version_spirv_header.h"
|
#include "source/latest_version_spirv_header.h"
|
||||||
|
#include "source/util/huffman_codec.h"
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
#include "util/huffman_codec.h"
|
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace comp {
|
namespace comp {
|
||||||
|
@ -12,14 +12,15 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "diagnostic.h"
|
#include "source/diagnostic.h"
|
||||||
|
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
|
#include <utility>
|
||||||
|
|
||||||
#include "table.h"
|
#include "source/table.h"
|
||||||
|
|
||||||
// Diagnostic API
|
// Diagnostic API
|
||||||
|
|
||||||
|
@ -21,20 +21,21 @@
|
|||||||
#include <iomanip>
|
#include <iomanip>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
|
#include <utility>
|
||||||
|
|
||||||
#include "assembly_grammar.h"
|
#include "source/assembly_grammar.h"
|
||||||
#include "binary.h"
|
#include "source/binary.h"
|
||||||
#include "diagnostic.h"
|
#include "source/diagnostic.h"
|
||||||
#include "disassemble.h"
|
#include "source/disassemble.h"
|
||||||
#include "ext_inst.h"
|
#include "source/ext_inst.h"
|
||||||
#include "name_mapper.h"
|
#include "source/name_mapper.h"
|
||||||
#include "opcode.h"
|
#include "source/opcode.h"
|
||||||
#include "parsed_operand.h"
|
#include "source/parsed_operand.h"
|
||||||
#include "print.h"
|
#include "source/print.h"
|
||||||
|
#include "source/spirv_constant.h"
|
||||||
|
#include "source/spirv_endian.h"
|
||||||
|
#include "source/util/hex_float.h"
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
#include "spirv_constant.h"
|
|
||||||
#include "spirv_endian.h"
|
|
||||||
#include "util/hex_float.h"
|
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
|
@ -21,7 +21,7 @@
|
|||||||
#include <set>
|
#include <set>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
|
||||||
#include "latest_version_spirv_header.h"
|
#include "source/latest_version_spirv_header.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "enum_string_mapping.h"
|
#include "source/enum_string_mapping.h"
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
@ -20,7 +20,7 @@
|
|||||||
#include <string>
|
#include <string>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
|
|
||||||
#include "extensions.h"
|
#include "source/extensions.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
|
|
||||||
|
@ -17,8 +17,8 @@
|
|||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
#include "extensions.h"
|
#include "source/extensions.h"
|
||||||
#include "latest_version_spirv_header.h"
|
#include "source/latest_version_spirv_header.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "ext_inst.h"
|
#include "source/ext_inst.h"
|
||||||
|
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
@ -22,14 +22,14 @@
|
|||||||
// TODO(dneto): DebugInfo.h should probably move to SPIRV-Headers.
|
// TODO(dneto): DebugInfo.h should probably move to SPIRV-Headers.
|
||||||
#include "DebugInfo.h"
|
#include "DebugInfo.h"
|
||||||
|
|
||||||
#include "latest_version_glsl_std_450_header.h"
|
#include "source/latest_version_glsl_std_450_header.h"
|
||||||
#include "latest_version_opencl_std_header.h"
|
#include "source/latest_version_opencl_std_header.h"
|
||||||
#include "macro.h"
|
#include "source/macro.h"
|
||||||
#include "spirv_definition.h"
|
#include "source/spirv_definition.h"
|
||||||
|
|
||||||
#include "debuginfo.insts.inc" // defines opencl_entries
|
#include "debuginfo.insts.inc"
|
||||||
#include "glsl.std.450.insts.inc" // defines glsl_entries
|
#include "glsl.std.450.insts.inc"
|
||||||
#include "opencl.std.insts.inc" // defines opencl_entries
|
#include "opencl.std.insts.inc"
|
||||||
|
|
||||||
#include "spv-amd-gcn-shader.insts.inc"
|
#include "spv-amd-gcn-shader.insts.inc"
|
||||||
#include "spv-amd-shader-ballot.insts.inc"
|
#include "spv-amd-shader-ballot.insts.inc"
|
||||||
|
@ -15,8 +15,8 @@
|
|||||||
#ifndef SOURCE_EXT_INST_H_
|
#ifndef SOURCE_EXT_INST_H_
|
||||||
#define SOURCE_EXT_INST_H_
|
#define SOURCE_EXT_INST_H_
|
||||||
|
|
||||||
|
#include "source/table.h"
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
#include "table.h"
|
|
||||||
|
|
||||||
// Gets the type of the extended instruction set with the specified name.
|
// Gets the type of the extended instruction set with the specified name.
|
||||||
spv_ext_inst_type_t spvExtInstImportTypeGet(const char* name);
|
spv_ext_inst_type_t spvExtInstImportTypeGet(const char* name);
|
||||||
|
@ -12,13 +12,13 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "extensions.h"
|
#include "source/extensions.h"
|
||||||
|
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
#include "enum_string_mapping.h"
|
#include "source/enum_string_mapping.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
|
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
#include "enum_set.h"
|
#include "source/enum_set.h"
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
|
@ -12,13 +12,13 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "id_descriptor.h"
|
#include "source/id_descriptor.h"
|
||||||
|
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
|
||||||
#include "opcode.h"
|
#include "source/opcode.h"
|
||||||
#include "operand.h"
|
#include "source/operand.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace {
|
namespace {
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "latest_version_spirv_header.h"
|
#include "source/latest_version_spirv_header.h"
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
|
|
||||||
// Describes an instruction.
|
// Describes an instruction.
|
||||||
|
@ -14,7 +14,11 @@
|
|||||||
|
|
||||||
#include "spirv-tools/libspirv.hpp"
|
#include "spirv-tools/libspirv.hpp"
|
||||||
|
|
||||||
#include "table.h"
|
#include <string>
|
||||||
|
#include <utility>
|
||||||
|
#include <vector>
|
||||||
|
|
||||||
|
#include "source/table.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
|
|
||||||
|
@ -14,26 +14,28 @@
|
|||||||
|
|
||||||
#include "spirv-tools/linker.hpp"
|
#include "spirv-tools/linker.hpp"
|
||||||
|
|
||||||
|
#include <algorithm>
|
||||||
#include <cstdio>
|
#include <cstdio>
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
|
|
||||||
#include <algorithm>
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
#include <memory>
|
||||||
|
#include <string>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "assembly_grammar.h"
|
#include "source/assembly_grammar.h"
|
||||||
#include "diagnostic.h"
|
#include "source/diagnostic.h"
|
||||||
#include "opt/build_module.h"
|
#include "source/opt/build_module.h"
|
||||||
#include "opt/compact_ids_pass.h"
|
#include "source/opt/compact_ids_pass.h"
|
||||||
#include "opt/decoration_manager.h"
|
#include "source/opt/decoration_manager.h"
|
||||||
#include "opt/ir_loader.h"
|
#include "source/opt/ir_loader.h"
|
||||||
#include "opt/make_unique.h"
|
#include "source/opt/make_unique.h"
|
||||||
#include "opt/pass_manager.h"
|
#include "source/opt/pass_manager.h"
|
||||||
#include "opt/remove_duplicates_pass.h"
|
#include "source/opt/remove_duplicates_pass.h"
|
||||||
|
#include "source/spirv_target_env.h"
|
||||||
#include "spirv-tools/libspirv.hpp"
|
#include "spirv-tools/libspirv.hpp"
|
||||||
#include "spirv_target_env.h"
|
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace {
|
namespace {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "message.h"
|
#include "source/message.h"
|
||||||
|
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "name_mapper.h"
|
#include "source/name_mapper.h"
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
@ -24,8 +24,8 @@
|
|||||||
|
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
|
|
||||||
#include "latest_version_spirv_header.h"
|
#include "source/latest_version_spirv_header.h"
|
||||||
#include "parsed_operand.h"
|
#include "source/parsed_operand.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace {
|
namespace {
|
||||||
|
@ -20,7 +20,7 @@
|
|||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
|
|
||||||
#include "assembly_grammar.h"
|
#include "source/assembly_grammar.h"
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "opcode.h"
|
#include "source/opcode.h"
|
||||||
|
|
||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
@ -20,12 +20,12 @@
|
|||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <cstdlib>
|
#include <cstdlib>
|
||||||
|
|
||||||
#include "instruction.h"
|
#include "source/instruction.h"
|
||||||
#include "macro.h"
|
#include "source/macro.h"
|
||||||
|
#include "source/spirv_constant.h"
|
||||||
|
#include "source/spirv_endian.h"
|
||||||
|
#include "source/spirv_target_env.h"
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
#include "spirv_constant.h"
|
|
||||||
#include "spirv_endian.h"
|
|
||||||
#include "spirv_target_env.h"
|
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
struct OpcodeDescPtrLen {
|
struct OpcodeDescPtrLen {
|
||||||
@ -33,7 +33,7 @@ struct OpcodeDescPtrLen {
|
|||||||
uint32_t len;
|
uint32_t len;
|
||||||
};
|
};
|
||||||
|
|
||||||
#include "core.insts-unified1.inc" // defines kOpcodeTableEntries_1_3
|
#include "core.insts-unified1.inc"
|
||||||
|
|
||||||
static const spv_opcode_table_t kOpcodeTable = {ARRAY_SIZE(kOpcodeTableEntries),
|
static const spv_opcode_table_t kOpcodeTable = {ARRAY_SIZE(kOpcodeTableEntries),
|
||||||
kOpcodeTableEntries};
|
kOpcodeTableEntries};
|
||||||
|
@ -15,10 +15,10 @@
|
|||||||
#ifndef SOURCE_OPCODE_H_
|
#ifndef SOURCE_OPCODE_H_
|
||||||
#define SOURCE_OPCODE_H_
|
#define SOURCE_OPCODE_H_
|
||||||
|
|
||||||
#include "instruction.h"
|
#include "source/instruction.h"
|
||||||
#include "latest_version_spirv_header.h"
|
#include "source/latest_version_spirv_header.h"
|
||||||
|
#include "source/table.h"
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
#include "table.h"
|
|
||||||
|
|
||||||
// Returns the name of a registered SPIR-V generator as a null-terminated
|
// Returns the name of a registered SPIR-V generator as a null-terminated
|
||||||
// string. If the generator is not known, then returns the string "Unknown".
|
// string. If the generator is not known, then returns the string "Unknown".
|
||||||
|
@ -12,15 +12,15 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "operand.h"
|
#include "source/operand.h"
|
||||||
|
|
||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
|
||||||
#include "macro.h"
|
#include "source/macro.h"
|
||||||
#include "spirv_constant.h"
|
#include "source/spirv_constant.h"
|
||||||
#include "spirv_target_env.h"
|
#include "source/spirv_target_env.h"
|
||||||
|
|
||||||
// For now, assume unified1 contains up to SPIR-V 1.3 and no later
|
// For now, assume unified1 contains up to SPIR-V 1.3 and no later
|
||||||
// SPIR-V version.
|
// SPIR-V version.
|
||||||
|
@ -16,9 +16,10 @@
|
|||||||
#define SOURCE_OPERAND_H_
|
#define SOURCE_OPERAND_H_
|
||||||
|
|
||||||
#include <functional>
|
#include <functional>
|
||||||
|
#include <vector>
|
||||||
|
|
||||||
|
#include "source/table.h"
|
||||||
#include "spirv-tools/libspirv.h"
|
#include "spirv-tools/libspirv.h"
|
||||||
#include "table.h"
|
|
||||||
|
|
||||||
// A sequence of operand types.
|
// A sequence of operand types.
|
||||||
//
|
//
|
||||||
|
@ -15,15 +15,16 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "aggressive_dead_code_elim_pass.h"
|
#include "source/opt/aggressive_dead_code_elim_pass.h"
|
||||||
|
|
||||||
#include "cfa.h"
|
|
||||||
#include "iterator.h"
|
|
||||||
#include "latest_version_glsl_std_450_header.h"
|
|
||||||
#include "reflect.h"
|
|
||||||
|
|
||||||
|
#include <memory>
|
||||||
#include <stack>
|
#include <stack>
|
||||||
|
|
||||||
|
#include "source/cfa.h"
|
||||||
|
#include "source/latest_version_glsl_std_450_header.h"
|
||||||
|
#include "source/opt/iterator.h"
|
||||||
|
#include "source/opt/reflect.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
|
||||||
|
@ -17,18 +17,21 @@
|
|||||||
#ifndef SOURCE_OPT_AGGRESSIVE_DEAD_CODE_ELIM_PASS_H_
|
#ifndef SOURCE_OPT_AGGRESSIVE_DEAD_CODE_ELIM_PASS_H_
|
||||||
#define SOURCE_OPT_AGGRESSIVE_DEAD_CODE_ELIM_PASS_H_
|
#define SOURCE_OPT_AGGRESSIVE_DEAD_CODE_ELIM_PASS_H_
|
||||||
|
|
||||||
#include <util/bit_vector.h>
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
#include <list>
|
||||||
#include <map>
|
#include <map>
|
||||||
#include <queue>
|
#include <queue>
|
||||||
|
#include <string>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
#include <vector>
|
||||||
|
|
||||||
#include "basic_block.h"
|
#include "source/opt/basic_block.h"
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "mem_pass.h"
|
#include "source/opt/mem_pass.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
|
#include "source/util/bit_vector.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,16 +12,16 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "basic_block.h"
|
#include "source/opt/basic_block.h"
|
||||||
#include "function.h"
|
|
||||||
#include "ir_context.h"
|
|
||||||
#include "module.h"
|
|
||||||
#include "reflect.h"
|
|
||||||
|
|
||||||
#include "make_unique.h"
|
|
||||||
|
|
||||||
#include <ostream>
|
#include <ostream>
|
||||||
|
|
||||||
|
#include "source/opt/function.h"
|
||||||
|
#include "source/opt/ir_context.h"
|
||||||
|
#include "source/opt/make_unique.h"
|
||||||
|
#include "source/opt/module.h"
|
||||||
|
#include "source/opt/reflect.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
namespace {
|
namespace {
|
||||||
|
@ -22,12 +22,13 @@
|
|||||||
#include <iterator>
|
#include <iterator>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
#include <ostream>
|
#include <ostream>
|
||||||
|
#include <string>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "instruction.h"
|
#include "source/opt/instruction.h"
|
||||||
#include "instruction_list.h"
|
#include "source/opt/instruction_list.h"
|
||||||
#include "iterator.h"
|
#include "source/opt/iterator.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -14,10 +14,12 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "block_merge_pass.h"
|
#include "source/opt/block_merge_pass.h"
|
||||||
|
|
||||||
#include "ir_context.h"
|
#include <vector>
|
||||||
#include "iterator.h"
|
|
||||||
|
#include "source/opt/ir_context.h"
|
||||||
|
#include "source/opt/iterator.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -24,11 +24,11 @@
|
|||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
|
||||||
#include "basic_block.h"
|
#include "source/opt/basic_block.h"
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
#include "pass.h"
|
#include "source/opt/pass.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,12 +12,15 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "build_module.h"
|
#include "source/opt/build_module.h"
|
||||||
|
|
||||||
#include "ir_context.h"
|
#include <utility>
|
||||||
#include "ir_loader.h"
|
#include <vector>
|
||||||
#include "make_unique.h"
|
|
||||||
#include "table.h"
|
#include "source/opt/ir_context.h"
|
||||||
|
#include "source/opt/ir_loader.h"
|
||||||
|
#include "source/opt/make_unique.h"
|
||||||
|
#include "source/table.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace {
|
namespace {
|
||||||
|
@ -18,8 +18,8 @@
|
|||||||
#include <memory>
|
#include <memory>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
#include "spirv-tools/libspirv.hpp"
|
#include "spirv-tools/libspirv.hpp"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
|
@ -16,13 +16,16 @@
|
|||||||
//
|
//
|
||||||
// Constant propagation with conditional branches,
|
// Constant propagation with conditional branches,
|
||||||
// Wegman and Zadeck, ACM TOPLAS 13(2):181-210.
|
// Wegman and Zadeck, ACM TOPLAS 13(2):181-210.
|
||||||
#include "ccp_pass.h"
|
|
||||||
#include "fold.h"
|
#include "source/opt/ccp_pass.h"
|
||||||
#include "function.h"
|
|
||||||
#include "module.h"
|
|
||||||
#include "propagator.h"
|
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
#include <limits>
|
||||||
|
|
||||||
|
#include "source/opt/fold.h"
|
||||||
|
#include "source/opt/function.h"
|
||||||
|
#include "source/opt/module.h"
|
||||||
|
#include "source/opt/propagator.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -15,12 +15,15 @@
|
|||||||
#ifndef SOURCE_OPT_CCP_PASS_H_
|
#ifndef SOURCE_OPT_CCP_PASS_H_
|
||||||
#define SOURCE_OPT_CCP_PASS_H_
|
#define SOURCE_OPT_CCP_PASS_H_
|
||||||
|
|
||||||
#include "constants.h"
|
#include <memory>
|
||||||
#include "function.h"
|
#include <unordered_map>
|
||||||
#include "ir_context.h"
|
|
||||||
#include "mem_pass.h"
|
#include "source/opt/constants.h"
|
||||||
#include "module.h"
|
#include "source/opt/function.h"
|
||||||
#include "propagator.h"
|
#include "source/opt/ir_context.h"
|
||||||
|
#include "source/opt/mem_pass.h"
|
||||||
|
#include "source/opt/module.h"
|
||||||
|
#include "source/opt/propagator.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,11 +12,15 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "cfg.h"
|
#include "source/opt/cfg.h"
|
||||||
#include "cfa.h"
|
|
||||||
#include "ir_builder.h"
|
#include <memory>
|
||||||
#include "ir_context.h"
|
#include <utility>
|
||||||
#include "module.h"
|
|
||||||
|
#include "source/cfa.h"
|
||||||
|
#include "source/opt/ir_builder.h"
|
||||||
|
#include "source/opt/ir_context.h"
|
||||||
|
#include "source/opt/module.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -15,12 +15,13 @@
|
|||||||
#ifndef SOURCE_OPT_CFG_H_
|
#ifndef SOURCE_OPT_CFG_H_
|
||||||
#define SOURCE_OPT_CFG_H_
|
#define SOURCE_OPT_CFG_H_
|
||||||
|
|
||||||
#include "basic_block.h"
|
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <list>
|
#include <list>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
|
#include <vector>
|
||||||
|
|
||||||
|
#include "source/opt/basic_block.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -19,10 +19,10 @@
|
|||||||
#include <queue>
|
#include <queue>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
|
|
||||||
#include "cfg_cleanup_pass.h"
|
#include "source/opt/cfg_cleanup_pass.h"
|
||||||
|
|
||||||
#include "function.h"
|
#include "source/opt/function.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -15,9 +15,9 @@
|
|||||||
#ifndef SOURCE_OPT_CFG_CLEANUP_PASS_H_
|
#ifndef SOURCE_OPT_CFG_CLEANUP_PASS_H_
|
||||||
#define SOURCE_OPT_CFG_CLEANUP_PASS_H_
|
#define SOURCE_OPT_CFG_CLEANUP_PASS_H_
|
||||||
|
|
||||||
#include "function.h"
|
#include "source/opt/function.h"
|
||||||
#include "mem_pass.h"
|
#include "source/opt/mem_pass.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,11 +12,13 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "combine_access_chains.h"
|
#include "source/opt/combine_access_chains.h"
|
||||||
|
|
||||||
#include "constants.h"
|
#include <utility>
|
||||||
#include "ir_builder.h"
|
|
||||||
#include "ir_context.h"
|
#include "source/opt/constants.h"
|
||||||
|
#include "source/opt/ir_builder.h"
|
||||||
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -15,7 +15,9 @@
|
|||||||
#ifndef SOURCE_OPT_COMBINE_ACCESS_CHAINS_H_
|
#ifndef SOURCE_OPT_COMBINE_ACCESS_CHAINS_H_
|
||||||
#define SOURCE_OPT_COMBINE_ACCESS_CHAINS_H_
|
#define SOURCE_OPT_COMBINE_ACCESS_CHAINS_H_
|
||||||
|
|
||||||
#include "pass.h"
|
#include <vector>
|
||||||
|
|
||||||
|
#include "source/opt/pass.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -14,9 +14,9 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "common_uniform_elim_pass.h"
|
#include "source/opt/common_uniform_elim_pass.h"
|
||||||
#include "cfa.h"
|
#include "source/cfa.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -18,18 +18,22 @@
|
|||||||
#define SOURCE_OPT_COMMON_UNIFORM_ELIM_PASS_H_
|
#define SOURCE_OPT_COMMON_UNIFORM_ELIM_PASS_H_
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
#include <list>
|
||||||
#include <map>
|
#include <map>
|
||||||
|
#include <memory>
|
||||||
#include <queue>
|
#include <queue>
|
||||||
|
#include <string>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
#include <vector>
|
||||||
|
|
||||||
#include "basic_block.h"
|
#include "source/opt/basic_block.h"
|
||||||
#include "decoration_manager.h"
|
#include "source/opt/decoration_manager.h"
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
#include "pass.h"
|
#include "source/opt/pass.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,12 +12,13 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "compact_ids_pass.h"
|
#include "source/opt/compact_ids_pass.h"
|
||||||
#include "ir_context.h"
|
|
||||||
|
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
|
|
||||||
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
|
||||||
|
@ -15,9 +15,9 @@
|
|||||||
#ifndef SOURCE_OPT_COMPACT_IDS_PASS_H_
|
#ifndef SOURCE_OPT_COMPACT_IDS_PASS_H_
|
||||||
#define SOURCE_OPT_COMPACT_IDS_PASS_H_
|
#define SOURCE_OPT_COMPACT_IDS_PASS_H_
|
||||||
|
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
#include "pass.h"
|
#include "source/opt/pass.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -14,14 +14,14 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "composite.h"
|
#include "source/opt/composite.h"
|
||||||
|
|
||||||
#include "ir_context.h"
|
|
||||||
#include "iterator.h"
|
|
||||||
#include "spirv/1.2/GLSL.std.450.h"
|
|
||||||
|
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
|
#include "source/opt/ir_context.h"
|
||||||
|
#include "source/opt/iterator.h"
|
||||||
|
#include "spirv/1.2/GLSL.std.450.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
|
||||||
|
@ -22,11 +22,12 @@
|
|||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
#include <vector>
|
||||||
|
|
||||||
#include "basic_block.h"
|
#include "source/opt/basic_block.h"
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,9 +12,9 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "const_folding_rules.h"
|
#include "source/opt/const_folding_rules.h"
|
||||||
|
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -15,9 +15,10 @@
|
|||||||
#ifndef SOURCE_OPT_CONST_FOLDING_RULES_H_
|
#ifndef SOURCE_OPT_CONST_FOLDING_RULES_H_
|
||||||
#define SOURCE_OPT_CONST_FOLDING_RULES_H_
|
#define SOURCE_OPT_CONST_FOLDING_RULES_H_
|
||||||
|
|
||||||
|
#include <unordered_map>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "constants.h"
|
#include "source/opt/constants.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,12 +12,13 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "constants.h"
|
#include "source/opt/constants.h"
|
||||||
#include "ir_context.h"
|
|
||||||
|
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
namespace analysis {
|
namespace analysis {
|
||||||
|
@ -16,17 +16,18 @@
|
|||||||
#define SOURCE_OPT_CONSTANTS_H_
|
#define SOURCE_OPT_CONSTANTS_H_
|
||||||
|
|
||||||
#include <cinttypes>
|
#include <cinttypes>
|
||||||
|
#include <map>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "make_unique.h"
|
#include "source/opt/make_unique.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
#include "type_manager.h"
|
#include "source/opt/type_manager.h"
|
||||||
#include "types.h"
|
#include "source/opt/types.h"
|
||||||
#include "util/hex_float.h"
|
#include "source/util/hex_float.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,8 +12,11 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "copy_prop_arrays.h"
|
#include "source/opt/copy_prop_arrays.h"
|
||||||
#include "ir_builder.h"
|
|
||||||
|
#include <utility>
|
||||||
|
|
||||||
|
#include "source/opt/ir_builder.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -15,7 +15,10 @@
|
|||||||
#ifndef SOURCE_OPT_COPY_PROP_ARRAYS_H_
|
#ifndef SOURCE_OPT_COPY_PROP_ARRAYS_H_
|
||||||
#define SOURCE_OPT_COPY_PROP_ARRAYS_H_
|
#define SOURCE_OPT_COPY_PROP_ARRAYS_H_
|
||||||
|
|
||||||
#include "mem_pass.h"
|
#include <memory>
|
||||||
|
#include <vector>
|
||||||
|
|
||||||
|
#include "source/opt/mem_pass.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -15,12 +15,16 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "dead_branch_elim_pass.h"
|
#include "source/opt/dead_branch_elim_pass.h"
|
||||||
|
|
||||||
#include "cfa.h"
|
#include <list>
|
||||||
#include "ir_context.h"
|
#include <memory>
|
||||||
#include "iterator.h"
|
#include <vector>
|
||||||
#include "make_unique.h"
|
|
||||||
|
#include "source/cfa.h"
|
||||||
|
#include "source/opt/ir_context.h"
|
||||||
|
#include "source/opt/iterator.h"
|
||||||
|
#include "source/opt/make_unique.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -23,11 +23,12 @@
|
|||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
#include <vector>
|
||||||
|
|
||||||
#include "basic_block.h"
|
#include "source/opt/basic_block.h"
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "mem_pass.h"
|
#include "source/opt/mem_pass.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -14,15 +14,13 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "dead_insert_elim_pass.h"
|
#include "source/opt/dead_insert_elim_pass.h"
|
||||||
|
|
||||||
#include "composite.h"
|
#include "source/opt/composite.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "iterator.h"
|
#include "source/opt/iterator.h"
|
||||||
#include "spirv/1.2/GLSL.std.450.h"
|
#include "spirv/1.2/GLSL.std.450.h"
|
||||||
|
|
||||||
#include <vector>
|
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
|
||||||
|
@ -22,12 +22,13 @@
|
|||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
#include <vector>
|
||||||
|
|
||||||
#include "basic_block.h"
|
#include "source/opt/basic_block.h"
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "mem_pass.h"
|
#include "source/opt/mem_pass.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,10 +12,12 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "dead_variable_elimination.h"
|
#include "source/opt/dead_variable_elimination.h"
|
||||||
|
|
||||||
#include "ir_context.h"
|
#include <vector>
|
||||||
#include "reflect.h"
|
|
||||||
|
#include "source/opt/ir_context.h"
|
||||||
|
#include "source/opt/reflect.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -18,8 +18,8 @@
|
|||||||
#include <climits>
|
#include <climits>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
|
|
||||||
#include "decoration_manager.h"
|
#include "source/opt/decoration_manager.h"
|
||||||
#include "mem_pass.h"
|
#include "source/opt/mem_pass.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,13 +12,15 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "decoration_manager.h"
|
#include "source/opt/decoration_manager.h"
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
#include <memory>
|
||||||
#include <set>
|
#include <set>
|
||||||
#include <stack>
|
#include <stack>
|
||||||
|
#include <utility>
|
||||||
|
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -20,8 +20,8 @@
|
|||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "instruction.h"
|
#include "source/opt/instruction.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,12 +12,12 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
|
||||||
#include "log.h"
|
#include "source/opt/log.h"
|
||||||
#include "reflect.h"
|
#include "source/opt/reflect.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -18,10 +18,11 @@
|
|||||||
#include <list>
|
#include <list>
|
||||||
#include <set>
|
#include <set>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "instruction.h"
|
#include "source/opt/instruction.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
#include "spirv-tools/libspirv.hpp"
|
#include "spirv-tools/libspirv.hpp"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
|
@ -12,11 +12,11 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "dominator_analysis.h"
|
#include "source/opt/dominator_analysis.h"
|
||||||
|
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
|
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
#include <map>
|
#include <map>
|
||||||
|
|
||||||
#include "dominator_tree.h"
|
#include "source/opt/dominator_tree.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -16,9 +16,9 @@
|
|||||||
#include <memory>
|
#include <memory>
|
||||||
#include <set>
|
#include <set>
|
||||||
|
|
||||||
#include "cfa.h"
|
#include "source/cfa.h"
|
||||||
#include "dominator_tree.h"
|
#include "source/opt/dominator_tree.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
// Calculates the dominator or postdominator tree for a given function.
|
// Calculates the dominator or postdominator tree for a given function.
|
||||||
// 1 - Compute the successors and predecessors for each BasicBlock. We add a
|
// 1 - Compute the successors and predecessors for each BasicBlock. We add a
|
||||||
|
@ -21,8 +21,8 @@
|
|||||||
#include <utility>
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "cfg.h"
|
#include "source/opt/cfg.h"
|
||||||
#include "tree_iterator.h"
|
#include "source/opt/tree_iterator.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,16 +12,17 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "eliminate_dead_constant_pass.h"
|
#include "source/opt/eliminate_dead_constant_pass.h"
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
|
#include <vector>
|
||||||
|
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "log.h"
|
#include "source/opt/log.h"
|
||||||
#include "reflect.h"
|
#include "source/opt/reflect.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -15,9 +15,9 @@
|
|||||||
#ifndef SOURCE_OPT_ELIMINATE_DEAD_CONSTANT_PASS_H_
|
#ifndef SOURCE_OPT_ELIMINATE_DEAD_CONSTANT_PASS_H_
|
||||||
#define SOURCE_OPT_ELIMINATE_DEAD_CONSTANT_PASS_H_
|
#define SOURCE_OPT_ELIMINATE_DEAD_CONSTANT_PASS_H_
|
||||||
|
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
#include "pass.h"
|
#include "source/opt/pass.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,11 +12,12 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "eliminate_dead_functions_pass.h"
|
#include "source/opt/eliminate_dead_functions_pass.h"
|
||||||
#include "ir_context.h"
|
|
||||||
|
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
|
|
||||||
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
|
||||||
|
@ -15,10 +15,10 @@
|
|||||||
#ifndef SOURCE_OPT_ELIMINATE_DEAD_FUNCTIONS_PASS_H_
|
#ifndef SOURCE_OPT_ELIMINATE_DEAD_FUNCTIONS_PASS_H_
|
||||||
#define SOURCE_OPT_ELIMINATE_DEAD_FUNCTIONS_PASS_H_
|
#define SOURCE_OPT_ELIMINATE_DEAD_FUNCTIONS_PASS_H_
|
||||||
|
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "function.h"
|
#include "source/opt/function.h"
|
||||||
#include "mem_pass.h"
|
#include "source/opt/mem_pass.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,11 +12,13 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "feature_manager.h"
|
#include "source/opt/feature_manager.h"
|
||||||
|
|
||||||
#include <queue>
|
#include <queue>
|
||||||
#include <stack>
|
#include <stack>
|
||||||
|
#include <string>
|
||||||
|
|
||||||
#include "enum_string_mapping.h"
|
#include "source/enum_string_mapping.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -15,9 +15,9 @@
|
|||||||
#ifndef SOURCE_OPT_FEATURE_MANAGER_H_
|
#ifndef SOURCE_OPT_FEATURE_MANAGER_H_
|
||||||
#define SOURCE_OPT_FEATURE_MANAGER_H_
|
#define SOURCE_OPT_FEATURE_MANAGER_H_
|
||||||
|
|
||||||
#include "assembly_grammar.h"
|
#include "source/assembly_grammar.h"
|
||||||
#include "extensions.h"
|
#include "source/extensions.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,14 +12,17 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "flatten_decoration_pass.h"
|
#include "source/opt/flatten_decoration_pass.h"
|
||||||
#include "ir_context.h"
|
|
||||||
|
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
|
#include <memory>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
|
||||||
|
@ -15,9 +15,9 @@
|
|||||||
#ifndef SOURCE_OPT_FLATTEN_DECORATION_PASS_H_
|
#ifndef SOURCE_OPT_FLATTEN_DECORATION_PASS_H_
|
||||||
#define SOURCE_OPT_FLATTEN_DECORATION_PASS_H_
|
#define SOURCE_OPT_FLATTEN_DECORATION_PASS_H_
|
||||||
|
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
#include "pass.h"
|
#include "source/opt/pass.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,17 +12,17 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "fold.h"
|
#include "source/opt/fold.h"
|
||||||
|
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "const_folding_rules.h"
|
#include "source/opt/const_folding_rules.h"
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "folding_rules.h"
|
#include "source/opt/folding_rules.h"
|
||||||
#include "ir_builder.h"
|
#include "source/opt/ir_builder.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -18,10 +18,10 @@
|
|||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "const_folding_rules.h"
|
#include "source/opt/const_folding_rules.h"
|
||||||
#include "constants.h"
|
#include "source/opt/constants.h"
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "folding_rules.h"
|
#include "source/opt/folding_rules.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,16 +12,16 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "fold_spec_constant_op_and_composite_pass.h"
|
#include "source/opt/fold_spec_constant_op_and_composite_pass.h"
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <initializer_list>
|
#include <initializer_list>
|
||||||
#include <tuple>
|
#include <tuple>
|
||||||
|
|
||||||
#include "constants.h"
|
#include "source/opt/constants.h"
|
||||||
#include "fold.h"
|
#include "source/opt/fold.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "make_unique.h"
|
#include "source/opt/make_unique.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -19,12 +19,12 @@
|
|||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "constants.h"
|
#include "source/opt/constants.h"
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
#include "pass.h"
|
#include "source/opt/pass.h"
|
||||||
#include "type_manager.h"
|
#include "source/opt/type_manager.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,12 +12,14 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "folding_rules.h"
|
#include "source/opt/folding_rules.h"
|
||||||
|
|
||||||
#include <limits>
|
#include <limits>
|
||||||
|
#include <memory>
|
||||||
|
#include <utility>
|
||||||
|
|
||||||
#include "ir_context.h"
|
#include "source/latest_version_glsl_std_450_header.h"
|
||||||
#include "latest_version_glsl_std_450_header.h"
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -16,9 +16,10 @@
|
|||||||
#define SOURCE_OPT_FOLDING_RULES_H_
|
#define SOURCE_OPT_FOLDING_RULES_H_
|
||||||
|
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
|
#include <unordered_map>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "constants.h"
|
#include "source/opt/constants.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,8 +12,8 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "freeze_spec_constant_value_pass.h"
|
#include "source/opt/freeze_spec_constant_value_pass.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -15,9 +15,9 @@
|
|||||||
#ifndef SOURCE_OPT_FREEZE_SPEC_CONSTANT_VALUE_PASS_H_
|
#ifndef SOURCE_OPT_FREEZE_SPEC_CONSTANT_VALUE_PASS_H_
|
||||||
#define SOURCE_OPT_FREEZE_SPEC_CONSTANT_VALUE_PASS_H_
|
#define SOURCE_OPT_FREEZE_SPEC_CONSTANT_VALUE_PASS_H_
|
||||||
|
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
#include "pass.h"
|
#include "source/opt/pass.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "function.h"
|
#include "source/opt/function.h"
|
||||||
|
|
||||||
#include <ostream>
|
#include <ostream>
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
|
@ -18,12 +18,13 @@
|
|||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <functional>
|
#include <functional>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
#include <string>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "basic_block.h"
|
#include "source/opt/basic_block.h"
|
||||||
#include "instruction.h"
|
#include "source/opt/instruction.h"
|
||||||
#include "iterator.h"
|
#include "source/opt/iterator.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,9 +12,12 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "if_conversion.h"
|
#include "source/opt/if_conversion.h"
|
||||||
|
|
||||||
#include "value_number_table.h"
|
#include <memory>
|
||||||
|
#include <vector>
|
||||||
|
|
||||||
|
#include "source/opt/value_number_table.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -15,10 +15,10 @@
|
|||||||
#ifndef SOURCE_OPT_IF_CONVERSION_H_
|
#ifndef SOURCE_OPT_IF_CONVERSION_H_
|
||||||
#define SOURCE_OPT_IF_CONVERSION_H_
|
#define SOURCE_OPT_IF_CONVERSION_H_
|
||||||
|
|
||||||
#include "basic_block.h"
|
#include "source/opt/basic_block.h"
|
||||||
#include "ir_builder.h"
|
#include "source/opt/ir_builder.h"
|
||||||
#include "pass.h"
|
#include "source/opt/pass.h"
|
||||||
#include "types.h"
|
#include "source/opt/types.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -14,7 +14,9 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "inline_exhaustive_pass.h"
|
#include "source/opt/inline_exhaustive_pass.h"
|
||||||
|
|
||||||
|
#include <utility>
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -23,9 +23,9 @@
|
|||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "inline_pass.h"
|
#include "source/opt/inline_pass.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -14,11 +14,12 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "inline_opaque_pass.h"
|
#include "source/opt/inline_opaque_pass.h"
|
||||||
|
|
||||||
|
#include <utility>
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
const uint32_t kTypePointerTypeIdInIdx = 1;
|
const uint32_t kTypePointerTypeIdInIdx = 1;
|
||||||
|
@ -23,9 +23,9 @@
|
|||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "def_use_manager.h"
|
#include "source/opt/def_use_manager.h"
|
||||||
#include "inline_pass.h"
|
#include "source/opt/inline_pass.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -14,9 +14,12 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "inline_pass.h"
|
#include "source/opt/inline_pass.h"
|
||||||
|
|
||||||
#include "cfa.h"
|
#include <unordered_set>
|
||||||
|
#include <utility>
|
||||||
|
|
||||||
|
#include "source/cfa.h"
|
||||||
|
|
||||||
// Indices of operands in SPIR-V instructions
|
// Indices of operands in SPIR-V instructions
|
||||||
|
|
||||||
|
@ -20,12 +20,13 @@
|
|||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <list>
|
#include <list>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
#include <set>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "decoration_manager.h"
|
#include "source/opt/decoration_manager.h"
|
||||||
#include "module.h"
|
#include "source/opt/module.h"
|
||||||
#include "pass.h"
|
#include "source/opt/pass.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
@ -12,14 +12,14 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include "instruction.h"
|
#include "source/opt/instruction.h"
|
||||||
|
|
||||||
#include <initializer_list>
|
#include <initializer_list>
|
||||||
|
|
||||||
#include "disassemble.h"
|
#include "source/disassemble.h"
|
||||||
#include "fold.h"
|
#include "source/opt/fold.h"
|
||||||
#include "ir_context.h"
|
#include "source/opt/ir_context.h"
|
||||||
#include "reflect.h"
|
#include "source/opt/reflect.h"
|
||||||
|
|
||||||
namespace spvtools {
|
namespace spvtools {
|
||||||
namespace opt {
|
namespace opt {
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user