mirror of
https://github.com/JakeHillion/object-introspection.git
synced 2024-11-12 21:56:54 +00:00
Update drgn submodule
Adds support for C++ member functions and virtuality.
This commit is contained in:
parent
ab499f6b83
commit
aef8826a3a
2
.gitmodules
vendored
2
.gitmodules
vendored
@ -1,6 +1,6 @@
|
|||||||
[submodule "extern/drgn"]
|
[submodule "extern/drgn"]
|
||||||
path = extern/drgn
|
path = extern/drgn
|
||||||
url = https://github.com/JakeHillion/drgn.git
|
url = https://github.com/ajor/drgn.git
|
||||||
[submodule "extern/folly"]
|
[submodule "extern/folly"]
|
||||||
path = extern/folly
|
path = extern/folly
|
||||||
url = https://github.com/jgkamat/folly.git
|
url = https://github.com/jgkamat/folly.git
|
||||||
|
2
extern/drgn
vendored
2
extern/drgn
vendored
@ -1 +1 @@
|
|||||||
Subproject commit 4a5b6279798c5625f68382baaba5f565aa798830
|
Subproject commit e3425c1ceb29d52cfc52e37de8763a6a4aa483eb
|
@ -226,10 +226,6 @@ void serialize(Archive &ar, struct drgn_type &type,
|
|||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
verify_version<struct drgn_type>(version);
|
verify_version<struct drgn_type>(version);
|
||||||
// We want to ensure that if the definition of `struct drgn_type` is changed
|
|
||||||
// at any point in the future that our code stops compiling, instead of us
|
|
||||||
// silently ignoring any newly added fields.
|
|
||||||
static_assert(sizeof(type) == 120);
|
|
||||||
|
|
||||||
// Ensure any unused fields are zeroed out for safety, as to avoid subtle
|
// Ensure any unused fields are zeroed out for safety, as to avoid subtle
|
||||||
// bugs resulting from mistakenly unserialized fields containing garbage.
|
// bugs resulting from mistakenly unserialized fields containing garbage.
|
||||||
@ -259,16 +255,12 @@ void serialize(Archive &ar, struct drgn_type &type,
|
|||||||
// `struct drgn_type`s in order to avoid serializing massive amounts of data.
|
// `struct drgn_type`s in order to avoid serializing massive amounts of data.
|
||||||
// In other words, our serialization of `struct drgn_type` is shallow.
|
// In other words, our serialization of `struct drgn_type` is shallow.
|
||||||
|
|
||||||
// First union: `name`, `tag`, `num_parameters`
|
// First union: `name`, `tag`
|
||||||
assert_in_same_union(name, tag);
|
assert_in_same_union(name, tag);
|
||||||
assert_in_same_union(name, num_parameters);
|
|
||||||
if (drgn_type_has_name(&type)) {
|
if (drgn_type_has_name(&type)) {
|
||||||
serialize_c_string(ar, const_cast<char **>(&type._private.name));
|
serialize_c_string(ar, const_cast<char **>(&type._private.name));
|
||||||
} else if (drgn_type_has_tag(&type)) {
|
} else if (drgn_type_has_tag(&type)) {
|
||||||
serialize_c_string(ar, const_cast<char **>(&type._private.tag));
|
serialize_c_string(ar, const_cast<char **>(&type._private.tag));
|
||||||
} else if (drgn_type_has_parameters(&type)) {
|
|
||||||
// Leave `num_parameters` set to 0 per the initial `memset`,
|
|
||||||
// see "AVOIDING OVERSERIALIZATION" comment above
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Second union: `size`, `length`, `num_enumerators`, `is_variadic`
|
// Second union: `size`, `length`, `num_enumerators`, `is_variadic`
|
||||||
@ -285,7 +277,11 @@ void serialize(Archive &ar, struct drgn_type &type,
|
|||||||
ar &type._private.is_variadic;
|
ar &type._private.is_variadic;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Third union: `little_endian`, `members`, `enumerators`, `parameters`
|
// Third union: `is_signed`, `num_members`, `num_paramters`
|
||||||
|
// Leave set to 0 per the initial `memset`, see "AVOIDING OVERSERIALIZATION"
|
||||||
|
// comment above
|
||||||
|
|
||||||
|
// Fourth union: `little_endian`, `members`, `enumerators`, `parameters`
|
||||||
assert_in_same_union(little_endian, members);
|
assert_in_same_union(little_endian, members);
|
||||||
assert_in_same_union(little_endian, enumerators);
|
assert_in_same_union(little_endian, enumerators);
|
||||||
assert_in_same_union(little_endian, parameters);
|
assert_in_same_union(little_endian, parameters);
|
||||||
|
@ -47,7 +47,7 @@ DEFINE_TYPE_VERSION(FuncDesc::Retval, 56, 2)
|
|||||||
DEFINE_TYPE_VERSION(FuncDesc::Range, 16, 2)
|
DEFINE_TYPE_VERSION(FuncDesc::Range, 16, 2)
|
||||||
DEFINE_TYPE_VERSION(FuncDesc, 104, 4)
|
DEFINE_TYPE_VERSION(FuncDesc, 104, 4)
|
||||||
DEFINE_TYPE_VERSION(GlobalDesc, 72, 4)
|
DEFINE_TYPE_VERSION(GlobalDesc, 72, 4)
|
||||||
DEFINE_TYPE_VERSION(struct drgn_type, 120, 3)
|
DEFINE_TYPE_VERSION(struct drgn_type, 152, 4)
|
||||||
DEFINE_TYPE_VERSION(DrgnClassMemberInfo, 64, 3)
|
DEFINE_TYPE_VERSION(DrgnClassMemberInfo, 64, 3)
|
||||||
DEFINE_TYPE_VERSION(struct drgn_qualified_type, 16, 2)
|
DEFINE_TYPE_VERSION(struct drgn_qualified_type, 16, 2)
|
||||||
DEFINE_TYPE_VERSION(RootInfo, 48, 2)
|
DEFINE_TYPE_VERSION(RootInfo, 48, 2)
|
||||||
|
Loading…
Reference in New Issue
Block a user