diff options
| author | Alessandro Gatti <a.gatti@frob.it> | 2025-06-26 21:56:26 +0200 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2025-07-04 16:07:04 +1000 |
| commit | 2ab06b61b3f60e42cda250203bda31667ecef043 (patch) | |
| tree | d7e55a12b6c38bf69beef98922f359339c825edb /py/asmx86.h | |
| parent | 3a97175f5f7023d9f8db37c21e0c04174df0f205 (diff) | |
py/emitnative: Let emitters know the compiled entity's name.
This commit introduces an optional feature to provide to native emitters
the fully qualified name of the entity they are compiling.
This is achieved by altering the generic ASM API to provide a third
argument to the entry function, containing the name of the entity being
compiled. Currently only the debug emitter uses this feature, as it is
not really useful for other emitters for the time being; in fact the
macros in question just strip the name away.
Signed-off-by: Alessandro Gatti <a.gatti@frob.it>
Diffstat (limited to 'py/asmx86.h')
| -rw-r--r-- | py/asmx86.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/py/asmx86.h b/py/asmx86.h index 2cec38ed4..d2e078ad5 100644 --- a/py/asmx86.h +++ b/py/asmx86.h @@ -149,12 +149,12 @@ void asm_x86_call_ind(asm_x86_t *as, size_t fun_id, mp_uint_t n_args, int temp_r // Holds a pointer to mp_fun_table #define REG_FUN_TABLE ASM_X86_REG_FUN_TABLE -#define ASM_T asm_x86_t -#define ASM_END_PASS asm_x86_end_pass -#define ASM_ENTRY asm_x86_entry -#define ASM_EXIT asm_x86_exit +#define ASM_T asm_x86_t +#define ASM_END_PASS asm_x86_end_pass +#define ASM_ENTRY(as, num_locals, name) asm_x86_entry((as), (num_locals)) +#define ASM_EXIT asm_x86_exit -#define ASM_JUMP asm_x86_jmp_label +#define ASM_JUMP asm_x86_jmp_label #define ASM_JUMP_IF_REG_ZERO(as, reg, label, bool_test) \ do { \ if (bool_test) { \ |
