Exemple #1
0
        internal void initHeapMemory(uint @startHeapMemory)
        {
            var mem = MRT.Ram.Stream;
            var c   = MRT.Registers["esi"];

            mem.Stream.Seek(c);
            mem.Stream.push(ObjectsMap.Serialize(@startHeapMemory, ushort.MaxValue, ushort.MaxValue), 64);
        }
Exemple #2
0
        internal void destVar()
        {
            var mem = MRT.Ram.Stream;
            var c   = MRT.Registers["esi"] -= 8;

            mem.Stream.Seek(c);
            mem.Stream.push(ObjectsMap.Serialize(0, 0, 0), 64);
        }
Exemple #3
0
        public unsafe static ObjectsMap ToObjectsMap(byte[] bytes)
        {
            long l = 0;

            fixed(byte *numRef = &(bytes[0]))
            l = *(((long *)numRef));

            ObjectsMap j = new ObjectsMap()
            {
                address   = (uint)l & 0xfffffff,
                size      = (ushort)(l >> 32),
                isDeleted = (uint)(l >> 48),
            };

            return(j);
        }
Exemple #4
0
        internal uint newVar(ushort size)
        {
            var mem = MRT.Ram.Stream;
            var c   = MRT.Registers["esi"];

            mem.Seek(c - 8);
            uint addr = (uint)mem.read(32) + (uint)mem.read(16);

            mem.Stream.Seek(c);
            mem.Stream.push(ObjectsMap.Serialize(addr, size, 0), 64);
            MRT.Registers["esi"] += 8;
            var q = @"{
                    
                }";

            return(addr);
        }