Alessandro Di Federico
6c115da619
Update pass names
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
4182a94346
Adopt MemoryEffects::none
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
ae871f5062
Adopt setOnlyReadsMemory
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
43fd690ea8
InaccessibleMemOnly: adopt MemoryEffects
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
e131817334
Drop usage of Type::getPointerElementType
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
a0fa150576
Drop usages of LoadInst::getPointerOperandType
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
7a08d51816
Drop usages of PointerType::getElementType
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
f777ccc4d3
Replace llvm::sys::fs::F_None with OF_None
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
26765f3d84
Drop usages of getBasicBlockList
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
a99d54457b
Drop usages of getInstList
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
aa6a60c5b8
Adopt new InlineFunction prototype
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
449e95021a
Replace CallBase::getNumArgOperands with arg_size
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
06f9bca598
Adopt {add,remove}FnAttribute
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
394111ed40
Add missing includes
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
d2caa1fad0
Make CreateLoad usages opaque pointers-compatible
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
dbcdad0a4d
Switch from llvm::Optional to std::optional
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
389342411a
Drop makeArrayRef
2023-04-08 08:42:24 +02:00
Alessandro Di Federico
1454ba6ebb
Link to the LLVMTargetParser library
2023-04-08 08:42:23 +02:00
Alessandro Di Federico
5ed9432a68
Fix ambiguous template function
...
Bumping LLVM version turned these into compiler errors.
2023-04-08 08:42:23 +02:00
Alessandro Di Federico
564519b6f9
Explicitly add -L for LLVM libraries path
2023-04-08 08:42:23 +02:00
Alessandro Di Federico
e3f9519ffc
Get rid of std::iterator
2023-04-08 08:42:23 +02:00
Alessandro Di Federico
31b46de38c
Remove dead code and fix spurious warnings
...
Remove some dead code or introduce suppressions for spurious.
These are results of more accurate warnings in clang 16.
2023-04-08 08:42:23 +02:00
Alessandro Di Federico
74ae629853
Drop experimental from coroutines
2023-04-08 08:42:23 +02:00
Alessandro Di Federico
52521f8cac
Adopt more standard library's features
2023-04-08 08:42:23 +02:00
Alessandro Di Federico
b2f22c168f
Adopt clang-format 16
2023-04-08 08:42:23 +02:00
Alessandro Di Federico
79bbd8b260
commands_registry.py: drop dict comprehension
2023-04-08 08:42:23 +02:00
Massimo Fioravanti
fc3f106640
Pipeline: fix accidental container materialization
...
Pipeline lazy containers were incorrectly materialized when it was not
necessary.
2023-04-07 14:37:14 +02:00
Pietro Fezzardi
ca1fd101db
Add opaque function to LLVM test helpers
...
This commits adds an opaque function that can be called by simple LLVM
IR snippets used in unit tests.
2023-04-06 14:25:18 +02:00
Alessandro Di Federico
2159dbbdc7
Merge branch 'feature/cstring-literals'
2023-04-04 11:03:21 +02:00
Kacper Kołodziej
bbebdd44b4
Prefer String.empty() case first
2023-04-04 09:30:09 +02:00
Kacper Kołodziej
17b0ecd78a
Compare to nullptr instead of implicit cast
...
Prefer explicit comparing to nullptr instead of implicit casting pointer
to bool.
2023-04-04 09:30:09 +02:00
Kacper Kołodziej
e7bb7d09df
Rename getStrByAddress to getStringByAddress
...
We don't use abbreviations in names.
2023-04-04 09:30:09 +02:00
Pietro Fezzardi
8801fc3b33
Support empty strings in getUniqueString
...
This commit works around a quirk of
`llvm::ConstantDataArray::getString`, which returns a
`llvm::ConstantAggregateZero` for empty strings.
This quirk caused assertions in the previous implementation when passing
an empty `String` to `getUniqueString`.
2023-04-04 09:30:09 +02:00
Pietro Fezzardi
91af14007f
Assert non-empty namespace in getUniqueString
...
Using an empty namespace causes the creation of a named metadata with an
empty string as name.
`llvm::verifyModule` does not check for that, so the `Module` still
verifies, but the on-disk serialization generated by `AsmPrinter.cpp`
prints `"empty name"` instead of the metadata name, and if the
serialized `Module` is then reparsed it parses succesfully but it does
not verify anymore.
2023-04-04 09:30:09 +02:00
Pietro Fezzardi
ec17b36801
Fix attributes of build_PlainMetaAddress function
...
These allow it to be DCE'd and CSE'd if possible directly by LLVM
instead of requiring us to handle it esplicitly as a special case.
2023-04-04 09:30:09 +02:00
Pietro Fezzardi
4c2602e956
RawBinaryView: add getStrByAddress method
...
This method is similar to `getByAddress`, but it returns an
`llvm::StringRef`.
It is intended for those users that need to manipulate the bytes as
strings. In those cases, the `llvm::ArrayRef<uint8_t>` returned by
`getByAddress` is not suitable, because it triggers warnings due to
`uint8_t` not being the same as `char`.
2023-04-04 09:30:09 +02:00
Kacper Kołodziej
1b8801c9dc
Add RawBinaryView::isReadOnly method
...
isReadOnly returns true if segment which contains region defined with
MetaAddress and size is not writable.
2023-04-04 09:30:08 +02:00
Kacper Kołodziej
d281d1fa05
Add --binary argument to llvm_pipeline.py
2023-04-04 09:30:08 +02:00
Giacomo Vercesi
f7c796553b
ContainerSet: fix typo
...
Fix a typo in the code of ContainerSet.intersect that would lead to an
incorrect intersection.
2023-03-31 15:50:46 +02:00
Alessandro Di Federico
94676ffde8
Merge branch 'feature/analyses-list'
2023-03-23 11:33:31 +01:00
Giacomo Vercesi
2e96e09f63
Drop analyze-all
...
Drop all the uses of analyzeAll and swap its use with the invocation of
the appropriate analysesList
2023-03-22 17:50:02 +01:00
Giacomo Vercesi
af237074f3
Implement AnalysesList in Python API & GraphQL
...
Implement the new functionality of AnalysesList on the python's side of
rev.ng and the GraphQL schema both in static and autogenerated form
2023-03-22 17:31:46 +01:00
Giacomo Vercesi
23286dc58f
GraphQL: expose analysis options
...
Add an additional parameter that allows specifying options for analyses
as a serialized json string
2023-03-22 17:31:46 +01:00
Giacomo Vercesi
1f097bb46a
revng.api: Fix leftover snake_case in as_dict
...
This commit fixes the name of the fields returned by the `as_dict`
function that were left in snake_case when the field in the schema was
camelCase
2023-03-22 17:31:46 +01:00
Giacomo Vercesi
a926ca8fcb
revng: make cmd tools analysesList-aware
...
Add the possibility to use analyses lists on tools where the use of
analyses names is allowed
2023-03-22 17:31:46 +01:00
Massimo Fioravanti
0373732b69
Add auto-analysis list
...
Introduces a default analysis list indede to be run first on binaries.
2023-03-22 17:31:46 +01:00
Massimo Fioravanti
312e2e8d53
Add analyses lists
...
Introduces the possibility of specifiying lists of analyses as way to
give them coherent names.
2023-03-22 17:31:46 +01:00
Alessandro Di Federico
b866e9010e
ELFImporter: fix setting gp_mips canonical value
...
We used to set the canonical value of the MIPS gp register even in
absence of PLT, leading to a crash (specifically on archlinux librt.so).
2023-03-22 14:22:24 +01:00
Djordje Todorovic
956160e667
TypeCopier: Avoid copying the types twice
2023-03-22 11:38:12 +01:00
Alessandro Di Federico
2fdfaef77e
Merge branch 'feature/fix-rename'
2023-03-20 16:38:11 +01:00