Commit Graph

157 Commits

Author SHA1 Message Date
Alessandro Di Federico 8e34aa3a3c revng-db: ensure CreateFileA is exported once 2026-05-15 11:43:22 +02:00
Alessandro Di Federico 9bc1e65125 import-prototypes test: merge .yml and .filecheck 2026-05-15 11:43:21 +02:00
Alessandro Di Federico 6e6105e8fe import-prototypes-from-db: add linux/x86-64 test
Smoke test that exercises the linux/x86-64 path: feeds malloc/calloc/
realloc plus a NonExistentFunction through the analysis and asserts that
the typed symbols pick up a prototype while the unknown one does not.
2026-05-15 11:27:33 +02:00
Alessandro Di Federico 2629f95dd1 Introduce ImportPrototypesFromDatabase
This commit introduces an analysis to import prototypes from a SQLite
database of well-known prototypes, typically built from debug info of
operating systems.

This analysis supersedes import-well-known-models.
2026-04-24 17:54:09 +02:00
Alessandro Di Federico eb9e82477a Introduce WindowsApiSetSchemaParser 2026-04-23 13:40:43 +02:00
Alessandro Di Federico d977f26bce import-from-c test: improve error reporting 2026-04-23 13:40:42 +02:00
Pietro Fezzardi 4735dfb460 Fix model-migration.yml: bash negation 2026-04-10 15:27:24 +02:00
Giacomo Vercesi 96f2ad60b4 Fix scripting tests 2026-04-10 11:45:12 +02:00
Giacomo Vercesi ee7ce2d9a3 revng2 quick artifact: use subcommands
Make each artifact a subcommand of `revng2 quick artifact` so that it
behaves the same way as `revng2 project artifact`.
2026-04-10 11:45:12 +02:00
Ivan Krysak 754cfd57fe Model: introduce migration to version 9 2026-03-27 08:19:21 +00:00
Ivan Krysak 16f4be79bb Migration tests: ignore empty lines 2026-03-27 08:18:57 +00:00
Giacomo Vercesi 36f9dfe45b tests: leave TODO in tests to port/drop
Add TODOs to the test yamls of tests that are yet to be ported to the
new pipeline, the new backend or will be removed indefinitely when the
old pipeline is removed.
2026-03-05 14:23:06 +01:00
Giacomo Vercesi 2a5c58791d Port tests to the new pypeline
Port as many tests as possible to use the `revng2`.
2026-03-05 14:23:06 +01:00
Giacomo Vercesi 4757cad690 pipeline-comparison: remove use of {push,pod}d 2026-03-04 14:58:02 +01:00
Ivan Krysak 22fe32afa2 Minor improvements 2026-02-25 12:47:27 +01:00
Giacomo Vercesi 728ee2bb96 Add end-to-end test for --debug 2026-02-16 12:17:56 +01:00
Alessandro Di Federico f443bcc6da Model migration tests: suppress output 2025-12-22 11:34:46 +01:00
Alessandro Di Federico 9d76a2ff52 for-collect-cfg: test Windows dynamic calls 2025-12-22 11:31:54 +01:00
Giacomo Vercesi e3b263d9da Implement revng2 project init 2025-12-10 16:16:14 +01:00
Alessandro Di Federico 5045506ce0 model-migration: use no-op analysis 2025-12-03 17:59:19 +01:00
Alessandro Di Federico f435443630 tests: adopt emit-c over decompile 2025-12-03 17:59:19 +01:00
Giacomo Vercesi e32c92b164 Add pypeline comparison tests
Add a set of tests to the test suite that compare the output of the new
pipeline (via `revng2`) to the output of the old one.
2025-11-18 17:47:54 +01:00
Alessandro Di Federico 81f063d30c Old backend: suppress -Wshift-count-overflow 2025-10-24 18:21:13 +02:00
Ivan Krysak e56f543b1a Split module.bc.zstd 2025-10-13 10:26:41 +03:00
Ivan Krysak ed53e759c9 Do not use -Y flag
Yaml model are now the _only_ way to store them, no point in still
specifying the old flag for it.
2025-10-13 10:26:41 +03:00
Lauri Vasama 653d451e6c Remove undef name configuration support
Also adds a model migration removing
Configuration.Naming.UndefinedValuePrefix.
2025-09-29 18:05:55 +03:00
Ivan Krysak 461c49df25 Model: bump version to 5 and introduce migration 2025-07-23 11:38:52 +02:00
Lauri Vasama e9b18d448b Add Clift emit-c pipe and end-to-end tests 2025-07-17 16:45:03 +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 9d39020034 Add LLVM-to-Clift import pipe 2025-07-17 16:45:03 +02:00
Giacomo Vercesi 569b9d11b5 end-to-end: add test to check decompile output
Add an end-to-end test that checks that the decompile output is a valid
tar file and it contains all the functions defined in the model.
2025-06-27 17:12:18 +02:00
Pietro Fezzardi c2def30b61 Re-enable tests formerly disabled do to a bug
This commit turns on some old tests that were disabled for a bug.

The comment on the disabled tests said that it was due to a bug in type
inlining, but it was actually caused by a bug in the computation of
dependencies in DepenencyGraph.

Type inlining is now gone, and DependencyGraph has been fixed, so it's
now possible to re-enable these tests.
2025-05-29 09:38:09 +02:00
Pietro Fezzardi ea3cbe4c1b Drop type inlining
Type inlining was a feature that allowed type definitions of
structs/unions/enums to be printed in C directly inside the definition
of another parent struct/union, if the inner type was only used once in
the parent type.

This kind of reasoning is inherently global: a type definition of the
subtype can be inlined in the parent type one only if *globally* the
subtype it isn't referred anywhere else.

This caused issues with type inlining inside definitions of stack types
in the body of functions. Indeed, for a given function, due to type
inlining, it was necessary to do global reasoning about what other types
could be inlined in the definition of the function's stack frame type.
This, in turn, had heavy consequences on invalidation, because any
change to any type (even if it wasn't referred in a given function's
body) was causing invalidation of all functions' bodies.

For this reason it was decided to drop the type inlining feature.
2025-05-28 17:11:56 +02:00
Ivan Krysak 2c7cc0edab Model: rework migration tests
This makes them a lot more modular, making it easier to add similar
tests for future model versions.
2025-05-08 15:42:02 +02:00
Giacomo Vercesi 3e3779498e Implement python interface for revng
Add a python interface (`revng.profile`) for interacting with the rev.ng
infrastructure as a whole; either through the CLI (`CLIProject`) or the
GraphQL API (`DaemonProject`).
2025-05-07 10:48:51 +02:00
Ivan Krysak b72bcd7dd2 Introduce a basic problem name reporting system 2025-04-17 11:19:17 +03:00
Ivan Krysak f070f1f1e1 Model: sunset double name system 2025-04-17 11:19:17 +03:00
Ivan Krysak 50bbcaba1c Sunset name collision tests
Because of the switch to pre-model deduplication, no collisions are
possible, as such, it doesn't make much sense to keep these.
2025-04-15 16:35:42 +03:00
Giacomo Vercesi 42f8321f59 Fix S3 storage test
Fix the storage test by converting it from bash to python and also
testing all the occasions where a save should be triggered.
2025-03-28 14:23:10 +01:00
Pietro Fezzardi 9e0f015eb8 Drop old conversion from LLVM to MLIR
The previous conversion from LLVM to MLIR was translating plain LLVM IR
to LLVM MLIR Dialect, as a preliminary step for further conversion from
LLVM MLIR Dialect to Clift.
This is not how things are expected to work anymore, so the old code is
now dead and can be removed.
2025-01-29 23:55:49 +01:00
Pietro Fezzardi 6e17dbed58 Tests: test the prepare-for-clift artifact
This is the initial part of the clift-based decomilation pipeline.
2025-01-29 23:55:49 +01:00
Alessandro Di Federico 143c315196 Merge revng-c into revng 2024-11-21 10:50:55 +01:00
Alessandro Di Federico 30f464119e s/module.ll/module.bc.zstd/g 2024-11-11 16:51:18 +01:00
Ivan Krysak c72abab5e4 Introduce name collision tests 2024-11-06 19:18:53 +02:00
Ivan Krysak 2240da4ffc Improve test documentation 2024-11-06 19:18:53 +02:00
Alessandro Di Federico a48e0f5c93 Rework usage of analyses list 2024-11-04 15:09:56 +01:00
Alessandro Di Federico bd84bd7f2e Rework --analyze and --analyses-list 2024-10-31 17:19:51 +01:00
Giacomo Vercesi 248e642f02 Fix tests due to module.ll format change
`module.ll` is now a zstd-compressed bitcode file. Change the tests
where it relied on the module being LLVM IR by decompressing and
disassembling the input on the fly.
2024-10-30 10:28:08 +01:00
Alessandro Di Federico bf9ef91f4e Drop revng model import binary 2024-10-16 11:46:56 +02:00
Ivan Krysak 94d860e2b2 Clean up builder configuration
This also re-enables stack inlining by default.
2024-10-15 10:45:13 +03:00