Ivan Krysak
32fd1eed5b
TTG: move classof boilerplate into the template
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
7ff1a0f487
Model: remove mostly unused Types.h header
2024-06-27 11:05:48 +02:00
Alessandro Di Federico
f60c1bb4ad
s/TrackGuard/DisableTracking/
2024-06-20 10:24:51 +02:00
Alessandro Di Federico
a6cf3fbb83
Centralize computation of llvm::Function names
...
This commit introduces a function to obtain the name assigned to a
`llvm::Function` associated to a `model::Function`. This simplifies the
codebase but also enables us to introduce an option to produce
human-friendly names for debugging/testing purposes.
2024-06-20 10:24:49 +02:00
Alessandro Di Federico
3097e94a0d
Enable fetching call site prototype without CFG
...
Before this commit, we used to attach to call site a metadata to trace
back the call site to the CFG (i.e., `FunctionMetadata`).
This led several passes in revng-c to depend on `FunctionMetadata` just
for this.
This commit, attaches to call sites a reference to the prototype itself
(on the `revng.prototype` metadata), breaking many of such dependencies.
2024-06-20 10:24:49 +02:00
Alessandro Di Federico
b350d12ad2
TTG: spread some optional: true around
2024-06-20 10:24:49 +02:00
Alessandro Di Federico
d07d6c4f1f
Drop leftover Section.h
2024-06-20 10:24:49 +02:00
Massimo Fioravanti
f783868dde
Model: adopt tryGet instead of find() != end()
2024-06-20 09:57:36 +02:00
Massimo Fioravanti
43349943a7
Stop serializing the model in the IR
2024-06-20 09:57:36 +02:00
Lauri Vasama
3e33a300d5
Introduce RawFunctionType::Architecture
2024-05-29 15:42:15 +02:00
Lauri Vasama
185afcf4c0
Fix spelling of FunctionEntryMDName
2024-05-29 15:42:15 +02:00
Alessandro Di Federico
47c3dd8f0f
Drop model::Segment::Sections
2024-05-22 10:25:25 +02:00
Alessandro Di Federico
31b1b66f44
Reorder model::Binary fields
2024-05-22 10:25:25 +02:00
Alessandro Di Federico
bf6cefc05a
Externalize functions to improve build times
2024-05-03 21:52:40 +02:00
Alessandro Di Federico
fe1dffcffd
Add some missing includes
...
This is in preparation of reducing headers in Debug.h.
2024-05-03 21:52:40 +02:00
Ivan Krysak
77fb7e6e5b
Yield: introduce BasicBlockPrefix option
2024-03-18 10:58:55 +00:00
Ivan Krysak
948d905752
Add PrintFullMetaAddress configuration option
2024-03-18 11:58:11 +01:00
Ivan Krysak
2bffccaaf6
Move ImmediateStyle configuration to the model
2024-03-18 11:58:11 +01:00
Ivan Krysak
184aa03847
Move AddressStyle configuration to the model
2024-03-18 11:58:11 +01:00
Ivan Krysak
2827c9d7f7
Move UseATTSyntax configuration to the model
2024-03-18 11:58:11 +01:00
Ivan Krysak
371784afbd
Model: introduce basic disassembly configuration
2024-03-18 07:20:41 +00:00
Alessandro Di Federico
e93d8ba09f
RawBinaryView:getByOffset: fix of by =
2024-03-15 17:13:20 +01:00
Alessandro Di Federico
0da9d1e1a4
Model: fix handling of 0-sized arguments
...
We used to support having a single `void` argument. It was for some
C-compatibility ambitions, but just omitting the argument is perfectly
fine.
Also, the DWARF importer has been fixed to handle typedef'd void as
arguments.
More in general, arguments are now required to always have a size.
2024-03-01 14:53:06 +01:00
Ivan Krysak
e708a3655b
ABI: drop incomplete clrcall support
2024-02-09 15:09:37 +00:00
Ivan Krysak
4e81a34cd7
ABI: separate 'gcc' editions of microsoft ABIs
2024-02-09 15:09:37 +00:00
Ivan Krysak
fffd62391c
Model: introduce hasMetadata helper
2024-02-09 15:09:37 +00:00
Alessandro Di Federico
d9367954a4
Convert all public strings to kebab-case
2024-02-09 10:04:24 +01:00
Ivan Krysak
54ffd723e6
ABI: decouple alignment from model::VerifyHelper
2024-01-29 11:57:54 +02:00
Ivan Krysak
a2ef041cb2
Move TypeBucket to the model
2024-01-29 11:57:54 +02:00
Ivan Krysak
77b1acaf00
Prefer uint64_t to size_t wherever relevant
2024-01-29 11:57:54 +02:00
Massimo Fioravanti
c276a439b5
Add pipeline invalidation
...
Replace the stub implementation of invalidation with the proper
implementation. A ReadPathCache is added to each global so that it can
keep tracks of what target are associated to which read paths.
2024-01-02 11:14:56 +01:00
Alessandro Di Federico
73a1827c29
Import QualifiedType::stripPointer
2023-12-12 12:04:34 +01:00
Giacomo Vercesi
8504a96020
RawFunctionType: use NamedTypedRegister for return
...
Use the `NamedTypedRegister` type for return values in
`RawFunctionType`. This allows return values to be renamed at the user's
discretion.
2023-12-11 12:03:45 +01:00
Alessandro Di Federico
10dcb7be11
Fix semantics of model::Types purging passes
...
One of the two passes to purge unused types from the model had a
ill-defined semantics.
This commit simplifies them in two passes: one that purges all the types
unreachable from outside `Binary::Types` and one that does the same but
also preserves types with a `CustomName` or an `OriginalName`.
2023-12-05 16:19:39 +01:00
Pietro Fezzardi
bbcb4df839
TypeSystemPrinter: print segment types
2023-12-05 16:19:39 +01:00
Pietro Fezzardi
1285c6e7af
Make RawFunctionType::StackArgumentsType a TTR
...
This is homogeneous with all other nullable references to types in the
model, such as the StackFrameType in model::Function, and others.
2023-12-05 16:19:38 +01:00
Pietro Fezzardi
48b27af795
Make Segment::Type a TupleTreeReference
...
This is homogeneous with all other nullable reference to types in the
model, like the StackFrameType in model::Function, and others.
2023-12-05 16:19:38 +01:00
Giacomo Vercesi
94efdc142a
Drop model::editPath helpers
...
With the introduction of `data-action-context-location` the helpers in
the `model::editPath` namespace are no longer needed.
2023-11-03 16:31:02 +01:00
Ivan Krysak
cfe28d8e56
Stop using std:: prefix for u?int\d+_t types
2023-11-02 17:10:03 +01:00
Alessandro Di Federico
2cbf3a8313
TypeCopier: minor rework
2023-10-05 10:19:44 +02:00
Alessandro Di Federico
456b916bcc
Move TypePath definition
2023-10-05 10:19:44 +02:00
Alessandro Di Federico
bf66ecc389
{,Dynamic}Function::Prototype: support typedefs
2023-10-05 10:19:44 +02:00
Giacomo Vercesi
29b229455f
Tuple Tree: rename Parent in struct.h.tpl
...
Rename the Parent attribute of a struct to BaseClass to avoid conflicts
with Tuple Tree structs that might need that attribute.
2023-09-14 15:44:32 +02:00
Alessandro Di Federico
26310efc1c
TypeCopier::copyTypeInto: fix returning wrong type
...
TypeCopier::copyTypeInto used to return a random type among those just
created instead of the new version of the originally requested type.
2023-09-11 14:15:37 +02:00