Decompiler Class Reference

#include <qtgui2/DecompilerThread.h>

Inheritance diagram for Decompiler:

Watcher List of all members.

Detailed Description

Definition at line 14 of file DecompilerThread.h.

Public Slots

void changeInputFile (const QString &f)
void changeOutputPath (const QString &path)
void decode ()
void decompile ()
void generateCode ()
void load ()
void stopWaiting ()

Signals

void consideringProc (const QString &parent, const QString &name)
void debuggingPoint (const QString &name, const QString &description)
void decodeCompleted ()
void decoding ()
void decompileCompleted ()
void decompiling ()
void decompilingProc (const QString &name)
void generateCodeCompleted ()
void generatingCode ()
void loadCompleted ()
void loading ()
void machineType (const QString &machine)
void newCluster (const QString &name)
void newEntrypoint (unsigned int addr, const QString &name)
void newLibProc (const QString &name, const QString &params)
void newProcInCluster (const QString &name, const QString &cluster)
void newSection (const QString &name, unsigned int start, unsigned int end)
void newUserProc (const QString &name, unsigned int addr)
void removeLibProc (const QString &name)
void removeUserProc (const QString &name, unsigned int addr)

Public Member Functions

void addEntryPoint (ADDRESS a, const char *nam)
virtual void alert_considering (Proc *parent, Proc *p)
virtual void alert_decompile_debug_point (UserProc *p, const char *description)
virtual void alert_decompiling (UserProc *p)
virtual void alert_new (Proc *p)
virtual void alert_remove (Proc *p)
virtual void alert_update_signature (Proc *p)
 Decompiler ()
const char * getClusterFile (const QString &name)
void getCompoundMembers (const QString &name, QTableWidget *tbl)
bool getRtlForProc (const QString &name, QString &rtl)
const char * getSigFile (const QString &name)
void removeEntryPoint (ADDRESS a)
void renameProc (const QString &oldName, const QString &newName)
void rereadLibSignatures ()
void setDebugging (bool d)
void setNoDecodeChildren (bool d)
void setUseDFTA (bool d)

Protected Member Functions

void emitClusterAndChildren (Cluster *root)
const char * procStatus (UserProc *p)

Protected Attributes

bool debugging
FrontEndfe
QString filename
Progprog
std::vector< ADDRESSuser_entrypoints
bool waiting


Constructor & Destructor Documentation

Decompiler::Decompiler  )  [inline]
 

Definition at line 19 of file DecompilerThread.h.


Member Function Documentation

void Decompiler::addEntryPoint ADDRESS  a,
const char *  nam
 

Definition at line 69 of file DecompilerThread.cpp.

References FrontEnd::AddSymbol(), fe, and user_entrypoints.

Referenced by MainWindow::on_addButton_pressed().

void Decompiler::alert_considering Proc parent,
Proc p
[virtual]
 

Reimplemented from Watcher.

Definition at line 225 of file DecompilerThread.cpp.

References consideringProc(), and Proc::getName().

void Decompiler::alert_decompile_debug_point UserProc p,
const char *  description
[virtual]
 

Reimplemented from Watcher.

Definition at line 284 of file DecompilerThread.cpp.

References debugging, debuggingPoint(), Proc::getName(), LOG, and waiting.

void Decompiler::alert_decompiling UserProc p  )  [virtual]
 

Reimplemented from Watcher.

Definition at line 230 of file DecompilerThread.cpp.

References decompilingProc(), and Proc::getName().

void Decompiler::alert_new Proc p  )  [virtual]
 

Reimplemented from Watcher.

Definition at line 235 of file DecompilerThread.cpp.

References Signature::getNumParams(), Signature::getParamName(), Signature::getParamType(), Proc::getSignature(), Proc::isLib(), Signature::isUnknown(), and NULL.

Referenced by alert_update_signature().

void Decompiler::alert_remove Proc p  )  [virtual]
 

Reimplemented from Watcher.

Definition at line 257 of file DecompilerThread.cpp.

References Proc::getName(), Proc::isLib(), and removeLibProc().

void Decompiler::alert_update_signature Proc p  )  [virtual]
 

Reimplemented from Watcher.

Definition at line 266 of file DecompilerThread.cpp.

References alert_new().

void Decompiler::changeInputFile const QString &  f  )  [slot]
 

Definition at line 82 of file DecompilerThread.cpp.

References filename.

Referenced by MainWindow::on_inputFileComboBox_currentIndexChanged(), and MainWindow::on_inputFileComboBox_editTextChanged().

void Decompiler::changeOutputPath const QString &  path  )  [slot]
 

Definition at line 87 of file DecompilerThread.cpp.

References Boomerang::get(), and Boomerang::setOutputDirectory().

Referenced by MainWindow::on_outputPathComboBox_editTextChanged().

void Decompiler::consideringProc const QString &  parent,
const QString &  name
[signal]
 

Referenced by alert_considering().

void Decompiler::debuggingPoint const QString &  name,
const QString &  description
[signal]
 

Referenced by alert_decompile_debug_point().

void Decompiler::decode  )  [slot]
 

Definition at line 141 of file DecompilerThread.cpp.

References FrontEnd::decode(), Prog::decodeEntryPoint(), decoding(), fe, FrontEnd::getMainEntryPoint(), NULL, prog, and user_entrypoints.

void Decompiler::decodeCompleted  )  [signal]
 

void Decompiler::decoding  )  [signal]
 

Referenced by decode().

void Decompiler::decompile  )  [slot]
 

Definition at line 167 of file DecompilerThread.cpp.

References Prog::decompile(), decompileCompleted(), decompiling(), and prog.

void Decompiler::decompileCompleted  )  [signal]
 

Referenced by decompile().

void Decompiler::decompiling  )  [signal]
 

Referenced by decompile().

void Decompiler::decompilingProc const QString &  name  )  [signal]
 

Referenced by alert_decompiling().

void Decompiler::emitClusterAndChildren Cluster root  )  [protected]
 

Definition at line 176 of file DecompilerThread.cpp.

References Cluster::getChild(), Cluster::getName(), Cluster::getNumChildren(), and newCluster().

Referenced by generateCode().

void Decompiler::generateCode  )  [slot]
 

Definition at line 183 of file DecompilerThread.cpp.

References emitClusterAndChildren(), Prog::generateCode(), generatingCode(), Prog::getFirstUserProc(), Prog::getNextUserProc(), Prog::getRootCluster(), newProcInCluster(), and prog.

void Decompiler::generateCodeCompleted  )  [signal]
 

void Decompiler::generatingCode  )  [signal]
 

Referenced by generateCode().

const char * Decompiler::getClusterFile const QString &  name  ) 
 

Definition at line 309 of file DecompilerThread.cpp.

References Prog::findCluster(), Cluster::getOutPath(), NULL, and prog.

void Decompiler::getCompoundMembers const QString &  name,
QTableWidget *  tbl
 

Definition at line 329 of file DecompilerThread.cpp.

References Type::asCompound(), CompoundType::getName(), Type::getNamedType(), CompoundType::getNumTypes(), CompoundType::getOffsetTo(), Type::getSize(), CompoundType::getType(), NULL, and Type::resolvesToCompound().

Referenced by MainWindow::on_structName_returnPressed().

bool Decompiler::getRtlForProc const QString &  name,
QString &  rtl
 

Definition at line 272 of file DecompilerThread.cpp.

References Prog::findProc(), Proc::isLib(), UserProc::print(), and prog.

Referenced by RTLEditor::updateContents().

const char * Decompiler::getSigFile const QString &  name  ) 
 

Definition at line 301 of file DecompilerThread.cpp.

References Prog::findProc(), Signature::getSigFile(), Proc::getSignature(), Proc::isLib(), NULL, and prog.

void Decompiler::load  )  [slot]
 

Definition at line 92 of file DecompilerThread.cpp.

References fe, filename, Prog::getMachine(), FrontEnd::Load(), loading(), MACHINE_HPRISC, MACHINE_PALM, MACHINE_PENTIUM, MACHINE_PPC, MACHINE_SPARC, MACHINE_ST20, machineType(), NULL, prog, FrontEnd::readLibraryCatalog(), and Prog::setFrontEnd().

void Decompiler::loadCompleted  )  [signal]
 

void Decompiler::loading  )  [signal]
 

Referenced by load().

void Decompiler::machineType const QString &  machine  )  [signal]
 

Referenced by load().

void Decompiler::newCluster const QString &  name  )  [signal]
 

Referenced by emitClusterAndChildren().

void Decompiler::newEntrypoint unsigned int  addr,
const QString &  name
[signal]
 

void Decompiler::newLibProc const QString &  name,
const QString &  params
[signal]
 

void Decompiler::newProcInCluster const QString &  name,
const QString &  cluster
[signal]
 

Referenced by generateCode().

void Decompiler::newSection const QString &  name,
unsigned int  start,
unsigned int  end
[signal]
 

void Decompiler::newUserProc const QString &  name,
unsigned int  addr
[signal]
 

const char * Decompiler::procStatus UserProc p  )  [protected]
 

Definition at line 200 of file DecompilerThread.cpp.

References UserProc::getStatus(), PROC_CODE_GENERATED, PROC_DECODED, PROC_EARLYDONE, PROC_FINAL, PROC_INCYCLE, PROC_PRESERVEDS, PROC_SORTED, PROC_UNDECODED, and PROC_VISITED.

void Decompiler::removeEntryPoint ADDRESS  a  ) 
 

Definition at line 74 of file DecompilerThread.cpp.

References user_entrypoints.

Referenced by MainWindow::on_removeButton_pressed().

void Decompiler::removeLibProc const QString &  name  )  [signal]
 

Referenced by alert_remove().

void Decompiler::removeUserProc const QString &  name,
unsigned int  addr
[signal]
 

void Decompiler::renameProc const QString &  oldName,
const QString &  newName
 

Definition at line 322 of file DecompilerThread.cpp.

References Prog::findProc(), prog, and Proc::setName().

Referenced by MainWindow::on_userProcs_cellChanged().

void Decompiler::rereadLibSignatures  ) 
 

Definition at line 317 of file DecompilerThread.cpp.

References prog, and Prog::rereadLibSignatures().

Referenced by MainWindow::on_actionSave_activated().

void Decompiler::setDebugging bool  d  )  [inline]
 

Definition at line 35 of file DecompilerThread.h.

References debugging.

Referenced by MainWindow::on_actionEnable_toggled().

void Decompiler::setNoDecodeChildren bool  d  ) 
 

Definition at line 65 of file DecompilerThread.cpp.

References Boomerang::get(), and Boomerang::noDecodeChildren.

Referenced by MainWindow::on_enableNoDecodeChildren_toggled().

void Decompiler::setUseDFTA bool  d  ) 
 

Definition at line 61 of file DecompilerThread.cpp.

References Boomerang::dfaTypeAnalysis, and Boomerang::get().

Referenced by MainWindow::on_enableDFTAcheckBox_toggled().

void Decompiler::stopWaiting  )  [slot]
 

Definition at line 296 of file DecompilerThread.cpp.

References waiting.

Referenced by MainWindow::on_actionEnable_toggled(), and MainWindow::on_actionStep_activated().


Member Data Documentation

bool Decompiler::debugging [protected]
 

Definition at line 78 of file DecompilerThread.h.

Referenced by alert_decompile_debug_point(), and setDebugging().

FrontEnd* Decompiler::fe [protected]
 

Definition at line 80 of file DecompilerThread.h.

Referenced by addEntryPoint(), decode(), and load().

QString Decompiler::filename [protected]
 

Definition at line 83 of file DecompilerThread.h.

Referenced by changeInputFile(), and load().

Prog* Decompiler::prog [protected]
 

Definition at line 81 of file DecompilerThread.h.

Referenced by decode(), decompile(), generateCode(), getClusterFile(), getRtlForProc(), getSigFile(), load(), renameProc(), and rereadLibSignatures().

std::vector<ADDRESS> Decompiler::user_entrypoints [protected]
 

Definition at line 88 of file DecompilerThread.h.

Referenced by addEntryPoint(), decode(), and removeEntryPoint().

bool Decompiler::waiting [protected]
 

Definition at line 78 of file DecompilerThread.h.

Referenced by alert_decompile_debug_point(), and stopWaiting().


The documentation for this class was generated from the following files:
Generated on Tue Sep 19 21:18:41 2006 for Boomerang by  doxygen 1.4.6