예제 #1
0
        public string[] GetModifiedRegistersDifferences(MemoryMap otherMap)
        {
            List <string> difs = new List <string> ();

            // Only check modified registers
            List <dynamic> modifiedRegisters = this.GetModifiedRegisters().GetAllElements();

            foreach (dynamic register in modifiedRegisters)
            {
                string name = register.id;

                if (!otherMap.ContainsMember(name) ||            // Register not present in other memory map
                    !base[name].Equals(otherMap[name]))          // Both registers are not equal
                {
                    difs.Add(name);
                    continue;
                }
            }

            return(difs.ToArray());
        }
예제 #2
0
 public bool ValidateModifiedRegisters(MemoryMap otherMap)
 {
     return(this.GetModifiedRegistersDifferences(otherMap).Length == 0);
 }