From 696bf0db0fce872684b3e27f8767fe5aa62b1347 Mon Sep 17 00:00:00 2001 From: Bill Hollings Date: Wed, 8 Nov 2017 13:54:28 -0500 Subject: [PATCH] Fixes from review #2 of PR 321. --- spirv_cross.hpp | 4 +++- spirv_msl.cpp | 2 +- spirv_msl.hpp | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/spirv_cross.hpp b/spirv_cross.hpp index e758f1da..7d2fb9cb 100644 --- a/spirv_cross.hpp +++ b/spirv_cross.hpp @@ -266,7 +266,9 @@ public: // Returns a mapping between the original entry point name in the SPIR-V and a modified // name defined by the backend. Some backends (eg. MSL) restrict the legal names allowed - // for entry point names (eg. "main" is illegal in MSL). + // for entry point names (eg. "main" is illegal in MSL). Renaming occurs during compile(). + // Calling this function after before compiling will return a map of the original names + // to those same original names. std::unordered_map get_entry_point_name_map() const; // Returns the internal data structure for entry points to allow poking around. diff --git a/spirv_msl.cpp b/spirv_msl.cpp index 80a14d74..5e732850 100644 --- a/spirv_msl.cpp +++ b/spirv_msl.cpp @@ -106,7 +106,7 @@ string CompilerMSL::compile() do { if (pass_count >= 3) - SPIRV_CROSS_THROW("Over 2 compilation loops detected. Must be a bug!"); + SPIRV_CROSS_THROW("Over 3 compilation loops detected. Must be a bug!"); reset(); diff --git a/spirv_msl.hpp b/spirv_msl.hpp index dc70ae66..78af8d25 100644 --- a/spirv_msl.hpp +++ b/spirv_msl.hpp @@ -18,12 +18,12 @@ #define SPIRV_CROSS_MSL_HPP #include "spirv_glsl.hpp" +#include #include #include #include #include #include -#include namespace spirv_cross {