| 74 | } |
| 75 | |
| 76 | SpecTest::CommandID resolveCommand(std::string_view Name) { |
| 77 | static const std::unordered_map<std::string_view, SpecTest::CommandID, |
| 78 | Hash::Hash> |
| 79 | CommandMapping = { |
| 80 | {"module"sv, SpecTest::CommandID::Module}, |
| 81 | {"module_definition"sv, SpecTest::CommandID::ModuleDefinition}, |
| 82 | {"module_instance"sv, SpecTest::CommandID::ModuleInstance}, |
| 83 | {"action"sv, SpecTest::CommandID::Action}, |
| 84 | {"register"sv, SpecTest::CommandID::Register}, |
| 85 | {"assert_return"sv, SpecTest::CommandID::AssertReturn}, |
| 86 | {"assert_trap"sv, SpecTest::CommandID::AssertTrap}, |
| 87 | {"assert_exhaustion"sv, SpecTest::CommandID::AssertExhaustion}, |
| 88 | {"assert_malformed"sv, SpecTest::CommandID::AssertMalformed}, |
| 89 | {"assert_invalid"sv, SpecTest::CommandID::AssertInvalid}, |
| 90 | {"assert_unlinkable"sv, SpecTest::CommandID::AssertUnlinkable}, |
| 91 | {"assert_uninstantiable"sv, |
| 92 | SpecTest::CommandID::AssertUninstantiable}, |
| 93 | {"assert_exception"sv, SpecTest::CommandID::AssertException}, |
| 94 | {"thread"sv, SpecTest::CommandID::Thread}, |
| 95 | {"wait"sv, SpecTest::CommandID::Wait}, |
| 96 | }; |
| 97 | if (auto Iter = CommandMapping.find(Name); Iter != CommandMapping.end()) { |
| 98 | return Iter->second; |
| 99 | } |
| 100 | return SpecTest::CommandID::Unknown; |
| 101 | } |
| 102 | |
| 103 | template <typename T, size_t N = sizeof(T)> |
| 104 | static void parseSIMDLanes(WasmEdge::uint128_t &V128, |
no test coverage detected