Skip to content

Commit

Permalink
Add parseAPI/SymLiteCodeSource.h
Browse files Browse the repository at this point in the history
  • Loading branch information
hainest committed Apr 3, 2024
1 parent 280a852 commit f3251f1
Show file tree
Hide file tree
Showing 4 changed files with 58 additions and 6 deletions.
1 change: 1 addition & 0 deletions docs/parseAPI/developer/API.rst
Original file line number Diff line number Diff line change
Expand Up @@ -37,5 +37,6 @@ ParseAPI
ProbabilisticParser.h
StackTamperVisitor.h
SymbolicExpression.h
SymLiteCodeSource.h
ThunkData.h
util.h
16 changes: 16 additions & 0 deletions docs/parseAPI/developer/SymLiteCodeSource.h.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
.. _`sec-dev:SymLiteCodeSource.h`:

SymLiteCodeSource.h
###################

.. cpp:namespace:: Dyninst::ParseAPI::dev

.. cpp:class:: SymReaderCodeSource : public CodeSource

.. cpp:function:: void removeHint(Hint)
.. cpp:function:: static void addNonReturning(std::string func_name)
.. cpp:function:: void print_stats() const
.. cpp:function:: bool have_stats() const
.. cpp:function:: void incrementCounter(const std::string& name) const
.. cpp:function:: void addCounter(const std::string& name, int num) const
.. cpp:function:: void decrementCounter(const std::string& name) const
43 changes: 41 additions & 2 deletions docs/parseAPI/public/SymLiteCodeSource.h.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,44 @@
.. _`sec:SymLiteCodeSource.h`:

SymLiteCodeSource.h
===================
###################

.. cpp:namespace:: Dyninst::ParseAPI

.. cpp:class:: SymReaderCodeRegion : public CodeRegion

.. cpp:function:: SymReaderCodeRegion(SymReader *, SymSegment *)
.. cpp:function:: void names(Address, std::vector<std::string> &) override
.. cpp:function:: bool findCatchBlock(Address addr, Address & catchStart) override
.. cpp:function:: bool isValidAddress(const Address) const override
.. cpp:function:: void* getPtrToInstruction(const Address) const override
.. cpp:function:: void* getPtrToData(const Address) const override
.. cpp:function:: unsigned int getAddressWidth() const override
.. cpp:function:: bool isCode(const Address) const override
.. cpp:function:: bool isData(const Address) const override
.. cpp:function:: bool isReadOnly(const Address) const override
.. cpp:function:: Address offset() const override
.. cpp:function:: Address length() const override
.. cpp:function:: Architecture getArch() const override
.. cpp:function:: Address low() const override
.. cpp:function:: Address high() const override
.. cpp:function:: SymSegment * symRegion() const

.. cpp:namespace:: Dyninst::parseAPI
.. cpp:class:: SymReaderCodeSource : public CodeSource

.. cpp:function:: SymReaderCodeSource(SymReader *)
.. cpp:function:: SymReaderCodeSource(const char *)
.. cpp:function:: bool nonReturning(Address func_entry)
.. cpp:function:: bool nonReturningSyscall(int num)
.. cpp:function:: bool resizeRegion(SymSegment *, Address newDiskSize)
.. cpp:function:: SymReader * getSymReaderObject()
.. cpp:function:: bool isValidAddress(const Address) const
.. cpp:function:: void* getPtrToInstruction(const Address) const
.. cpp:function:: void* getPtrToData(const Address) const
.. cpp:function:: unsigned int getAddressWidth() const
.. cpp:function:: bool isCode(const Address) const
.. cpp:function:: bool isData(const Address) const
.. cpp:function:: bool isReadOnly(const Address) const
.. cpp:function:: Address offset() const
.. cpp:function:: Address length() const
.. cpp:function:: Architecture getArch() const
4 changes: 0 additions & 4 deletions parseAPI/h/SymLiteCodeSource.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,6 @@ namespace ParseAPI {

class CFGModifier;

/** SymReaderCodeRegion and SymReaderCodeSource implement CodeSource for program
binaries supported by the SymReaderAPI
**/

class SymReaderCodeRegion : public CodeRegion {
private:
SymReader * _symtab;
Expand Down

0 comments on commit f3251f1

Please sign in to comment.