31 Commits

Author SHA1 Message Date
Ivan Krysak 1609bbe745 Restore the separate enum declaration node 2026-06-16 18:43:45 +02:00
Ivan Krysak e5113a8c1d ImportFromC: add a logger printing clang inputs 2026-06-15 17:32:33 +02:00
Ivan Krysak 42e9973ab1 ImportFromC: drop a pointless logger
It was only outputting errors that were already printed anyway.
2026-06-15 17:32:30 +02:00
Ivan Krysak 77affee259 importType: provide a error-less overload 2026-06-15 17:28:22 +02:00
Ivan Krysak 334a50e168 import-from-c: use new header 2026-06-15 17:28:22 +02:00
Giacomo Vercesi d479438d3c Add ImportFromC analysis to pypeline 2026-03-04 14:58:02 +01:00
Alessandro Di Federico 5820908675 Remove and ban \file 2025-12-16 17:41:55 +01:00
Alessandro Di Federico c883bed765 Drop Logger's StaticEnabled feature 2025-10-31 17:25:03 +01:00
Ivan Krysak 290d2e2c57 ptml::CTypeBuilder: rename into ModelCBuilder 2025-07-23 11:38:53 +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
Pietro Fezzardi 8c7a800de1 Rename CTypeBuilder::printForwardTypeDeclaration
to printForwardDeclaration.
2025-05-28 17:11:11 +02:00
Giacomo Vercesi cf08ae41be Drop usage of llvm::ErrorOr<T>
Remove the last two remaining classes in revng which used the
`llvm::ErrorOr` class, replace them with `llvm::Expected`.
2025-05-05 16:02:40 +02:00
Ivan Krysak 6ea75f02b3 Model: switch to the new namespace verifier 2025-04-15 16:35:42 +03:00
Ivan Krysak 705e4a5955 auto [...] -> auto &&[...] 2025-02-13 13:10:51 +02:00
Ivan Krysak 288448f009 Never include model::VerifyHelper from headers 2025-02-13 13:09:50 +02:00
Alessandro Di Federico 143c315196 Merge revng-c into revng 2024-11-21 10:50:55 +01:00
Ivan Krysak 64446d0453 Adopt name builder across the model users 2024-11-06 19:18:53 +02:00
Ivan Krysak efbc5cdd5c Introduce an error creation helper 2024-11-06 19:18:53 +02:00
Ivan Krysak 1a35cbcb77 Introduce PTMLCTypeBuilder 2024-10-15 10:45:13 +03:00
Ivan Krysak 8aa7b55e2d PTMLIndentedOstream: rename into IndentedOstream 2024-10-15 09:13:28 +02:00
Ivan Krysak 8288bd68d2 PTMLCBuilder: rename into ptml::CBuilder 2024-10-15 09:13:28 +02:00
Alessandro Di Federico 8a5ae5f9c1 s/ExecutionContext &Ctx/ExecutionContext &EC/g 2024-09-27 10:35:10 +02:00
Alessandro Di Federico 08e1dc0f05 Drop no-op Pipe::checkPrecondition 2024-09-27 10:35:10 +02:00
Ivan Krysak 73a723e9f4 HeaderToModel: rework error reporting 2024-09-04 16:42:29 +02:00
Pietro Fezzardi dfe3f4cb47 Rename revng C headers for decompiled code
Strip away the 'revng-' prefix from the filename.
2024-06-27 17:26:18 -04:00
Ivan Krysak 94a0ad6b93 Adopt reworked model::Type 2024-06-27 11:07:01 +02:00
Ivan Krysak 3705906074 Model: rename Type into TypeDefinition 2024-06-27 11:07:01 +02:00
Alessandro Di Federico b05ab6ff3c Make Pipe::checkPrecondition mandatory 2024-05-21 09:44:04 +02:00
Giacomo Vercesi f8e50acc49 ImportFromCAnalysis: fix getOptionsfromCFGFile
Rewrite the `getOptionsfromCFGFile` function using llvm facilities.
The new code has the following features.
- It avoids the default behaviour of `std::fstream` of opening the file
in read-write.
- It's stricter should an error occur when opening the file.
2024-03-01 16:07:45 +01:00
Alessandro Di Federico f6f542769b Convert all public strings to kebab-case 2024-02-09 09:04:25 +01:00
Alessandro Di Federico 23b3bc9e16 s/ImportModelFromC/ImportFromC/g 2024-02-09 09:03:34 +01:00