Ivan Krysak
1f16a5bee6
KeyedObjectContainers: add erase_if
2024-06-27 11:05:50 +02:00
Ivan Krysak
73c43add70
TupleTree: revamp the visitors
2024-06-27 11:05:50 +02:00
Ivan Krysak
6628cbe1b8
TupleTree: drop an unused argument
2024-06-27 11:05:50 +02:00
Ivan Krysak
a4f638082d
TTG: stop treating GUID as optional
2024-06-27 11:05:50 +02:00
Ivan Krysak
925690a1e1
VerifyHelper: reduce pointer usage
2024-06-27 11:05:50 +02:00
Ivan Krysak
b6625e8913
Model: simplify fixModel pass
...
Instead of getting reimplemented/updated, it now just reuses normal
type verification routines.
2024-06-27 11:05:50 +02:00
Ivan Krysak
c76f7488d2
YAMLTraits: leave kind-less pointers empty
2024-06-27 11:05:50 +02:00
Ivan Krysak
72346979e2
TupleTree: improve nullptr robustness
2024-06-27 11:05:50 +02:00
Ivan Krysak
d4bb646708
UpcastablePointer: improve nullptr robustness
2024-06-27 11:05:50 +02:00
Ivan Krysak
23aed24be1
Model: make compare key-strict
...
Before now it only looked at `ID`s which made it incompatible with
models that reuse the same ID for different kinds.
2024-06-27 11:05:50 +02:00
Ivan Krysak
94c9e9d4dd
Make verifys inside asserts strict
2024-06-27 11:05:50 +02:00
Ivan Krysak
39264e73fa
Model: introduce new Type system
2024-06-27 11:05:50 +02:00
Ivan Krysak
b33eb7cf70
Model: reduce pointer usage in verify
2024-06-27 11:05:50 +02:00
Ivan Krysak
284699967f
UpcastablePointer: introduce bool operator
...
This allows writing stuff like
```cpp
if (UpcastablePointer P = getPointerFromSomewhere())
doSomething(*P);
```
which makes it even more pointer-like.
2024-06-27 11:05:50 +02:00
Ivan Krysak
a51d755608
TTG: add a static assert on a get miss
2024-06-27 11:05:50 +02:00
Ivan Krysak
806e90a124
TTG: change typescript generator to use comments
2024-06-27 11:05:50 +02:00
Ivan Krysak
e8288d1e70
Model: reorganize verifier order
...
This helps keeping track of them and making sure none of them is lost.
The order is bottom-to-top, so ends with `model::Binary::verify` and
contains verification of all of its dependencies in the order they
appear in their user's `verify`s, kind of like a flattened tree.
2024-06-27 11:05:49 +02:00
Ivan Krysak
277cba213c
Model: separate verification
2024-06-27 11:05:49 +02:00
Ivan Krysak
9e6bf29f74
TTG: pull dump helper into the template
2024-06-27 11:05:49 +02:00
Ivan Krysak
927e8006b9
Model: rename TypePath to DefinitionReference
2024-06-27 11:05:49 +02:00
Ivan Krysak
087ecbc534
TypeSystemPrinter: remove unused method
2024-06-27 11:05:49 +02:00
Ivan Krysak
5ec894e117
Yield: resyncronize yield::BasicBlock
2024-06-27 11:05:49 +02:00
Ivan Krysak
8ab27800a8
EFA: remove some dead code
2024-06-27 11:05:49 +02:00
Ivan Krysak
d3a6fd8b5b
Layout: simplify aggregate return type logic
2024-06-27 11:05:49 +02:00
Ivan Krysak
35444268b3
TTG: strip Kind from the child constructor
2024-06-27 11:05:49 +02:00
Ivan Krysak
edb2d11c9a
TTG: add upcastable struct field support
2024-06-27 11:05:49 +02:00
Ivan Krysak
2dfdff992d
UpcastablePointer: introduce copy helper
2024-06-27 11:05:49 +02:00
Ivan Krysak
efc24dee4b
UpcastablePointer: introduce empty helper
2024-06-27 11:05:49 +02:00
Ivan Krysak
ee238fd473
RCC: allow prettier to print errors
2024-06-27 11:05:49 +02:00
Ivan Krysak
32fd1eed5b
TTG: move classof boilerplate into the template
2024-06-27 11:05:49 +02:00
Ivan Krysak
48ace7c147
TTG: reorder early struct template
...
This heavily improves readability of the generated header.
2024-06-27 11:05:49 +02:00
Ivan Krysak
a85ce02b29
TTG: clean impl.cpp formatting up
2024-06-27 11:05:49 +02:00
Ivan Krysak
37f424da06
TTG: move UpcastableX typedef to the template
2024-06-27 11:05:49 +02:00
Ivan Krysak
6a1018b860
Remove unused linter suppressors
2024-06-27 11:05:48 +02:00
Ivan Krysak
ac587cbb4f
Model: rename Type into TypeDefinition
2024-06-27 11:05:48 +02:00
Ivan Krysak
d613023a53
Model: drop an obsolete assert
2024-06-27 11:05:48 +02:00
Ivan Krysak
26c68b78ea
Model: drop makeTypeWithID
2024-06-27 11:05:48 +02:00
Ivan Krysak
84c8822c37
Model: drop TypedRegister
2024-06-27 11:05:48 +02:00
Ivan Krysak
4676c951a0
ABI: update outdated comments
2024-06-27 11:05:48 +02:00
Ivan Krysak
7ff1a0f487
Model: remove mostly unused Types.h header
2024-06-27 11:05:48 +02:00
Ivan Krysak
ce1f13e715
TTG: fix parseClass argument type
2024-06-27 11:05:48 +02:00
Ivan Krysak
93b5ad6067
TTG: add indirect dependencies to root's late.h
2024-06-27 11:05:48 +02:00
Ivan Krysak
c109d50814
TTG: remove self passthrough
2024-06-27 11:05:48 +02:00
Ivan Krysak
0438a207fc
TTG: improve early struct header formatting
2024-06-27 11:05:48 +02:00
Ivan Krysak
b2959e36df
Minor improvements
2024-06-27 11:05:48 +02:00
Alessandro Di Federico
d14b4905e7
Merge branch 'feature/pipeline-revng-passes'
2024-06-27 10:17:44 +02:00
Alessandro Di Federico
4523571231
Merge branch 'feature/pipeline-revng-passes'
2024-06-27 10:17:37 +02:00
Alessandro Di Federico
2aa4812ca0
end-to-end.yml: disable check-decompiled-c
...
This is a temporary change.
2024-06-27 10:13:49 +02:00
Pietro Fezzardi
85340c8d84
ModelToHeader: disable type inlining by default
...
This is due to the fact that type inlining currently is broken in some
corner cases involving recursive types.
The bugs are caused by the fact that TypeInlineHelper uses its own
custom graph instead of using the DependencyGraph used by ModelToHeader,
causing different decisions about the order of emission of types.
As a result, the generated C types are not valid C, and they fail to
compile because a field of a struct has a type that is defined later
than its use.
After refactoring TypeInlineHelper to use DependencyGraph like
ModelToHeader, this can be reverted.
2024-06-26 12:21:58 +02:00
Pietro Fezzardi
fc02a98aa3
DLA: disable DeduplicateFields
...
The DLAStep has bugs that are preventing other useful features to be
merged.
2024-06-26 12:21:58 +02:00