Beispiel #1
0
        private void AddRegister(ParserParagraph aPara, ParserField aField, ParserFieldName aFieldName, uint aValue)
        {
            RegisterCollection.TType type = (RegisterCollection.TType)aPara.Tag;
            string regName = aFieldName.Name;

            // USR registers are a bit tricky since they are largely shared. Only R13 and R14 are
            // really USR specific.
            if (type == RegisterCollection.TType.ETypeUser)
            {
                ArmRegister reg = new ArmRegister(regName, aValue);
                //
                switch (reg.RegType)
                {
                default:
                    type = RegisterCollection.TType.ETypeCommonBank;
                    break;

                case TArmRegisterType.EArmReg_SP:
                case TArmRegisterType.EArmReg_LR:
                    break;
                }
            }

            RegisterCollection regCollection = iInfo[type];

            regCollection.Add(regName, aValue);
        }
Beispiel #2
0
        public void SetThreadNStateWaitObject(ParserParagraph aParagraph, ParserFieldName aParameterName, uint aWaitObjectAddress)
        {
            System.Diagnostics.Debug.Assert(aParagraph.Tag is NThread);
            NThread thread = (NThread)aParagraph.Tag;

            thread.WaitObj = aWaitObjectAddress;
        }
Beispiel #3
0
        public void SetMessageQueueState(ParserLine aLine, ParserFieldName aFieldName, string aState)
        {
            System.Diagnostics.Debug.Assert(aLine.Tag is DMsgQueue);
            DMsgQueue queue = (DMsgQueue)aLine.Tag;

            DMsgQueue.TQueueState state = DMsgQueue.StateByString(aState);
            queue.State = state;
        }
Beispiel #4
0
        public void AddChunkToProcess(ParserParagraph aParagraph, ParserFieldName aParameterName, uint aParameterValue)
        {
            System.Diagnostics.Debug.Assert(aParagraph.Tag is DProcess);
            DProcess process = (DProcess)aParagraph.Tag;
            ProcessChunkCollection chunks = process.Chunks;
            //
            ProcessChunk chunk = new ProcessChunk(process.CrashDebugger, aParameterValue, 0);

            chunks.Add(chunk);
        }
Beispiel #5
0
        public void SetChunkAccessCount(ParserParagraph aParagraph, ParserFieldName aParameterName, int aParameterValue)
        {
            System.Diagnostics.Debug.Assert(aParagraph.Tag is DProcess);
            DProcess process = (DProcess)aParagraph.Tag;
            ProcessChunkCollection chunks = process.Chunks;
            //
            int count = chunks.Count;

            if (count > 0)
            {
                ProcessChunk lastEntry = chunks[count - 1];
                lastEntry.AccessCount = aParameterValue;
            }
        }
Beispiel #6
0
        public void AddCodeSegToProcess(ParserParagraph aParagraph, ParserFieldName aParameterName, uint aParameterValue)
        {
            System.Diagnostics.Debug.Assert(aParagraph.Tag is DProcess);
            DProcess process = (DProcess)aParagraph.Tag;
            ProcessCodeSegCollection codeSegs = process.CodeSegments;

            //
            if (aParameterName == "lib")
            {
                int count = codeSegs.Count;
                if (count > 0)
                {
                    ProcessCodeSeg lastEntry = codeSegs[count - 1];
                    lastEntry.LibraryAddress = aParameterValue;
                }
            }
            else if (aParameterName == "seg")
            {
                ProcessCodeSeg entry = new ProcessCodeSeg(process.CrashDebugger);
                entry.CodeSegAddress = aParameterValue;
                codeSegs.Add(entry);
            }
        }