def _mcb_Architecture(self, name, value): # This is for legacy stuff... self.arch = envi.getArchModule(value) self.psize = self.arch.getPointerSize() archid = envi.getArchByName(value) self.setMemArchitecture(archid)
def __init__(self, archname=None): # For the crazy thread-call-proxy-thing # (must come first for __getattribute__ self.requires_thread = {} self.proxymeth = None # FIXME hack for now... self._released = False # The universal place for all modes # that might be platform dependant... self.modes = {} self.modedocs = {} self.notifiers = {} # For all transient data (if notifiers want # to track stuff per-trace self.metadata = {} self.initMode("RunForever", False, "Run until RunForever = False") self.initMode("NonBlocking", False, "A call to wait() fires a thread to wait *for* you") self.initMode( "ThreadProxy", True, "Proxy necissary requests through a single thread (can deadlock...)" ) self.initMode( "SingleStep", False, "All calls to run() actually just step. This allows RunForever + SingleStep to step forever ;)" ) self.initMode("FastStep", False, "All stepi() will NOT generate a step event") self.regcache = None self.regcachedirty = False self.sus_threads = {} # A dictionary of suspended threads # Set if we're a server and this trace is proxied self.proxy = None # Set us up with an envi arch module # FIXME eventually we should just inherit one... if archname == None: archname = envi.getCurrentArch() arch = envi.getArchByName(archname) self.setMeta('Architecture', archname) self.arch = envi.getArchModule(name=archname) e_resolv.SymbolResolver.__init__(self, width=self.arch.getPointerSize()) e_mem.IMemory.__init__(self, arch=arch) e_reg.RegisterContext.__init__(self) # Add event numbers to here for auto-continue self.auto_continue = [ NOTIFY_LOAD_LIBRARY, NOTIFY_CREATE_THREAD, NOTIFY_UNLOAD_LIBRARY, NOTIFY_EXIT_THREAD, NOTIFY_DEBUG_PRINT ]
def _mcb_Architecture(self, name, value): # This is for legacy stuff... self.arch = envi.getArchModule(value) self.psize = self.arch.getPointerSize() archid = envi.getArchByName(value) self.setMemArchitecture(archid) # Default calling convention for architecture # This will be superceded by Platform and Parser settings defcall = self.arch.getArchDefaultCall() if defcall: self.setMeta('DefaultCall', defcall)
def __init__(self, archname=None): # For the crazy thread-call-proxy-thing # (must come first for __getattribute__ self.requires_thread = {} self.proxymeth = None # FIXME hack for now... self._released = False # The universal place for all modes # that might be platform dependant... self.modes = {} self.modedocs = {} self.notifiers = {} # For all transient data (if notifiers want # to track stuff per-trace self.metadata = {} self.initMode("RunForever", False, "Run until RunForever = False") self.initMode("NonBlocking", False, "A call to wait() fires a thread to wait *for* you") self.initMode("ThreadProxy", True, "Proxy necissary requests through a single thread (can deadlock...)") self.initMode("SingleStep", False, "All calls to run() actually just step. This allows RunForever + SingleStep to step forever ;)") self.initMode("FastStep", False, "All stepi() will NOT generate a step event") self.regcache = None self.regcachedirty = False self.sus_threads = {} # A dictionary of suspended threads # Set if we're a server and this trace is proxied self.proxy = None # Set us up with an envi arch module # FIXME eventually we should just inherit one... if archname == None: archname = envi.getCurrentArch() arch = envi.getArchByName( archname ) self.setMeta('Architecture', archname) self.arch = envi.getArchModule(name=archname) e_resolv.SymbolResolver.__init__(self, width=self.arch.getPointerSize()) e_mem.IMemory.__init__(self, arch=arch) e_reg.RegisterContext.__init__(self) # Add event numbers to here for auto-continue self.auto_continue = [NOTIFY_LOAD_LIBRARY, NOTIFY_CREATE_THREAD, NOTIFY_UNLOAD_LIBRARY, NOTIFY_EXIT_THREAD, NOTIFY_DEBUG_PRINT]