Commit Graph

2939 Commits

Author SHA1 Message Date
Ivan Krysak 03b8d29cb9 CFG: introduce flat per-line padding 2025-07-24 13:31:29 +03:00
Ivan Krysak 0db801b439 CFG: ignore empty lines at the ends of blocks 2025-07-24 13:31:29 +03:00
Ivan Krysak f6970ff70a TypeNames: fix function prototype return value tag 2025-07-23 11:38:53 +02:00
Ivan Krysak a285ad2785 IRHelperRegister: get a comment from Description 2025-07-23 11:38:53 +02:00
Ivan Krysak b656381ec5 Update ptml documentation
This also reorders definitions in `revng/Pipes/Ranks.h` to match
the order used by the docs.
2025-07-23 11:38:53 +02:00
Ivan Krysak 97aa3c8247 std::string: use implicit default constructor 2025-07-23 11:38:53 +02:00
Ivan Krysak 90862b68ed StringBufferContainer: fix StartingContent 2025-07-23 11:38:53 +02:00
Ivan Krysak 290d2e2c57 ptml::CTypeBuilder: rename into ModelCBuilder 2025-07-23 11:38:53 +02:00
Ivan Krysak 116c8675db Ranks: greatly improve documentation 2025-07-23 11:38:52 +02:00
Ivan Krysak 2b9b925e8c TTG: make doc mandatory in fields too 2025-07-23 11:38:52 +02:00
Ivan Krysak 9589721b52 Model schema: reorder and reformat
This improves readability and navigation in this big file.
2025-07-23 11:38:52 +02:00
Ivan Krysak f49ec25de3 TTG: make doc mandatory in structs and enums 2025-07-23 11:38:52 +02:00
Ivan Krysak a11215bd73 Model schema: drop trailing newlines from docs 2025-07-23 11:38:52 +02:00
Ivan Krysak f391392fe9 Use explicit separator strings 2025-07-23 11:38:52 +02:00
Ivan Krysak 461c49df25 Model: bump version to 5 and introduce migration 2025-07-23 11:38:52 +02:00
Ivan Krysak c9072ec28f TypePathHelpers: add variable and goto label paths 2025-07-23 11:38:52 +02:00
Ivan Krysak 0572de8990 TypePathHelpers: fix incorrect return value paths 2025-07-23 11:38:52 +02:00
Ivan Krysak f4e86b37b8 OpaqueFunctionsPool: leave a TODO 2025-07-23 11:38:51 +02:00
Ivan Krysak 1930f72484 CTypeBuilder: drop replaced tag builders 2025-07-23 11:38:51 +02:00
Ivan Krysak 21734cad34 CTypeBuilder: add new variable and label tagging 2025-07-23 11:38:51 +02:00
Ivan Krysak a7bba503d3 CTypeBuilder: add counting name builder support 2025-07-23 11:38:51 +02:00
Ivan Krysak 4265644adf NameBuilder: introduce counting sub-builders 2025-07-23 11:38:51 +02:00
Ivan Krysak 2f560e797c TrackingContainer: introduce unwrap 2025-07-23 11:38:51 +02:00
Ivan Krysak 36ce22cd4e STLExtras: change notNull to return a reference 2025-07-23 11:38:51 +02:00
Ivan Krysak fd1ed20852 Ranks: update local variables and goto labels
Then now use corresponding model keys instead of raw names.
2025-07-23 11:38:51 +02:00
Ivan Krysak 554ffa376a model::Function: introduce GotoLabels field 2025-07-23 11:38:51 +02:00
Ivan Krysak 1ebeb8f493 model::Function: introduce LocalVariables field 2025-07-23 11:38:50 +02:00
Ivan Krysak 4e3c6cccd0 Model: introduce LocalIdentifier struct 2025-07-23 11:38:50 +02:00
Ivan Krysak 3c9aa5f4b2 Pipes: pull tryExtractAddress up 2025-07-23 11:38:50 +02:00
Ivan Krysak 8dff23d586 MetaAddress: pull addressesToString up 2025-07-23 11:38:50 +02:00
Ivan Krysak b982ae68d0 NamingConfiguration: add UnnamedGotoLabelPrefix 2025-07-23 11:38:50 +02:00
Ivan Krysak 031c4dfa2f Introduce ptml::CTypeBuilder::getFreeFormComment 2025-07-23 11:38:50 +02:00
Ivan Krysak 04b751dafc TrackingContainer: add a missing Other access
This ensures `operator==` correctly registers the fact that *both*
of the containers were accesses.
2025-07-23 11:38:50 +02:00
Ivan Krysak d11b524f14 TrackingContainer: introduce operator<=> 2025-07-23 11:38:50 +02:00
Ivan Krysak 83a3843d8a SortedVector: introduce operator<=> 2025-07-23 11:38:50 +02:00
Ivan Krysak 96be1a9979 MetaAddress: introduce operator<=> 2025-07-23 11:38:50 +02:00
Ivan Krysak b5337d78da Minor Improvements 2025-07-23 11:38:50 +02:00
Andrea Gussoni c060f07ecd ScopeGraph: add scope-graph-output cl::opt 2025-07-23 11:34:13 +02:00
Andrea Gussoni 1faa781e6a CommandLine: drop pathToStream
Remove `pathToStream` in favour of `llvm::ToolOutputFile`.
2025-07-23 11:34:13 +02:00
Giacomo Vercesi 29d7f2d8a8 artifacts: allow parsing the recompilable archive
Allow the artifacts machinery to parse, via `pycparser`, the
recompilable archive provided by revng via the
`emit-recompilable-archive` artifact.
2025-07-18 09:30:56 +02:00
Lauri Vasama 28550f2f57 Add explicit pointer size support in old backend
When `Configuration.ExplicitTargetPointerSize` is set, the backend uses
explicit pointer type sizes (e.g. `pointer32_t(T)`).
2025-07-17 16:45:03 +02:00
Lauri Vasama 780e774b20 Add Clift legalization pipe 2025-07-17 16:45:03 +02:00
Lauri Vasama 9fda9f955d Add NoMemoryEffect on Clift operations
This allows unused expressions to be automatically pruned during
transforms.
2025-07-17 16:45:03 +02:00
Lauri Vasama 4e17287cfc Add LLVM-to-Clift import 2025-07-17 16:45:03 +02:00
Lauri Vasama b9ce0a87df Add Clift model verification 2025-07-17 16:45:03 +02:00
Lauri Vasama d70c9404f3 Add a helper for LLVM IR lookup by meta-address 2025-07-17 16:45:03 +02:00
Lauri Vasama 8c3d774978 Implement MetaAddress DenseMap support 2025-07-17 16:45:03 +02:00
Lauri Vasama 74588ae684 Rename MLIRFunctionKind to CliftFunction 2025-07-17 16:45:03 +02:00
Lauri Vasama 237d246665 Factor out the default C target implementation
This commit also adds size 16 -> extended integer kind mapping.

While we are hardcoding this for now, some maintenance (as above) is
needed, so it's best to hardcode it only in one place and share that
definition.
2025-07-17 16:45:03 +02:00
Lauri Vasama ee38ac933c Make comparison op assembly syntax more explicit
```
// Old syntax:
// Argument types are !int32_t.
// The boolean result type is implicitly !int32_t.
clift.eq %0, %1 : !int32_t

// New syntax:
// The boolean result type must be specified explicitly.
clift.eq %0, %1 : !int32_t -> !int32_t
```
2025-07-17 16:45:03 +02:00