Alessandro Di Federico
e80d159944
revng-pipline: simplify Kinds.h
2022-02-08 17:44:33 +01:00
Alessandro Di Federico
9788c49529
Fix pipeline test suite names
2022-02-08 17:44:26 +01:00
Alessandro Di Federico
fa8061b805
Drop dead Kinds
2022-02-08 17:44:19 +01:00
Alessandro Di Federico
80d92e2fed
Drop FunctionCounter-related files
2022-02-08 17:44:08 +01:00
Alessandro Di Federico
c8026ac401
Minor changes
2022-02-08 17:40:09 +01:00
Pietro Fezzardi
29c50fa909
Model: reserve names defined in stdint.h
...
This commit adds a bunch of type names and macro names to the set of
reserved keywords that cannot be used for names in the revng Model.
These are the names defined in the stdint.h standard C header, that is
included automatically by the decompiler in decompiled code.
We need to reserve these names otherwise it would be possible to add
things to the revng Model with names that clash with the names defined
in stdint.h, which would in turn break recompilation of decompiled code
because of conflicting definitions.
2022-02-08 15:54:02 +01:00
Alessandro Di Federico
d9c893547f
Merge branch 'feature/revng-pipes'
2022-02-08 08:45:17 +01:00
Massimo Fioravanti
d696197597
scripts/revng: adopt revng-pipeline
...
The revng-translate tool is now a driver for revng-pipeline to perform
the translation.
This commit also drops computing the `-load` "roots". It shouldn't
really be necessary.
2022-02-08 00:05:03 +01:00
Massimo Fioravanti
67f9cbdf4c
Introduce the revng-pipeline CLI tool
2022-02-08 00:05:03 +01:00
Massimo Fioravanti
fe9686be03
revng-pipeline: introduce C API
2022-02-08 00:05:03 +01:00
Massimo Fioravanti
a8a8da3bae
Introduce revng pipes
...
This commit imports all the revng pipes (and other support utilities) to
be used with `revng-pipeline`. In particular, the pipes necessary for
binary translations have been introduced.
2022-02-08 00:05:03 +01:00
Massimo Fioravanti
6f0d0c4f9d
CodeGenerator: accept an external model
2022-02-07 22:24:39 +01:00
Massimo Fioravanti
98ecd38162
Drop PureLLVMPipe
...
Now LLVM passes can be used directly in an LLVMPipe without specifying a
contract for it.
2022-02-07 22:24:39 +01:00
Alessandro Di Federico
3b7d7c5f7e
Don't use llvm::outs
2022-02-07 22:24:39 +01:00
Alessandro Di Federico
fec5f3537b
s/Granularity/Rank/
2022-02-07 22:24:39 +01:00
Alessandro Di Federico
e2cd7cbcdf
Pipeline: simplify LLVMContainer
2022-02-07 20:11:37 +01:00
Massimo Fioravanti
396095706f
Minor changes to revngPipeline
2022-02-07 20:11:15 +01:00
Alessandro Di Federico
91fd04079a
AllPasses.h: include Verify.h
2022-02-07 20:11:15 +01:00
Alessandro Di Federico
0f084ed620
Minor changes
2022-02-07 16:55:46 +01:00
Alessandro Di Federico
21f16ce95d
Drop *.orig files
...
They have been accidentally committed.
2022-02-07 16:55:46 +01:00
Alessandro Di Federico
2b5610bc93
Merge branch 'feature/model-tooling'
2022-01-31 19:24:29 +01:00
Alessandro Di Federico
1c2527f6fa
mv tools/{revng-,}lift
2022-01-31 16:37:22 +01:00
Alessandro Di Federico
60b2dbab72
revng: support model subcommands
2022-01-31 16:28:26 +01:00
Alessandro Di Federico
78be0e9268
Explode TupleTree.h
2022-01-31 16:28:26 +01:00
Alessandro Di Federico
280848484e
SerializeModelPass: verify model
2022-01-31 16:28:17 +01:00
Alessandro Di Federico
c0f8110e4e
s/revng-compare-yaml/revng-model-compare/
2022-01-31 16:28:17 +01:00
Alessandro Di Federico
0d7decccb3
s/revng-dump-model/revng-model-to-json/
2022-01-31 16:28:17 +01:00
Alessandro Di Federico
7fba073058
Enable testing model diff
2022-01-31 16:28:17 +01:00
Alessandro Di Federico
a353e00ac1
Introduce model passes
2022-01-31 16:28:14 +01:00
Alessandro Di Federico
3980ee3fad
Introduce model tools
2022-01-31 16:28:14 +01:00
Alessandro Di Federico
29cf330fc8
TupleTreeDiff: use streams
2022-01-31 14:13:25 +01:00
Alessandro Di Federico
5c89a6a858
callOnPathSteps: fix UpcastablePointer handling
...
The version of callOnPathSteps without an actual instance was completely
ignoring the upcasted type of `UpcastablePointer`s. We now fix this by
calling the right template specialization, which we choose by inspecting
the key of the `UpcastablePointer`.
2022-01-31 14:13:25 +01:00
Alessandro Di Federico
c1ec001f46
TupleTreeDiff: dump any object
2022-01-31 14:13:25 +01:00
Alessandro Di Federico
2c2832c027
Merge branch 'feature/dedup-model-types'
2022-01-27 13:46:17 +01:00
Alessandro Di Federico
b3d6c721ad
Introduce purgeUnnamedAndUnreachableTypes
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
f14e722c86
Introduce deduplicateEquivalentTypes
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
f3634e165f
Introduce model::Type::localCompare
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
d0bb3d4c2c
CodeGenerator.cpp: use OriginalName for symbols
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
445066bd0a
CodeGenerator.cpp: posticipate DWARF import
...
This way we apply the optimization passes.
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
2d08050220
DwarfImporter: adopt OriginalName
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
dd7477664c
Update CustomName verification criteria
...
This commit ensures `CustomName` is unambiguous according to C symbols
rules.
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
74a7496020
deduplicateNames -> promoteOriginalName
...
This commit switches from `deduplicateNames`, which changed certain
`CustomName` values, to `promoteOriginalName`, which updates empty
`CustomName` using non-ambiguous versions of `OriginalName`.
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
3d1df0ab7d
Use OriginalName in tests/analysis/*.yml
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
863652f480
Introduce OriginalName in the type system
...
The goal of `OriginalName` is to keep track of the original name of a
symbol upon import.
In future, this will also be used to promote it to `CustomName`.
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
8d22c5205f
Push CustomName to model::Type
...
Before this commit `CustomName` was in each inheritor, except for
`model::PrimitiveType`.
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
54fcc1d7fe
struct_impl.cpp.tpl: include headers in any case
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
680924b643
CodeGenerator.cpp: drop some outdated assertions
...
Drop some outdated checks for `model::Binary::ImportedDynamicFunctions`
being sorted.
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
48565ee905
Move skip to STLExtras.h
...
It has nothing to do with IR.
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
09054e637a
Introduce TupleTree::replaceReferences
2022-01-27 11:51:03 +01:00
Alessandro Di Federico
b31e7b1f5e
Introduce model::Type::edges()
...
This makes building a graph for the type system very easy.
2022-01-27 11:51:03 +01:00