diff options
Diffstat (limited to 'src/arch/instruction.c')
-rw-r--r-- | src/arch/instruction.c | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/src/arch/instruction.c b/src/arch/instruction.c index d6bf183..d9d7693 100644 --- a/src/arch/instruction.c +++ b/src/arch/instruction.c @@ -52,7 +52,7 @@ static void g_arch_instruction_finalize(GArchInstruction *); /* Ajoute à un tampon GLib le contenu de l'instance spécifiée. */ -static GBufferLine *_g_arch_instruction_print(const GArchInstruction *, GCodeBuffer *, MemoryDataSize, const bin_t *, AsmSyntax); +static GBufferLine *_g_arch_instruction_print(const GArchInstruction *, GCodeBuffer *, MemoryDataSize, const GBinContent *, AsmSyntax); @@ -317,7 +317,7 @@ const mrange_t *g_arch_instruction_get_range(const GArchInstruction *instr) void g_arch_instruction_get_location(const GArchInstruction *instr, off_t *offset, off_t *length, vmpa_t *address) { if (offset != NULL) *offset = instr->offset; - if (length != NULL) *length = instr->length; + //if (length != NULL) *length = instr->length; if (address != NULL) *address = instr->address; @@ -833,10 +833,11 @@ const char *g_arch_instruction_get_keyword(const GArchInstruction *instr, AsmSyn /****************************************************************************** * * -* Paramètres : instr = instruction d'assemblage à représenter. * -* buffer = espace où placer ledit contenu. * -* msize = taille idéale des positions et adresses; * -* syntax = type de représentation demandée. * +* Paramètres : instr = instruction d'assemblage à représenter. * +* buffer = espace où placer ledit contenu. * +* msize = taille idéale des positions et adresses; * +* content = contenu binaire global à venir lire. * +* syntax = type de représentation demandée. * * * * Description : Ajoute à un tampon GLib le contenu de l'instance spécifiée. * * * @@ -846,7 +847,7 @@ const char *g_arch_instruction_get_keyword(const GArchInstruction *instr, AsmSyn * * ******************************************************************************/ -static GBufferLine *_g_arch_instruction_print(const GArchInstruction *instr, GCodeBuffer *buffer, MemoryDataSize msize, const bin_t *content, AsmSyntax syntax) +static GBufferLine *_g_arch_instruction_print(const GArchInstruction *instr, GCodeBuffer *buffer, MemoryDataSize msize, const GBinContent *content, AsmSyntax syntax) { GBufferLine *result; /* Ligne de destination */ const char *key; /* Mot clef principal */ @@ -857,8 +858,7 @@ static GBufferLine *_g_arch_instruction_print(const GArchInstruction *instr, GCo g_buffer_line_add_flag(result, BLF_HAS_CODE); - g_buffer_line_fill_for_instr(result, msize/* TODO ! */, msize, - content, get_mrange_length(&instr->range), true); + g_buffer_line_fill_for_instr(result, msize/* TODO ! */, msize, content, true); /* Instruction proprement dite */ @@ -892,6 +892,7 @@ static GBufferLine *_g_arch_instruction_print(const GArchInstruction *instr, GCo * Paramètres : instr = instruction d'assemblage à représenter. * * buffer = espace où placer ledit contenu. * * msize = taille idéale des positions et adresses; * +* content = contenu binaire global à venir lire. * * syntax = type de représentation demandée. * * * * Description : Ajoute à un tampon GLib le contenu de l'instance spécifiée. * @@ -902,7 +903,7 @@ static GBufferLine *_g_arch_instruction_print(const GArchInstruction *instr, GCo * * ******************************************************************************/ -GBufferLine *g_arch_instruction_print(const GArchInstruction *instr, GCodeBuffer *buffer, MemoryDataSize msize, const bin_t *content, AsmSyntax syntax) +GBufferLine *g_arch_instruction_print(const GArchInstruction *instr, GCodeBuffer *buffer, MemoryDataSize msize, const GBinContent *content, AsmSyntax syntax) { return G_ARCH_INSTRUCTION_GET_CLASS(instr)->print(instr, buffer, msize, content, syntax); |