summaryrefslogtreecommitdiff
path: root/src/arch/arm/v7/operands
diff options
context:
space:
mode:
authorCyrille Bagard <nocbos@gmail.com>2016-10-23 16:22:50 (GMT)
committerCyrille Bagard <nocbos@gmail.com>2016-10-23 18:53:25 (GMT)
commit56f7524c4fd0fc14a509be7689f4820b31564dbc (patch)
tree9c84e11279cd5711a4e0af907ca6160b62317528 /src/arch/arm/v7/operands
parent3f05bacd4fec23824489b51d964a7ce3565bb85b (diff)
Deleted a level of data to reduce the memory fingerprint.
Diffstat (limited to 'src/arch/arm/v7/operands')
-rw-r--r--src/arch/arm/v7/operands/coproc.c2
-rw-r--r--src/arch/arm/v7/operands/estate.c4
-rw-r--r--src/arch/arm/v7/operands/limitation.c18
-rw-r--r--src/arch/arm/v7/operands/maccess.c16
-rw-r--r--src/arch/arm/v7/operands/offset.c2
-rw-r--r--src/arch/arm/v7/operands/reglist.c8
-rw-r--r--src/arch/arm/v7/operands/rotation.c4
-rw-r--r--src/arch/arm/v7/operands/shift.c12
8 files changed, 33 insertions, 33 deletions
diff --git a/src/arch/arm/v7/operands/coproc.c b/src/arch/arm/v7/operands/coproc.c
index c816b37..90f8874 100644
--- a/src/arch/arm/v7/operands/coproc.c
+++ b/src/arch/arm/v7/operands/coproc.c
@@ -197,7 +197,7 @@ static void g_armv7_coproc_operand_print(const GArmV7CoprocOperand *operand, GBu
nlen = snprintf(name, sizeof(name), "p%hhu", operand->index);
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, name, nlen, RTT_REGISTER);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, name, nlen, RTT_REGISTER, NULL);
}
diff --git a/src/arch/arm/v7/operands/estate.c b/src/arch/arm/v7/operands/estate.c
index 214508a..6f66832 100644
--- a/src/arch/arm/v7/operands/estate.c
+++ b/src/arch/arm/v7/operands/estate.c
@@ -193,9 +193,9 @@ GArchOperand *g_armv7_endian_operand_new(bool big)
static void g_armv7_endian_operand_print(const GArmV7EndianOperand *operand, GBufferLine *line, AsmSyntax syntax)
{
if (operand->big)
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "BE", 2, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "BE", 2, RTT_KEY_WORD, NULL);
else
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "LE", 2, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "LE", 2, RTT_KEY_WORD, NULL);
}
diff --git a/src/arch/arm/v7/operands/limitation.c b/src/arch/arm/v7/operands/limitation.c
index 4d1d661..5a5b567 100644
--- a/src/arch/arm/v7/operands/limitation.c
+++ b/src/arch/arm/v7/operands/limitation.c
@@ -199,39 +199,39 @@ static void g_armv7_limitation_operand_print(const GArmV7LimitationOperand *oper
switch (operand->type)
{
case BLT_SY:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "SY", 2, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "SY", 2, RTT_KEY_WORD, NULL);
break;
case BLT_ST:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "ST", 2, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "ST", 2, RTT_KEY_WORD, NULL);
break;
case BLT_ISH:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "ISH", 3, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "ISH", 3, RTT_KEY_WORD, NULL);
break;
case BLT_ISHST:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "ISHST", 5, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "ISHST", 5, RTT_KEY_WORD, NULL);
break;
case BLT_NSH:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "NSH", 3, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "NSH", 3, RTT_KEY_WORD, NULL);
break;
case BLT_NSHST:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "NSHST", 5, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "NSHST", 5, RTT_KEY_WORD, NULL);
break;
case BLT_OSH:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "OSH", 3, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "OSH", 3, RTT_KEY_WORD, NULL);
break;
case BLT_OSHST:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "OSHST", 5, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "OSHST", 5, RTT_KEY_WORD, NULL);
break;
default:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "(reserved)", 10, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "(reserved)", 10, RTT_KEY_WORD, NULL);
break;
}
diff --git a/src/arch/arm/v7/operands/maccess.c b/src/arch/arm/v7/operands/maccess.c
index 8eb5b57..10c8328 100644
--- a/src/arch/arm/v7/operands/maccess.c
+++ b/src/arch/arm/v7/operands/maccess.c
@@ -213,17 +213,17 @@ GArchOperand *g_armv7_maccess_operand_new(GArchOperand *base, GArchOperand *offs
static void g_armv7_maccess_operand_print(const GArmV7MAccessOperand *operand, GBufferLine *line, AsmSyntax syntax)
{
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "[", 1, RTT_HOOK);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "[", 1, RTT_HOOK, NULL);
g_arch_operand_print(operand->base, line, syntax);
if (!operand->not_post_indexed)
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "]", 1, RTT_HOOK);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "]", 1, RTT_HOOK, NULL);
if (operand->offset != NULL)
{
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, ",", 1, RTT_PUNCT);
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, " ", 1, RTT_RAW);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, ",", 1, RTT_PUNCT, NULL);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, " ", 1, RTT_RAW, NULL);
g_arch_operand_print(operand->offset, line, syntax);
@@ -231,18 +231,18 @@ static void g_armv7_maccess_operand_print(const GArmV7MAccessOperand *operand, G
if (operand->shift != NULL)
{
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, ",", 1, RTT_PUNCT);
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, " ", 1, RTT_RAW);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, ",", 1, RTT_PUNCT, NULL);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, " ", 1, RTT_RAW, NULL);
g_arch_operand_print(operand->shift, line, syntax);
}
if (operand->not_post_indexed)
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "]", 1, RTT_HOOK);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "]", 1, RTT_HOOK, NULL);
if (operand->write_back)
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "!", 1, RTT_PUNCT);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "!", 1, RTT_PUNCT, NULL);
}
diff --git a/src/arch/arm/v7/operands/offset.c b/src/arch/arm/v7/operands/offset.c
index 9a9506a..03d69d8 100644
--- a/src/arch/arm/v7/operands/offset.c
+++ b/src/arch/arm/v7/operands/offset.c
@@ -198,7 +198,7 @@ GArchOperand *g_armv7_offset_operand_new(bool positive, GArchOperand *value)
static void g_armv7_offset_operand_print(const GArmV7OffsetOperand *operand, GBufferLine *line, AsmSyntax syntax)
{
if (!operand->positive)
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "-", 1, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "-", 1, RTT_KEY_WORD, NULL);
g_arch_operand_print(operand->value, line, syntax);
diff --git a/src/arch/arm/v7/operands/reglist.c b/src/arch/arm/v7/operands/reglist.c
index a54d148..7ad72d0 100644
--- a/src/arch/arm/v7/operands/reglist.c
+++ b/src/arch/arm/v7/operands/reglist.c
@@ -206,21 +206,21 @@ static void g_armv7_reglist_operand_print(const GArmV7RegListOperand *operand, G
{
size_t i; /* Boucle de parcours */
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "{", 1, RTT_HOOK);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "{", 1, RTT_HOOK, NULL);
for (i = 0; i < operand->count; i++)
{
if (i > 0)
{
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, ",", 1, RTT_PUNCT);
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, " ", 1, RTT_RAW);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, ",", 1, RTT_PUNCT, NULL);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, " ", 1, RTT_RAW, NULL);
}
g_arch_register_print(G_ARCH_REGISTER(operand->registers[i]), line, syntax);
}
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "}", 1, RTT_HOOK);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "}", 1, RTT_HOOK, NULL);
}
diff --git a/src/arch/arm/v7/operands/rotation.c b/src/arch/arm/v7/operands/rotation.c
index 1532270..22f53c3 100644
--- a/src/arch/arm/v7/operands/rotation.c
+++ b/src/arch/arm/v7/operands/rotation.c
@@ -194,9 +194,9 @@ GArchOperand *g_armv7_rotation_operand_new(GArchOperand *value)
static void g_armv7_rotation_operand_print(const GArmV7RotationOperand *operand, GBufferLine *line, AsmSyntax syntax)
{
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "ror", 3, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "ror", 3, RTT_KEY_WORD, NULL);
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, " ", 1, RTT_RAW);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, " ", 1, RTT_RAW, NULL);
g_arch_operand_print(operand->value, line, syntax);
diff --git a/src/arch/arm/v7/operands/shift.c b/src/arch/arm/v7/operands/shift.c
index 7a90a70..9a9035c 100644
--- a/src/arch/arm/v7/operands/shift.c
+++ b/src/arch/arm/v7/operands/shift.c
@@ -199,23 +199,23 @@ static void g_armv7_shift_operand_print(const GArmV7ShiftOperand *operand, GBuff
switch (operand->shift_type)
{
case SRType_LSL:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "lsl", 3, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "lsl", 3, RTT_KEY_WORD, NULL);
break;
case SRType_LSR:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "lsr", 3, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "lsr", 3, RTT_KEY_WORD, NULL);
break;
case SRType_ASR:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "asr", 3, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "asr", 3, RTT_KEY_WORD, NULL);
break;
case SRType_ROR:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "ror", 3, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "ror", 3, RTT_KEY_WORD, NULL);
break;
case SRType_RRX:
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, "rrx", 3, RTT_KEY_WORD);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, "rrx", 3, RTT_KEY_WORD, NULL);
break;
}
- g_buffer_line_insert_text(line, BLC_ASSEMBLY, " ", 1, RTT_RAW);
+ g_buffer_line_append_text(line, BLC_ASSEMBLY, " ", 1, RTT_RAW, NULL);
g_arch_operand_print(operand->shift_value, line, syntax);