#include <stdint.h>1#include <stdlib.h>23#define CONCAT2(a, b) a##b4#define CONCAT(a, b) CONCAT2(a, b)5#define VERSIONED_SYMBOL(a) CONCAT(a, VERSIONED_SUFFIX)67#ifdef CFG_TARGET_OS_windows8// export required for external access.9__declspec(dllexport)10#else11// Note the `weak` linkage here, though, which is intended to let other code12// override this symbol if it's defined elsewhere, since this definition doesn't13// matter.14// Just in case cross-language LTO is enabled we set the `noinline` attribute15// and also try to have some sort of side effect in this function with a dummy16// `asm` statement.17__attribute__((weak, noinline))18#endif19void __jit_debug_register_code() {20#ifndef CFG_TARGET_OS_windows21__asm__("");22#endif23}2425struct JITDescriptor {26uint32_t version_;27uint32_t action_flag_;28void *relevant_entry_;29void *first_entry_;30};3132#ifdef CFG_TARGET_OS_windows33// export required for external access.34__declspec(dllexport)35#else36// Note the `weak` linkage here which is the same purpose as above. We want to37// let other runtimes be able to override this since our own definition isn't38// important.39__attribute__((weak))40#endif41struct JITDescriptor __jit_debug_descriptor = {1, 0, NULL, NULL};4243struct JITDescriptor *VERSIONED_SYMBOL(wasmtime_jit_debug_descriptor)() {44return &__jit_debug_descriptor;45}464748