mirror of
https://github.com/yuzu-emu/unicorn.git
synced 2025-01-22 03:11:09 +00:00
qlit: rename compare_litqobj_to_qobj() to qlit_equal_qobject()
compare_litqobj_to_qobj() lacks a qlit_ prefix. Moreover, "compare" suggests -1, 0, +1 for less than, equal and greater than. The function actually returns non-zero for equal, zero for unequal. Rename to qlit_equal_qobject(). Its return type will be cleaned up in the next patch. Backports commit 60cc2eb7afd40b9cbaa35a5e0b54f365ac6e49f1 from qemu
This commit is contained in:
parent
b462c3929f
commit
c51622c4ce
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_aarch64
|
||||
#define qlist_size_iter qlist_size_iter_aarch64
|
||||
#define qlist_type qlist_type_aarch64
|
||||
#define qlit_equal_qobject qlit_equal_qobject_aarch64
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_aarch64
|
||||
#define qobject_input_end_list qobject_input_end_list_aarch64
|
||||
#define qobject_input_end_struct qobject_input_end_struct_aarch64
|
||||
|
|
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_aarch64eb
|
||||
#define qlist_size_iter qlist_size_iter_aarch64eb
|
||||
#define qlist_type qlist_type_aarch64eb
|
||||
#define qlit_equal_qobject qlit_equal_qobject_aarch64eb
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_aarch64eb
|
||||
#define qobject_input_end_list qobject_input_end_list_aarch64eb
|
||||
#define qobject_input_end_struct qobject_input_end_struct_aarch64eb
|
||||
|
|
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_arm
|
||||
#define qlist_size_iter qlist_size_iter_arm
|
||||
#define qlist_type qlist_type_arm
|
||||
#define qlit_equal_qobject qlit_equal_qobject_arm
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_arm
|
||||
#define qobject_input_end_list qobject_input_end_list_arm
|
||||
#define qobject_input_end_struct qobject_input_end_struct_arm
|
||||
|
|
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_armeb
|
||||
#define qlist_size_iter qlist_size_iter_armeb
|
||||
#define qlist_type qlist_type_armeb
|
||||
#define qlit_equal_qobject qlit_equal_qobject_armeb
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_armeb
|
||||
#define qobject_input_end_list qobject_input_end_list_armeb
|
||||
#define qobject_input_end_struct qobject_input_end_struct_armeb
|
||||
|
|
|
@ -230,7 +230,6 @@ symbols = (
|
|||
'commonNaNToFloat32',
|
||||
'commonNaNToFloat64',
|
||||
'commonNaNToFloatx80',
|
||||
'compare_litqobj_to_qobj',
|
||||
'compute_abs_deadline',
|
||||
'cond_name',
|
||||
'configure_accelerator',
|
||||
|
@ -2819,6 +2818,7 @@ symbols = (
|
|||
'qlist_size',
|
||||
'qlist_size_iter',
|
||||
'qlist_type',
|
||||
'qlit_equal_qobject',
|
||||
'qobject_input_end_implicit_struct',
|
||||
'qobject_input_end_list',
|
||||
'qobject_input_end_struct',
|
||||
|
|
|
@ -44,6 +44,6 @@ struct QLitDictEntry {
|
|||
#define QLIT_QLIST(val) \
|
||||
{ .type = QTYPE_QLIST, .value.qlist = (val) }
|
||||
|
||||
int compare_litqobj_to_qobj(QLitObject *lhs, QObject *rhs);
|
||||
int qlit_equal_qobject(QLitObject *lhs, QObject *rhs);
|
||||
|
||||
#endif /* QLIT_H */
|
||||
|
|
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_m68k
|
||||
#define qlist_size_iter qlist_size_iter_m68k
|
||||
#define qlist_type qlist_type_m68k
|
||||
#define qlit_equal_qobject qlit_equal_qobject_m68k
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_m68k
|
||||
#define qobject_input_end_list qobject_input_end_list_m68k
|
||||
#define qobject_input_end_struct qobject_input_end_struct_m68k
|
||||
|
|
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_mips
|
||||
#define qlist_size_iter qlist_size_iter_mips
|
||||
#define qlist_type qlist_type_mips
|
||||
#define qlit_equal_qobject qlit_equal_qobject_mips
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_mips
|
||||
#define qobject_input_end_list qobject_input_end_list_mips
|
||||
#define qobject_input_end_struct qobject_input_end_struct_mips
|
||||
|
|
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_mips64
|
||||
#define qlist_size_iter qlist_size_iter_mips64
|
||||
#define qlist_type qlist_type_mips64
|
||||
#define qlit_equal_qobject qlit_equal_qobject_mips64
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_mips64
|
||||
#define qobject_input_end_list qobject_input_end_list_mips64
|
||||
#define qobject_input_end_struct qobject_input_end_struct_mips64
|
||||
|
|
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_mips64el
|
||||
#define qlist_size_iter qlist_size_iter_mips64el
|
||||
#define qlist_type qlist_type_mips64el
|
||||
#define qlit_equal_qobject qlit_equal_qobject_mips64el
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_mips64el
|
||||
#define qobject_input_end_list qobject_input_end_list_mips64el
|
||||
#define qobject_input_end_struct qobject_input_end_struct_mips64el
|
||||
|
|
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_mipsel
|
||||
#define qlist_size_iter qlist_size_iter_mipsel
|
||||
#define qlist_type qlist_type_mipsel
|
||||
#define qlit_equal_qobject qlit_equal_qobject_mipsel
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_mipsel
|
||||
#define qobject_input_end_list qobject_input_end_list_mipsel
|
||||
#define qobject_input_end_struct qobject_input_end_struct_mipsel
|
||||
|
|
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_powerpc
|
||||
#define qlist_size_iter qlist_size_iter_powerpc
|
||||
#define qlist_type qlist_type_powerpc
|
||||
#define qlit_equal_qobject qlit_equal_qobject_powerpc
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_powerpc
|
||||
#define qobject_input_end_list qobject_input_end_list_powerpc
|
||||
#define qobject_input_end_struct qobject_input_end_struct_powerpc
|
||||
|
|
|
@ -42,10 +42,10 @@ static void compare_helper(QObject *obj, void *opaque)
|
|||
}
|
||||
|
||||
helper->result =
|
||||
compare_litqobj_to_qobj(&helper->objs[helper->index++], obj);
|
||||
qlit_equal_qobject(&helper->objs[helper->index++], obj);
|
||||
}
|
||||
|
||||
int compare_litqobj_to_qobj(QLitObject *lhs, QObject *rhs)
|
||||
int qlit_equal_qobject(QLitObject *lhs, QObject *rhs)
|
||||
{
|
||||
int64_t val;
|
||||
|
||||
|
@ -67,7 +67,7 @@ int compare_litqobj_to_qobj(QLitObject *lhs, QObject *rhs)
|
|||
QObject *obj = qdict_get(qobject_to_qdict(rhs),
|
||||
lhs->value.qdict[i].key);
|
||||
|
||||
if (!compare_litqobj_to_qobj(&lhs->value.qdict[i].value, obj)) {
|
||||
if (!qlit_equal_qobject(&lhs->value.qdict[i].value, obj)) {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_sparc
|
||||
#define qlist_size_iter qlist_size_iter_sparc
|
||||
#define qlist_type qlist_type_sparc
|
||||
#define qlit_equal_qobject qlit_equal_qobject_sparc
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_sparc
|
||||
#define qobject_input_end_list qobject_input_end_list_sparc
|
||||
#define qobject_input_end_struct qobject_input_end_struct_sparc
|
||||
|
|
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_sparc64
|
||||
#define qlist_size_iter qlist_size_iter_sparc64
|
||||
#define qlist_type qlist_type_sparc64
|
||||
#define qlit_equal_qobject qlit_equal_qobject_sparc64
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_sparc64
|
||||
#define qobject_input_end_list qobject_input_end_list_sparc64
|
||||
#define qobject_input_end_struct qobject_input_end_struct_sparc64
|
||||
|
|
|
@ -2812,6 +2812,7 @@
|
|||
#define qlist_size qlist_size_x86_64
|
||||
#define qlist_size_iter qlist_size_iter_x86_64
|
||||
#define qlist_type qlist_type_x86_64
|
||||
#define qlit_equal_qobject qlit_equal_qobject_x86_64
|
||||
#define qobject_input_end_implicit_struct qobject_input_end_implicit_struct_x86_64
|
||||
#define qobject_input_end_list qobject_input_end_list_x86_64
|
||||
#define qobject_input_end_struct qobject_input_end_struct_x86_64
|
||||
|
|
Loading…
Reference in a new issue