Skip to content

Commit

Permalink
(Binary Analysis) Removed deprecated features
Browse files Browse the repository at this point in the history
Removed all RoseBin features:

* They have been deprecated for a while
* We've planning much longer to remove them
* They're largely untested
* They're replaced by better things
* We think nobody uses them
* They make our code coverage look bad
* The authors are no longer part of the ROSE team
  • Loading branch information
matzke1 committed May 6, 2017
1 parent cb1dfd0 commit 043c1e8
Show file tree
Hide file tree
Showing 162 changed files with 56 additions and 34,246 deletions.
3 changes: 0 additions & 3 deletions CMakeLists.txt
Expand Up @@ -1001,7 +1001,6 @@ endif (HAVE_DLFCN_H)
${ROSE_TOP_SRC_DIR}/src/frontend/PythonFrontend
${ROSE_TOP_SRC_DIR}/src/frontend/BinaryFormats
${ROSE_TOP_SRC_DIR}/src/frontend/BinaryLoader
${ROSE_TOP_SRC_DIR}/src/frontend/BinaryDisassembly
${ROSE_TOP_SRC_DIR}/src/frontend/Disassemblers
${ROSE_TOP_SRC_DIR}/src/frontend/ExecFormats
${ROSE_TOP_SRC_DIR}/src/frontend
Expand Down Expand Up @@ -1048,14 +1047,12 @@ endif (HAVE_DLFCN_H)
${ROSE_TOP_SRC_DIR}/src/midend/programTransformation/ompLowering
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis/CFG
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis/CallGraphAnalysis
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis/OAWrap
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis/bitvectorDataflow
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis/VirtualFunctionAnalysis
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis/defUseAnalysis
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis/distributedMemoryAnalysis
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis/dominanceAnalysis
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis/graphAnalysis
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis/pointerAnal
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis/staticSingleAssignment
${ROSE_TOP_SRC_DIR}/src/midend/programAnalysis/staticInterproceduralSlicing
Expand Down
1,077 changes: 0 additions & 1,077 deletions ChangeLog

Large diffs are not rendered by default.

10 changes: 0 additions & 10 deletions Makefile.am
Expand Up @@ -659,7 +659,6 @@ lcov:
-d src/frontend/ECJ_ROSE_Connection/.libs \
-d src/frontend/X10_ROSE_Connection/.libs \
-d src/frontend/PHPFrontend/.libs \
-d src/frontend/BinaryDisassembly/.libs \
-d src/frontend/BinaryLoader/.libs \
-d src/frontend/BinaryFormats/.libs \
-d src/frontend/Disassemblers/.libs \
Expand Down Expand Up @@ -754,9 +753,6 @@ librose-lcov.info: all-lcov.info
"$(top_srcdir)/src/backend/unparser/PHPCodeGeneration/*" \
"$(top_srcdir)/src/midend/programAnalysis/OAWrap/*" \
"$(top_srcdir)/src/midend/programAnalysis/OpenAnalysis/*" \
"$(top_srcdir)/src/frontend/BinaryDisassembly/*" \
"$(top_srcdir)/src/midend/binaryAnalyses/dataflowanalyses/*" \
"$(top_srcdir)/src/midend/binaryAnalyses/RoseBin_*" \
"$(top_srcdir)/src/midend/programAnalysis/genericDataflow/*" \
"$(top_srcdir)/src/frontend/CxxFrontend/EDG/EDG_4.9/*" \
"$(top_srcdir)/src/midend/astRewriteMechanism/*" \
Expand All @@ -772,7 +768,6 @@ librose-lcov.info: all-lcov.info
"$(top_srcdir)/src/midend/programTransformation/implicitCodeGeneration/*" \
"$(top_srcdir)/src/midend/programTransformation/singleStatementToBlockNormalization/*" \
"$(top_srcdir)/src/roseSupport/stringify.C" \
"$(top_srcdir)/src/midend/programAnalysis/graphAnalysis/*" \
"$(top_srcdir)/src/roseExtensions/roseHPCToolkit/*" \
"$(top_srcdir)/src/frontend/SageIII/nodeBuildFunctionsForAterms.C" \
"$(top_srcdir)/src/frontend/SageIII/astVisualization/*" \
Expand Down Expand Up @@ -807,9 +802,6 @@ librose_lcov_web_pages: librose-lcov.info
# src/backend/unparser/PHPCodeGeneration/*
# src/midend/programAnalysis/OAWrap/*
# src/midend/programAnalysis/OpenAnalysis/*
# src/frontend/BinaryDisassembly/*
# src/midend/binaryAnalyses/dataflowanalyses/*
# src/midend/binaryAnalyses/RoseBin_*
# src/midend/programAnalysis/genericDataflowflow/*
# src/frontend/CxxFrontend/EDG/EDG_4.9/*
# src/midend/astRewriteMechanism/*
Expand All @@ -826,7 +818,6 @@ librose_lcov_web_pages: librose-lcov.info
# src/midend/programTransformation/implicitCodeGeneration/*
# src/midend/programTransformation/singleStatementToBlockNormalization/*
# src/roseSupport/stringify.C
# src/midend/programAnalysis/graphAnalysis/*
#
#
# Directories to remove from ROSE:
Expand Down Expand Up @@ -856,7 +847,6 @@ librose_lcov_web_pages: librose-lcov.info
#
# What is this:
# src/midend/abstractMemoryObject (DTEC work by Liao)
# src/midend/programAnalysis/graphAnalysis (Old binary call graph support, superceeded by more recent work)
#
#
# Why are these so poorly tested:
Expand Down
4 changes: 0 additions & 4 deletions cmake/ConvenienceLibs.cmake
Expand Up @@ -129,8 +129,6 @@

# src/midend/programAnalysis/distributedMemoryAnalysis/Makefile.am: distributedMemoryAnalysis

# src/midend/programAnalysis/graphAnalysis/Makefile.am: SB_GraphAnalysis

# src/midend/programAnalysis/pointerAnal/Makefile.am: pointerAnal

# src/midend/programAnalysis/proceduralSlicing/Makefile.am: alternativeProgramSlicing
Expand Down Expand Up @@ -179,8 +177,6 @@ set(dominance_STAT_SRCS

# src/midend/ompLowering/Makefile.am: ompLowering

# src/frontend/BinaryDisassembly/Makefile.am: binaryFrontend

# src/frontend/SageIII/astMerge/Makefile.am: astMerge

# src/frontend/SageIII/astHiddenTypeAndDeclarationLists/Makefile.am: astHiddenTypeAndDeclarationLists
Expand Down
3 changes: 0 additions & 3 deletions config/Makefile.for.ROSE.includes.and.libs
Expand Up @@ -282,7 +282,6 @@ ROSE_INCLUDES_WITHOUT_BOOST_ISYSTEM_PATH = \
-I$(top_srcdir)/src/frontend/OpenFortranParser_SAGE_Connection \
-I$(top_srcdir)/src/frontend/ECJ_ROSE_Connection \
-I"$(JAVA_HOME)/include" \
-I$(top_srcdir)/src/frontend/BinaryDisassembly \
-I$(top_srcdir)/src/frontend/BinaryFormats \
-I$(top_srcdir)/src/frontend/BinaryLoader \
-I$(top_srcdir)/src/frontend/Disassemblers \
Expand Down Expand Up @@ -341,7 +340,6 @@ ROSE_INCLUDES_WITHOUT_BOOST_ISYSTEM_PATH = \
-I$(top_srcdir)/src/frontend/PHPFrontend \
$(ROSE_CLANG_FRONTEND_INCLUDE) \
-I$(top_srcdir)/src/frontend/PythonFrontend \
-I$(top_srcdir)/src/frontend/BinaryDisassembly \
-I$(top_srcdir)/src/frontend/BinaryFormats \
-I$(top_srcdir)/src/frontend/BinaryLoader \
-I$(top_srcdir)/src/frontend/Disassemblers \
Expand Down Expand Up @@ -402,7 +400,6 @@ ROSE_INCLUDES_WITHOUT_BOOST_ISYSTEM_PATH = \
-I$(top_srcdir)/src/midend/programAnalysis/defUseAnalysis \
-I$(top_srcdir)/src/midend/programAnalysis/distributedMemoryAnalysis \
-I$(top_srcdir)/src/midend/programAnalysis/dominanceAnalysis \
-I$(top_srcdir)/src/midend/programAnalysis/graphAnalysis \
-I$(top_srcdir)/src/midend/programAnalysis/pointerAnal \
-I$(top_srcdir)/src/midend/programAnalysis/staticInterproceduralSlicing \
-I$(top_srcdir)/src/midend/programAnalysis/valuePropagation \
Expand Down
2 changes: 0 additions & 2 deletions config/support-rose.m4
Expand Up @@ -1011,7 +1011,6 @@ AM_CONDITIONAL(ROSE_USE_INDENT, [test "x$INDENT" = "xindent"])
echo "value of INDENT variable = $INDENT"
# DQ (9/30/2009): Added checking for tclsh command (common in Linux, but not on some platforms).
# This command is used in the src/frontend/BinaryDisassembly/Makefile.am file.
AC_CHECK_PROGS(TCLSH, [tclsh])
AM_CONDITIONAL(ROSE_USE_TCLSH, [test "x$TCLSH" = "xtclsh"])
echo "value of TCLSH variable = $TCLSH"
Expand Down Expand Up @@ -2151,7 +2150,6 @@ src/Makefile
src/ROSETTA/Makefile
src/ROSETTA/src/Makefile
src/backend/Makefile
src/frontend/BinaryDisassembly/Makefile
src/frontend/BinaryFormats/Makefile
src/frontend/BinaryLoader/Makefile
src/frontend/CxxFrontend/Clang/Makefile
Expand Down
114 changes: 0 additions & 114 deletions docs/Rose/Tutorial/binaryAnalysis.tex
Expand Up @@ -4,120 +4,6 @@ \chapter{Binary Analysis}

See doxgyen ``Getting started with binary analysis'' chapter.

%% This chapter discusses the capabilities of ROSE to read, analyze and transform
%% (transformations to the binary file format) binary executables.
%%
%% Binary support in ROSE is currently based on a custom build \emph{ROSE Disassembler} (for ARM, x86, and PowerPC).
%%
%% The following code reads in a binary and creates a binary ROSE AST:
%%
%% {\mySmallFontSize
%% \begin{verbatim}
%% SgProject* project = frontend(argc,argv);
%% \end{verbatim}
%% }
%%
%% Similarily, one can unparse the AST to assembly using a call to the backend, cf. Figure ~\ref{Tutorial:examplesourcecode2}.
%%
%% The best documentation for ROSE's binary analysis capabilities is
%% found in the doxygen-generated API reference manual. Start with the
%% Binary Analysis FAQ in that manual.

%\subsection{IdaPro-mysql}

%A binary processed by IdaPro needs to be processed into a MySQL database (DB). With that DB,
%the following lines create a binary ROSE AST:


%{\mySmallFontSize
%\begin{verbatim}
% // create RoseBin object with DB specific information
% RoseBin* roseBin = new RoseBin(def_host_name,
% def_user_name,
% def_password,
% def_db_name);

% RoseBin_Arch::arch=RoseBin_Arch::bit32;
% RoseBin_OS::os_sys=RoseBin_OS::linux_op;
% RoseBin_OS_VER::os_ver=RoseBin_OS_VER::linux_26;
% RoseBin_Def::RoseAssemblyLanguage=x86;
% // connect to the DB
% roseBin->connect_DB(socket);
% // query the DB to retrieve all data
% SgAsmNode* globalBlock = roseBin->retrieve_DB_IDAPRO();
% // close the DB
% roseBin->close_DB();

% // traverse the AST and test it
% roseBin->test();
%\end{verbatim}
%}




%\section{The AST}

%The binary AST can now be unparsed to represent assembly instructions, cf. Figure ~\ref{Tutorial:examplesourcecode2}:

%{\mySmallFontSize
%\begin{verbatim}
% SgAsmGenericFile* file = project->get_file(0).get_binaryFile();
% RoseBin_unparse* unparser = new RoseBin_unparse();
% unparser->init(file->get_global_block(), fileName);
% unparser->unparse();
%\end{verbatim}
%}


%To visualize the binary AST, we can use the following lines to
%write the AST out to a .dot format:

%{\mySmallFontSize
%\begin{verbatim}
% string filename=''_binary_tree.dot'';
% AST_BIN_Traversal* trav = new AST_BIN_Traversal();
% trav->run(file->get_global_block(), filename);
%\end{verbatim}
%}


%% \section{The ControlFlowGraph}
%%
%% Based on a control flow traversal of the binary AST, a separate control flow graph
%% is created that can be used for further analyses.
%%
%% TODO: Describe recent work on binary CFG.

%{\mySmallFontSize
%\begin{verbatim}
% // forward or backward analysis ?
% bool forward = true;
% // when creating a visual representation, visualized edges?
% bool edges = true;
% // visualize multiple edges or merge edges between same nodes to one edge?
% bool mergedEdges = false;
% // create DotGraph Object or/and GmlGraph Object
% RoseBin_DotGraph* dotGraph = new RoseBin_DotGraph();
% RoseBin_GMLGraph* gmlGraph = new RoseBin_GMLGraph();
% char* cfgFileNameDot = ``cfg.dot'';
% char* cfgFileNameGml = ``gml.dot'';
% RoseBin_ControlFlowAnalysis* cfganalysis = new RoseBin_ControlFlowAnalysis(
% file->get_global_block(), forward, NULL, edges);
% cfganalysis->run(dotGraph, cfgFileNameDot, mergedEdges);
% cfganalysis->run(gmlGraph, cfgFileNameGml, mergedEdges);
%\end{verbatim}
%}

%The control flow graph of our example is represented in Figure ~\ref{Tutorial:examplefig1}.
%The graph shows different functions represented purple, containing various instructions.
%Instructions within a function are represented within the same box. Common instructions are
%represented yellow. Green instructions are jumps and pink instructions calls and returns.
%Respectively, blue edges are call relationships and red edges return relationships.
%Black edges represent plain controlflow from one instruction to the next.



\section{DataFlow Analysis}

%\begin{figure}
Expand Down
3 changes: 0 additions & 3 deletions docs/Rose/binaryAnalysis.tex
Expand Up @@ -191,9 +191,6 @@ \subsection{Dwarf Debug Support}
operate on the binary executable when the binary executable has been generated to include
Dwarf debug information.

\fixme{Consider moving the Dwarf support from {\em src/frontend/SageIII} to
{\em src/frontend/BinaryDisassembly} instead.}

\section{Binary Analysis}

A number of binary analysis passes are provided, most are a part of the Compass
Expand Down

0 comments on commit 043c1e8

Please sign in to comment.