예제 #1
0
 /// <summary>
 /// Advances the current integrated instruction to the next. EndOfIIStream is the IROP flag for end of instructions for this prototype.
 /// </summary>
 public void NextII()
 {
     prevII = curII;
     bIndex++;
     if (bIndex >= curBlock.iis.Count)                    //advance to next block if necessary.
     {
         if (curBlock.GetNameIndex() + 1 >= blocks.Count) //no more instructions.
         {
             //IntegratedInstruction end = new IntegratedInstruction(IRMap.EndOfIIStream, OpCodes.RET0, -1, 0, 0, 0); //basically a flag instruction
             IntegratedInstruction end = new IntegratedInstruction(IRMap.EndOfIIStream, new BytecodeInstruction(OpCodes.RET0, -2)); //basically a flag instruction
             curII = end;
         }
         else
         {
             curBlock = blocks[curBlock.GetNameIndex() + 1];
             bIndex   = 0;
             curII    = curBlock.iis[bIndex];
         }
     }
     if (curII != null && curII.iROp == IRMap.EndOfIIStream)
     {
         return;
     }
     curII = curBlock.iis[bIndex];
     regs  = curII.bci.regs;
 }
예제 #2
0
 /// <summary>
 /// Writes a notification to the decompiled output that an opcode is currently unimplmented.
 /// </summary>
 public void UnimplementedOpcode(IntegratedInstruction ii)
 {
     decompLines.Add("--Opcode not impemented: " + ii.originalOp);
 }
예제 #3
0
 //Checks if a conditional integrated instruction is the start of a loop or an if statement.
 public bool IIStartsLoop(IntegratedInstruction ii)
 {
     //look at the next block, see if it points back to us.
     return(false);
 }