mirror of
https://github.com/bytecodealliance/wasm-micro-runtime.git
synced 2025-05-09 21:26:21 +00:00
wasm_runtime_start_debug_instance: Don't create debug instance for AOT (#1395)
This commit is contained in:
parent
0ec99e9522
commit
ccd664b81e
|
@ -506,9 +506,17 @@ wasm_runtime_is_xip_file(const uint8 *buf, uint32 size)
|
||||||
uint32
|
uint32
|
||||||
wasm_runtime_start_debug_instance(WASMExecEnv *exec_env)
|
wasm_runtime_start_debug_instance(WASMExecEnv *exec_env)
|
||||||
{
|
{
|
||||||
|
WASMModuleInstanceCommon *module_inst =
|
||||||
|
wasm_runtime_get_module_inst(exec_env);
|
||||||
WASMCluster *cluster = wasm_exec_env_get_cluster(exec_env);
|
WASMCluster *cluster = wasm_exec_env_get_cluster(exec_env);
|
||||||
|
bh_assert(module_inst);
|
||||||
bh_assert(cluster);
|
bh_assert(cluster);
|
||||||
|
|
||||||
|
if (module_inst->module_type != Wasm_Module_Bytecode) {
|
||||||
|
LOG_WARNING("Attempt to create a debug instance for an AOT module");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
if (cluster->debug_inst) {
|
if (cluster->debug_inst) {
|
||||||
LOG_WARNING("Cluster already bind to a debug instance");
|
LOG_WARNING("Cluster already bind to a debug instance");
|
||||||
return cluster->debug_inst->control_thread->port;
|
return cluster->debug_inst->control_thread->port;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user