mirror of
https://github.com/JakeHillion/object-introspection.git
synced 2024-09-19 11:09:05 +01:00
31ba8659f0
A previous change enabled running OIL tests with specific features enabled. This highlighted that pointer code generation under TreeBuilder-v2 was very broken. This change updates pointer code generation to work and enables the skipped tests. All enabled tests need `expected_json_v2` added to them due to formatting differences. Reformatted and rewrote the basic type handler that handles primitives and pointers. Removed the reliance on `features` to decide whether to generate for TreeBuilder-v2 as the intermediate features have been removed. Pointers are treated as containers with a capacity of 1 and a length of 0 if null/a cycle and 1 if followed. This holds for void pointers where, although they aren't followed, the length is still set. There were a couple of other changes needed to enable these tests on TBv2 that aren't worth their own issues and PRs, I sneaked them in here. Extra changes: - Added `Pointer` and `Reference` to TopoSorter so they generate `NameProvider` instances. It might be worth visiting the graph differently for `NameProvider` as it requires so many instances that others generators do not. Will consider that in the future. - Follow typedefs when calculating exclusive size for a type. Closes #458. Test plan: - CI - Enabled previously disabled tests. |
||
---|---|---|
.. | ||
exporters | ||
support | ||
type_graph | ||
types/test | ||
CMakeLists.txt | ||
CodeGen.cpp | ||
CodeGen.h | ||
Config.cpp | ||
Config.h | ||
ContainerInfo.cpp | ||
ContainerInfo.h | ||
ContainerTypeEnum.h | ||
Descs.cpp | ||
Descs.h | ||
DrgnUtils.cpp | ||
DrgnUtils.h | ||
EnumBitset.h | ||
Features.cpp | ||
Features.h | ||
FuncGen.cpp | ||
FuncGen.h | ||
Headers.h | ||
IntrospectionResult.cpp | ||
Metrics.cpp | ||
Metrics.h | ||
OICache.cpp | ||
OICache.h | ||
OICodeGen.cpp | ||
OICodeGen.h | ||
OICompiler.cpp | ||
OICompiler.h | ||
OID.cpp | ||
OIDebugger.cpp | ||
OIDebugger.h | ||
OIGenerator.cpp | ||
OIGenerator.h | ||
OILexer.h | ||
OILexer.l | ||
OILibrary.cpp | ||
OILibraryImpl.cpp | ||
OILibraryImpl.h | ||
OIOpts.h | ||
OIParser.h | ||
OIParser.yy | ||
OITraceCode.cpp | ||
PaddingHunter.cpp | ||
PaddingHunter.h | ||
Portability.h | ||
Serialize.cpp | ||
Serialize.h | ||
SymbolService.cpp | ||
SymbolService.h | ||
Syscall.h | ||
TimeUtils.h | ||
TrapInfo.h | ||
TreeBuilder.cpp | ||
TreeBuilder.h | ||
TypeHierarchy.h | ||
X86InstDefs.h |