Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Commit 0fdb42a

Browse files
author
Evgeny Pavlov
committed
Fix inlining of '__jit_debug_register_code' on ARM32 release build
1 parent c567999 commit 0fdb42a

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/vm/gdbjit.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,9 +167,10 @@ struct jit_descriptor
167167
struct jit_code_entry *relevant_entry;
168168
struct jit_code_entry *first_entry;
169169
};
170-
/* GDB puts a breakpoint in this function. */
170+
// GDB puts a breakpoint in this function.
171+
// To prevent from inlining we add noinline attribute and inline assembler statement.
171172
extern "C"
172-
void __attribute__((noinline)) __jit_debug_register_code() { };
173+
void __attribute__((noinline)) __jit_debug_register_code() { __asm__(""); };
173174

174175
/* Make sure to specify the version statically, because the
175176
debugger may check the version before we can set it. */

0 commit comments

Comments
 (0)