Ivan Krysak
f912ebf9b9
Model: associate a primitive kind to each register
2022-11-23 09:26:01 +01:00
Ivan Krysak
d7867e0e7e
QualifiedType: add argument-less isPrimitive()
2022-11-23 09:26:01 +01:00
Ivan Krysak
4eced0adc4
Move pointer creation away from model::Binary
2022-11-23 09:26:01 +01:00
Alessandro Di Federico
3441c6d136
DwarfImport: fix handling of local functions
2022-11-23 09:26:01 +01:00
Pietro Fezzardi
fd0914b460
QualifiedType: add isConst method
2022-11-22 10:12:31 +01:00
Pietro Fezzardi
d520fd5aea
Cache TTRs in Model tools
2022-10-29 16:46:19 +02:00
Pietro Fezzardi
fff0fbd874
LoadModelPass: cache TTRs on getReadOnlyModel
...
The cache is evicted on the next call to getWritableModel.
2022-10-29 16:46:19 +02:00
Pietro Fezzardi
7eb94c6646
QualifiedType: add operator<=>
2022-10-29 16:46:19 +02:00
Massimo Fioravanti
9363bbd70a
Pipeline: every container type has now a C++ type
2022-09-29 15:51:17 +02:00
Djordje Todorovic
5559d8431b
Introduce fix-model model pass
2022-09-21 18:37:36 +02:00
Alvise de Faveri
999df25246
Add revng model export type-graph tool
...
This tools dumps a type, a function or an entire type-system to a
dot file,representing dependencies between types as edges.
2022-09-19 08:35:06 +02:00
Pietro Fezzardi
ec9a5b0608
Use lexicographical compare for model::Qualifier
2022-09-19 08:34:20 +02:00
Giacomo Vercesi
a05737696f
Introduce revng/Model/ForwardDecls.h
2022-09-01 17:46:25 +02:00
Massimo Fioravanti
633f49c1ef
Introduce dedicated namespace for kinds and ranks
2022-08-29 14:44:53 +02:00
Massimo Fioravanti
915c083661
Pipes: reorganize who defines pipes
2022-08-29 14:44:35 +02:00
Alessandro Di Federico
1d91ed9beb
tuple_tree_generator: make C++ just a regular backend
...
The `tuple_tree_generator` component was still heavily treating C++ as a
special citizen.
This commit normalizes the situation.
2022-08-11 16:20:42 +02:00
Alessandro Di Federico
6a6cd939db
Rework EarlyFunctionAnalysis
2022-08-08 13:55:34 +02:00
Alessandro Di Federico
b07d134b73
Introduce CanonicalRegisterValues in the model
...
These canonical values ease certain analysis that can assume their value
at function entry.
2022-08-08 13:55:25 +02:00
Ivan Krysak
65d1a016d4
Standardize concept naming across the codebase
2022-08-05 17:27:56 +03:00
Ivan Krysak
de99de78ae
Add key overloads for model::getTypePath
2022-08-05 17:27:56 +03:00
Djordje Todorovic
1243d1061c
Introduce revng model hard-purge
...
In addition, introduce a new model Pass:
revng model opt -prune-unsused-types
2022-07-28 15:02:55 +02:00
Djordje Todorovic
a36e22729f
Model: Add PDB support
2022-07-28 14:52:50 +02:00
Djordje Todorovic
098f864d8d
Model: Add parsing of dyn syms to PECOFFImporter
...
This parses symbols similar to ELF's .dynsym.
2022-07-28 14:52:02 +02:00
Giacomo Vercesi
09009836a1
PipelineC: expose globals verification
2022-07-28 08:47:46 +02:00
Antonio Frighetto
186d907be3
Model: extend model::Segment
...
`Segment` now includes a `Type` of struct kind. This is intended to
emit the segment as a struct later in decompilation. The implementation
of name has also been added.
2022-07-22 16:10:51 +02:00
Ivan Krysak
04efcb8ed8
Drop the revng yield .* tools
2022-06-14 18:55:59 +03:00
Massimo Fioravanti
f0a5ffe3b3
revng-pipeline: globals, extractOne and analyses
2022-05-24 08:58:48 +02:00
Pietro Fezzardi
1c6dac225a
Add dedicated non-generated TypeKind.h header
...
This is necessary because now QualifiedType.h needs TypeKind, but
including Type.h directly would result in a circular dependency between
Type.h and QualifiedType.h
2022-05-11 14:39:31 +02:00
Giacomo Vercesi
8a61d7c2b9
Model/ABI.h: make doc fields multiline
2022-05-09 13:35:10 +02:00
Ivan Krysak
cfc9915b39
Add ModelInModule::getModule.
2022-05-06 18:51:47 +02:00
Alessandro Di Federico
92d3b95fba
Model: make more things optional
2022-04-29 17:57:49 +02:00
Alessandro Di Federico
9e46d4fdcc
Introduce getLLVMTypeForScalar(QualifiedType)
2022-04-29 17:57:49 +02:00
Alessandro Di Federico
a355a90c7e
model::Binary::getPointerTo(model::QualifiedType)
2022-04-29 17:57:49 +02:00
Alvise de Faveri
a3110c0b59
Add QualifiedType::is(TypeKind)
2022-04-20 11:25:46 +02:00
Giacomo Vercesi
d81dc49809
revng-check-conventions: license check
2022-04-20 09:55:18 +02:00
Ivan Krysak
c374f8013a
ABI: separate mips and mipsel ABIs
2022-04-15 18:25:11 +02:00
Massimo Fioravanti
c4aa92694c
Introduce revng model apply
2022-04-15 15:15:41 +02:00
Pietro Fezzardi
7f65b1117a
New AddPrimitiveTypesPipe
...
This pipe is executed during the Lift step and populates the model with
all the required primitive types.
2022-04-12 16:40:27 +02:00
Pietro Fezzardi
6b2b2e8ada
Make model::Type::edges() method const
2022-04-08 18:58:58 +02:00
Pietro Fezzardi
dfb1bb9fd2
RawFunctionType.edges() uses StackArgumentsType
2022-04-08 18:58:58 +02:00
Pietro Fezzardi
e40ded965f
QualifiedType RawFunctionType.StackArgumentsType
...
The `StackArgumentsType` field of `RawFunctionType` was the only
cross-reference between `model::Type`s that did not use
`model::QualifiedType` but a naked `TupleTreeReference`.
Switching it to `QualifiedType` make all cross-references across
`model::Type`s homogeneous.
2022-04-08 18:58:58 +02:00
Pietro Fezzardi
63a6676551
Make EnumType.UnderlyingType a QualifiedType
...
This was one of the few places left in the type system where a
`model::Type` referred to another one not using QualifiedType, but a
naked `TupleTreeReference`.
Switching it to be a `model::QualifiedType` makes cross-references
between `model::Type`s more homogenenous, requiring less corner-cases
to handle for whoever manipulates types.
2022-04-08 18:58:58 +02:00
Giacomo Vercesi
a2b5dbb1dc
TupleTreeGenerator: autogenerate Kind
2022-04-08 17:36:59 +02:00
Giacomo Vercesi
039f7db93e
model::*: ensure Kind -> Class correspondence
2022-04-08 17:31:05 +02:00
Antonio Frighetto
9980fc8c67
EFA: support dynamic function calls
...
EarlyFunctionAnalysis now can handle calls to
dynamically linked functions.
2022-04-05 15:37:57 +02:00
Antonio Frighetto
20cdfe668a
EFA: take the control-flow graph out of the model
...
The control-flow graph and all its hierarchy components
have been moved from `model` to `efa`. The CFG is now
serialized onto the LLVM IR module as a metadata.
2022-04-05 15:37:57 +02:00
Alessandro Di Federico
f6c9b04c81
Adopt clang-tidy: readability-identifier-naming
2022-04-04 21:15:52 +02:00
Massimo Fioravanti
39e0f0ac96
TupleTreeDiff<Binary>: fix compile errors
2022-03-28 12:17:05 +02:00
Massimo Fioravanti
5bdce4bf36
LoadModelPass: support command-line path
...
It is now possible to load a model from file instead of the one written
in the module itself:
revng opt --model-path=<path>
2022-03-28 12:17:05 +02:00
Alessandro Di Federico
af1828e090
DwarfImporter: better support for 0-sized types
...
We now ignore field of `struct`/`union` that have a 0-sized type.
We now also ignore types containing a an array with 0-sized elements.
2022-03-28 12:17:05 +02:00