Ejemplo n.º 1
0
 public SymbolManager(ITracer aTracer)
 {
     iTracer = aTracer;
     //
     iEngineROM  = new ROMEngine(this);
     iEngineROFS = new ROFSEngine(this);
 }
Ejemplo n.º 2
0
        public static TFileType IsSupported(string aFileName)
        {
            TFileType ret = TFileType.EFileNotSupported;
            //
            FileInfo fileInfo = new FileInfo(aFileName);

            if (fileInfo.Exists)
            {
                // Try rom then rofs
                ret = ROMEngine.IsSupported(aFileName);
                if (ret == TFileType.EFileNotSupported)
                {
                    ret = ROFSEngine.IsSupported(aFileName);
                }
            }
            //
            return(ret);
        }
Ejemplo n.º 3
0
        public void LoadDynamicCodeSegments(CodeSegDefinitionCollection aCodeSegments, TSynchronicity aSynchronicity)
        {
            // Unload any pre-existing dynamically loaded content
            ROFSEngine.UnloadAll();

            // We must attempt to dynamically load all the code segements listed.
            // For codesegments that we have no corresponding collection for, we'll allow
            // a stub codesegment to be created in the ROFS engine - this ensures we
            // at least show the codesegment name (though not function addresses) when we
            // encounter an unrecognised address within the codesegment address space.
            //
            // For everything else, we load it (if it exists) or then if it's already been
            // loaded by the CORE ROM symbol file, we ignore the request.

            // These are the code segs that we'll eventually push through to the
            // ROFS engine.
            CodeSegDefinitionCollection codeSegsToAttemptToLoad = new CodeSegDefinitionCollection();

            // First pass - identify which code seg entries we already have loaded.
            foreach (CodeSegDefinition def in aCodeSegments)
            {
                // Check if there is already a valid definition for this entry in
                // the CORE ROM symbol table. If there is, the we don't need to do
                // anything.
                bool loaded = ROMEngine.IsLoaded(def);
                if (!loaded)
                {
                    Trace("SymbolManager.LoadDynamicCodeSegments() - will attempt to load: " + def);
                    codeSegsToAttemptToLoad.Add(def);
                }
                else
                {
                    Trace("SymbolManager.LoadDynamicCodeSegments() - not loading XIP code seg: " + def);
                }
            }

            // Now, we have a ratified list that contains only code segments that weren't already managed
            // by the CORE ROM engine.
            ROFSEngine.LoadFromDefinitionCollection(codeSegsToAttemptToLoad, aSynchronicity);
        }
Ejemplo n.º 4
0
 public void Clear()
 {
     ClearTags();
     ROFSEngine.Reset();
     ROMEngine.Reset();
 }