Commit Graph

19 Commits

Author SHA1 Message Date
Alessandro Di Federico 903617e79e IRHelpers: turn some functions into IRBuilder::* 2026-06-19 09:18:16 +02:00
Alessandro Di Federico 0bf97a9e68 getPointerSizedInteger: use model::Architecture
No need to get model::Binary.
2025-12-22 11:34:47 +01:00
Alessandro Di Federico f8bd4c3bac Move around some files in preparation for libtcg
* Make the following private headers public:
  * Lift/CPUStateAccessAnalysisPass.h
  * Lift/CSVOffsets.h
  * Lift/PTCDump.h
  * Lift/VariableManager.h
* Move from revngSupport to revngLift:
  * IRAnnotators.{h,cpp}
  * SelfReferencingDbgAnnotationWriter.{h,cpp}
* Move from revngSupport to revngModel:
  * FunctionTags.{h,cpp}
  * ProgramCounterHandler.{h,cpp}
* Move from revngSupport to revngRecompile:
  * OriginalAssemblyAnnotationWriter.{h,cpp}
2025-10-24 15:34:11 +02:00
Ivan Krysak 2ba5ca3e3d Suppress selected IRBuilder checks 2025-10-21 19:17:37 +03:00
Ivan Krysak 3561c2b907 Adopt IRBuilder wrapper 2025-10-21 19:17:01 +03:00
Ivan Krysak 374ee341fa Remove an unused logger 2025-09-10 17:44:02 +02:00
Pietro Fezzardi 03e0de9458 Improve debug info propagation in legacy pipeline 2025-09-10 17:44:02 +02:00
Ivan Krysak b5337d78da Minor Improvements 2025-07-23 11:38:50 +02:00
Pietro Fezzardi df3b4758e4 Add initModeTypesConsideringUses
Before this commit, initModelTypes always looked at uses of each
instructions to see if its knowledge of the instruction's model type
could be improved.

This is useful in some cases, but it's detrimental when building model
casts, because this requires to see the exact type computed for an
instruction.

This commit introduces a new function initModeTypesConsideringUses,
which works like old initModelTypes, considering uses.
In this way we can make sure that uses are considered when necessary,
like when computing types to build new local variables, and ignored when
necessary, e.g. when building model casts.
2025-05-29 09:38:01 +02:00
Pietro Fezzardi e9528f4647 Fix getCopyType function type
This commit changes the prototype of getCopeType, so that it now takes 2
arguments.
1. The llvm::Type returned by the Copy function. This can be any scalar
   llvm::Type.
2. The llvm::type of the argument representing the reference to the
   value being copied. This should be a pointer-sized integer, where
   pointer-sized means with the same size of a pointer in the
   architecture in the input binary.

The second argument is not strictly necessary for now, because the whole
decompilation framework expects a binary with a single architecture,
hence a well defined unambiguous pointer size.
This will be used fully only when we start supporting multiple binaries.
Whenever that happens, if we haven't already fully dropped the Copy
helper function we will have to update the associated
OpaqueFunctionsPool to a type pair as key: the return type and the type
of the argument.
2025-01-29 15:17:15 +01:00
Alessandro Di Federico 143c315196 Merge revng-c into revng 2024-11-21 10:50:55 +01:00
Alessandro Di Federico 2e4f4d09b9 Remaining FunctionTags have been moved to revng 2024-11-04 15:09:56 +01:00
Alessandro Di Federico e239e18b0c Adopt FunctionPoolTag 2024-11-04 15:09:56 +01:00
Alessandro Di Federico 9c99ac33ac s/serializeToLLVMString/toLLVMString/ 2024-09-27 10:35:10 +02:00
Ivan Krysak 94a0ad6b93 Adopt reworked model::Type 2024-06-27 11:07:01 +02:00
Alessandro Di Federico 5186a58053 s/FunctionMetadata/ControlFlowGraph/ 2024-06-18 17:56:24 +02:00
Pietro Fezzardi 37340a91a7 Don't skip non-isolated Function in FunctionPass
Before this commit, many passes in revng-c were skipping over
non-isolated functions.

Now revng-pipeline takes care of removing non-isolated functions so that
check can be omitted everywhere.
2024-03-19 09:44:00 +01:00
Alessandro Di Federico 0c212b66d9 Relicense to MIT 2024-02-29 17:03:36 +01:00
Alessandro Di Federico 7a2e315e29 s/IRCanonicalization/Canonicalize/g 2024-02-09 09:03:34 +01:00