public void TinyGenerator(){
	            register_type r0 = new register_type(0);
	            register_type r1 = new register_type(1);
	            register_type r2 = new register_type(2);
	            register_type r3 = new register_type(3);
	            Allregisters.put(0,r0);
	            Allregisters.put(1,r1);
	            Allregisters.put(2,r2);
	            Allregisters.put(3,r3);

	            //once a register is used, next put will be current_use+4,and then current_use ++; 

	            Scope thescope = SymbolTable.get("GLOBAL");
	            for (Iterator ele =  (thescope.elements).keySet().iterator();ele.hasNext();){
	                  Object down_key= ele.next();
	                  if((thescope.elements).get(down_key).E_type.equals("STRING")){
	                        System.out.println("str "+(thescope.elements).get(down_key).E_name+" "+(thescope.elements).get(down_key).E_value);
	                  }else{
	                        System.out.println("var "+(thescope.elements).get(down_key).E_name);
	                  }
	            }
	            System.out.println("push"); 
	            System.out.println("push "+CString("r",0));
	            System.out.println("push "+CString("r",1));
	            System.out.println("push "+CString("r",2));
	            System.out.println("push "+CString("r",3));
	            System.out.println("jsr main");
	            System.out.println("sys halt"); 
	            int i,ra,rb,rc;
	            Operation temp_op;
	            for(Iterator func = Functiontable.keySet().iterator();func.hasNext();){
	                  Object hello = func.next();
	                  Function newfunc = Functiontable.get(hello);
	                  current_function_reg = newfunc;
	                  for (i=0;i<newfunc.IRcount;i++){
	                        current_IR  = i;
	                       // System.out.println();
	                        temp_op= newfunc.IRs.get(i);
	                      //  System.out.println(";"+i+" "+newfunc.IRs.get(i).operation+" "+newfunc.IRs.get(i).op1+" "+newfunc.IRs.get(i).op2+" "+newfunc.IRs.get(i).op3);
	                        if((temp_op.operation).equals("STOREF")|(temp_op.operation).equals("STOREI")){
	                              ra = 0;
	                              int flag = 1;
	                              int flagstar = 1;
	                              try{
	                                    int a = Integer.parseInt(temp_op.op1);
	                              }catch(NumberFormatException e){
	                                    try{
	                                          float  b= Float.parseFloat(temp_op.op1);   
	                                    }catch(NumberFormatException x){
	                                          if(temp_op.op1.charAt(0)=='$'){
	                                                flagstar = 0;
	                                          }
	                                          else{
	                                                ra = Ensure(temp_op.op1);
	                                                flag = 0;
	                                          }
	                                    }
	                              }
	                              if(temp_op.op2.charAt(0)=='$'){
	                                    if(flag==0|flagstar==0){
	                                          rb = Ensure(temp_op.op1);
	                                          System.out.println("move "+CString("r",rb)+" "+temp_op.op2);
	                                    }
	                                    else 
	                                          System.out.println("move "+temp_op.op1+" "+temp_op.op2);
	                              }else{

	                                    rc = allocate(temp_op.op2);
	                                    if(flag==0)
	                                          System.out.println("move "+CString("r",ra)+" "+CString("r",rc));
	                                    else
	                                          System.out.println("move "+temp_op.op1+" "+CString("r",rc));
	                                    Allregisters.get(rc).status = "Dirty";
	                                    Usecount(rc);
	                              }
	                              if((SymbolTable.get("GLOBAL").elements).get(temp_op.op2)!=null){
	                                    int h;
	                                    for(h=0;h<4;h++){
	                                          register_type r = Allregisters.get(h);
	                                          if(r.status.equals("Dirty")){
	                                                GenStore(h,r.variable);
	                                          }
	                                          r.recentuse=h;
	                                          r.variable ="";
	                                          r.status ="Free";
	                                    }
	                              }
	                              // if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                              //       free(ra);
	                              // } 
	                              // System.out.println("move "+CString("r",ra)+" "+CString("r",rc));     
	                              // System.out.println("move "+temp_op.op1+" "+temp_op.op2);
	                        }else if((temp_op.operation).equals("ADDI")){
	                              ra = Ensure(temp_op.op1);
	                              rb = Ensure(temp_op.op2);
	                              if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                                    free(ra);
	                              }
	                              if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op2)){
	                                    free(rb);
	                              }
	                              rc = allocate(temp_op.op3);
	                              if(rc==ra){
	                                    System.out.println("addi "+CString("r",rb)+" "+CString("r",rc)); 
	                              }else if(rc==rb){
	                                    System.out.println("addi "+CString("r",ra)+" "+CString("r",rc)); 
	                              }else{
	                                    System.out.println("move "+CString("r",ra)+" "+CString("r",rc));
	                                    System.out.println("addi "+CString("r",rb)+" "+CString("r",rc));
	                              }
	                              Usecount(rc);
	                              Allregisters.get(rc).status = "Dirty";
	                             // System.out.println("move "+temp_op.op1+" "+temp_op.op3);
	                             // System.out.println("addi "+temp_op.op2+" "+temp_op.op3);
	                        }else if((temp_op.operation).equals("ADDF")){
	                              ra = Ensure(temp_op.op1);
	                              rb = Ensure(temp_op.op2);
	                              if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                                    free(ra);
	                              }
	                              if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op2)){
	                                    free(rb);
	                              }
	                              rc = allocate(temp_op.op3);
	                              if(rc==ra){
	                                    System.out.println("addr "+CString("r",rb)+" "+CString("r",rc)); 
	                              }else if(rc==rb){
	                                    System.out.println("addr "+CString("r",ra)+" "+CString("r",rc)); 
	                              }else{
	                                    System.out.println("move "+CString("r",ra)+" "+CString("r",rc));
	                                    System.out.println("addr "+CString("r",rb)+" "+CString("r",rc));
	                              }
	                              Usecount(rc);
	                              Allregisters.get(rc).status = "Dirty";
	                              //System.out.println("move "+temp_op.op1+" "+temp_op.op3);
	                              //System.out.println("addr "+temp_op.op2+" "+temp_op.op3);
	                        }else if((temp_op.operation).equals("SUBI")){
	                              ra = Ensure(temp_op.op1);
	                              rb = Ensure(temp_op.op2);
	                             
	                              rc = allocate(temp_op.op3);
	                              if(rc==ra){
	                                    System.out.println("subi "+CString("r",rb)+" "+CString("r",rc)); 
	                              }else if(rc==rb){
	                                    System.out.println("subi "+CString("r",ra)+" "+CString("r",rc)); 
	                              }else{
	                                    System.out.println("move "+CString("r",ra)+" "+CString("r",rc));
	                                    System.out.println("subi "+CString("r",rb)+" "+CString("r",rc));
	                              }
	                              Usecount(rc);
	                              Allregisters.get(rc).status = "Dirty";
	                              if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                                    free(ra);
	                              }
	                              if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op2)){
	                                   free(rb);
	                              }
	                              //System.out.println("move "+temp_op.op1+" "+temp_op.op3);
	                              //System.out.println("subi "+temp_op.op2+" "+temp_op.op3);
	                        }else if((temp_op.operation).equals("SUBF")){
	                              ra = Ensure(temp_op.op1);
	                              rb = Ensure(temp_op.op2);
	                             // if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                             //       free(ra);
	                             // }
	                             // if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op2)){
	                             //       free(rb);
	                             // }
	                              rc = allocate(temp_op.op3);
	                              if(rc==ra){
	                                    System.out.println("subr "+CString("r",rb)+" "+CString("r",rc)); 
	                              }else if(rc==rb){
	                                    System.out.println("move "+CString("r",ra)+" "+CString("r",rc));
	                                    System.out.println("subr "+CString("r",ra)+" "+CString("r",rc)); 
	                              }else{
	                                    System.out.println("move "+CString("r",ra)+" "+CString("r",rc));
	                                    System.out.println("subr "+CString("r",rb)+" "+CString("r",rc));
	                              }
	                              Usecount(rc);
	                              Allregisters.get(rc).status = "Dirty";
	                              if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                                    free(ra);
	                              }
	                              if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op2)){
	                                   free(rb);
	                              }
	                              //System.out.println("move "+temp_op.op1+" "+temp_op.op3);
	                              //System.out.println("subr "+temp_op.op2+" "+temp_op.op3);
	                        }else if((temp_op.operation).equals("MULTI")){
	                              ra = Ensure(temp_op.op1);
	                              rb = Ensure(temp_op.op2);
	                              if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                                   free(ra);
	                              }
	                              if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op2)){
	                                    free(rb);
	                              }
	                              rc = allocate(temp_op.op3);
	                              //System.out.println(ra+" "+rb+" "+rc);
	                              if(rc==ra){
	                                    System.out.println("muli "+CString("r",rb)+" "+CString("r",rc)); 
	                              }else if(rc==rb){
	                                    System.out.println("muli "+CString("r",ra)+" "+CString("r",rc)); 
	                              }else{
	                                    System.out.println("move "+CString("r",ra)+" "+CString("r",rc));
	                                    System.out.println("muli "+CString("r",rb)+" "+CString("r",rc));
	                              }
	                              Usecount(rc);
	                              Allregisters.get(rc).status = "Dirty";
	                              //System.out.println("move "+temp_op.op1+" "+temp_op.op3);
	                              //System.out.println("muli "+temp_op.op2+" "+temp_op.op3);
	                        }else if((temp_op.operation).equals("MULTF")){
	                              ra = Ensure(temp_op.op1);
	                              rb = Ensure(temp_op.op2);
	                              if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                                    free(ra);
	                              }
	                              if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op2)){
	                                    free(rb);
	                              }
	                              rc = allocate(temp_op.op3);
	                              if(rc==ra){
	                                    System.out.println("mulr "+CString("r",rb)+" "+CString("r",rc)); 
	                              }else if(rc==rb){
	                                    System.out.println("mulr "+CString("r",ra)+" "+CString("r",rc)); 
	                              }else{
	                                    System.out.println("move "+CString("r",ra)+" "+CString("r",rc));
	                                    System.out.println("mulr "+CString("r",rb)+" "+CString("r",rc));
	                              }
	                              Usecount(rc);
	                              Allregisters.get(rc).status = "Dirty";
	                              // System.out.println("move "+temp_op.op1+" "+temp_op.op3);
	                              // System.out.println("mulr "+temp_op.op2+" "+temp_op.op3);
	                        }else if((temp_op.operation).equals("DIVI")){
	                              ra = Ensure(temp_op.op1);
	                              
	                              rb = Ensure(temp_op.op2);
	                              
	                              //if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                              //      free(ra);
	                              //}
	                              //if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op2)){
	                              //      free(rb);
	                              //}
	                              rc = allocate(temp_op.op3);
	                              if(rc==ra){
	                                    System.out.println("divi "+CString("r",rb)+" "+CString("r",rc)); 
	                              }else if(rc==rb){

	                                    System.out.println("divi "+CString("r",ra)+" "+CString("r",rc)); 
	                              }else{
	                                    System.out.println("move "+CString("r",ra)+" "+CString("r",rc));
	                                    System.out.println("divi "+CString("r",rb)+" "+CString("r",rc));
	                              }
	                              Usecount(rc);
	                              
	                              Allregisters.get(rc).status = "Dirty";
	                              //System.out.println("move "+temp_op.op1+" "+temp_op.op3);
	                              //System.out.println("divi "+temp_op.op2+" "+temp_op.op3);
	                        }else if((temp_op.operation).equals("DIVF")){
	                              ra = Ensure(temp_op.op1);
	                              rb = Ensure(temp_op.op2);
	                              //if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                              //      free(ra);
	                              //}
	                              //if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op2)){
	                              //      free(rb);
	                              //}
	                              rc = allocate(temp_op.op3);
	                              if(rc==ra){
	                                    System.out.println("divr "+CString("r",rb)+" "+CString("r",rc)); 
	                              }else if(rc==rb){
	                                    System.out.println("divr "+CString("r",ra)+" "+CString("r",rc)); 
	                              }else{
	                                    System.out.println("move "+CString("r",ra)+" "+CString("r",rc));
	                                    System.out.println("divr "+CString("r",rb)+" "+CString("r",rc));
	                              }
	                              Usecount(rc);
	                              Allregisters.get(rc).status = "Dirty";
	                              //System.out.println("move "+temp_op.op1+" "+temp_op.op3);
	                              //System.out.println("divr "+temp_op.op2+" "+temp_op.op3);
	                        }else if((temp_op.operation).equals("WRITEI")){
	                              if((SymbolTable.get("GLOBAL").elements).get(temp_op.op1)!=null)
	                              System.out.println("sys writei "+temp_op.op1);
	                              else {
	                                    ra = Ensure(temp_op.op1);
	                                    System.out.println("sys writei "+CString("r",ra)); 
	                              }
	                              //System.out.println("sys writei "+temp_op.op1);
	                        }else if((temp_op.operation).equals("WRITEF")){
	                              if((SymbolTable.get("GLOBAL").elements).get(temp_op.op1)!=null)
	                              System.out.println("sys writer "+temp_op.op1);
	                              else {
	                                    ra = Ensure(temp_op.op1);
	                                    System.out.println("sys writer "+CString("r",ra));
	                              }
	                              //System.out.println("sys writer "+temp_op.op1);
	                        }else if((temp_op.operation).equals("WRITES")){
	                              if((SymbolTable.get("GLOBAL").elements).get(temp_op.op1)!=null)
	                              System.out.println("sys writes "+temp_op.op1);
	                              else {
	                                    ra = Ensure(temp_op.op1);
	                                    System.out.println("sys writes "+CString("r",ra));
	                              }
	                              //System.out.println("sys writes "+temp_op.op1);
	                        }else if((temp_op.operation).equals("READI")){
	                              ra = Ensure(temp_op.op1);
	                              System.out.println("sys readi "+CString("r",ra));
	                              Allregisters.get(ra).status = "Dirty";
	                              int h;
	                              for(h=0;h<4;h++){
	                                    register_type r = Allregisters.get(h);
	                                    if(r.status.equals("Dirty")){
	                                          GenStore(h,r.variable);
	                                    }
	                                    r.recentuse=h;
	                                    r.variable ="";
	                                    r.status ="Free";
	                              }
	                             // System.out.println("sys readi "+temp_op.op1);
	                        }else if((temp_op.operation).equals("READF")){
	                              ra = Ensure(temp_op.op1);
	                              System.out.println("sys readr "+CString("r",ra));
	                              Allregisters.get(ra).status = "Dirty";
	                              int h;
	                              for(h=0;h<4;h++){
	                                    register_type r = Allregisters.get(h);
	                                    if(r.status.equals("Dirty")){
	                                          GenStore(h,r.variable);
	                                    }
	                                    r.recentuse=h;
	                                    r.variable ="";
	                                    r.status ="Free";
	                              }
	                              //System.out.println("sys readr "+temp_op.op1);
	                        }else if((temp_op.operation).equals("NE")){
	                              //System.out.println("case 1");
	                              ra = Ensure(temp_op.op1);
	                            //  if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                            //        free(ra);
	                            //  }
	                              rc = Ensure(temp_op.op2);
	                              if(Findelementbyname(temp_op.op1)!=null){
	                                    if(Findelementbyname(temp_op.op1).E_type.equals("FLOAT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }else if(Findelementbyname(temp_op.op1).E_type.equals("INT")){
	                                          System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                    }
	                              }else if(Findelementbyname(temp_op.op2)!=null){
	                                    if(Findelementbyname(temp_op.op2).E_type.equals("FLOAT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }else if(Findelementbyname(temp_op.op2).E_type.equals("INT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }
	                              }else{
	                                    String newty = temp_op.op1.split("T")[1];
	                                    String ty = TypeTable.get(Integer.parseInt(newty));
	                                  //  System.out.println("ty is "+ty+" "+newty +" wrong");
	                                    if(ty!=null){
	                                          if(ty.equals("FLOAT")){
	                                                System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                               // System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                          }else if(ty.equals("INT")){
	                                                System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                               // System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                          }
	                                    }
	                              }
	                              System.out.println("jne "+"label"+temp_op.op3);
	                             // Allregisters.get(rc).status = "Dirty";
	                        }else if((temp_op.operation).equals("GE")){
	                            ////System.out.println("case 2");
	                              ra = Ensure(temp_op.op1);
	                            //  if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                            //        free(ra);
	                            //  }
	                              rc = Ensure(temp_op.op2);
	                              if(Findelementbyname(temp_op.op1)!=null){
	                                    if(Findelementbyname(temp_op.op1).E_type.equals("FLOAT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                         // System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }else if(Findelementbyname(temp_op.op1).E_type.equals("INT")){
	                                          System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                         // System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                    }
	                              }else if(Findelementbyname(temp_op.op2)!=null){
	                                    if(Findelementbyname(temp_op.op2).E_type.equals("FLOAT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                         // System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }else if(Findelementbyname(temp_op.op2).E_type.equals("INT")){
	                                          System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                         // System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                    }
	                              }else{
	                                    String newty = temp_op.op1.split("T")[1];
	                                    String ty = TypeTable.get(Integer.parseInt(newty));
	                                    //System.out.println("ty is "+ty);
	                                    if(ty!=null){
	                                          if(ty.equals("FLOAT")){
	                                                System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                               // System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                          }else if(ty.equals("INT")){
	                                                System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                               // System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                          }
	                                    }
	                              }
	                            //  Allregisters.get(rc).status = "Dirty";
	                              System.out.println("jge "+"label"+temp_op.op3);
	                        }else if((temp_op.operation).equals("GT")){
	                              //System.out.println("case 3");
	                              ra = Ensure(temp_op.op1);
	                           //   if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                           //         free(ra);
	                           //   }
	                              rc = Ensure(temp_op.op2);
	                              if(Findelementbyname(temp_op.op1)!=null){
	                                    if(Findelementbyname(temp_op.op1).E_type.equals("FLOAT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }else if(Findelementbyname(temp_op.op1).E_type.equals("INT")){
	                                          System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                    }
	                              }else if(Findelementbyname(temp_op.op2)!=null){
	                                    if(Findelementbyname(temp_op.op2).E_type.equals("FLOAT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }else if(Findelementbyname(temp_op.op2).E_type.equals("INT")){
	                                          System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                    }
	                              }else{
	                                    String newty = temp_op.op1.split("T")[1];
	                                    String ty = TypeTable.get(Integer.parseInt(newty));
	                                    //System.out.println("ty is "+ty);
	                                    if(ty!=null){
	                                          if(ty.equals("FLOAT")){
	                                                System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                              //  System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                          }else if(ty.equals("INT")){
	                                                System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                               // System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                          }
	                                    }
	                              }
	                             // Allregisters.get(rc).status = "Dirty";
	                              System.out.println("jgt "+"label"+temp_op.op3);
	                        }else if((temp_op.operation).equals("LT")){
	                              //System.out.println("case 4");
	                              ra = Ensure(temp_op.op1);
	                          //    if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                          //          free(ra);
	                          //    }
	                              rc = Ensure(temp_op.op2);
	                              if(Findelementbyname(temp_op.op1)!=null){
	                                    if(Findelementbyname(temp_op.op1).E_type.equals("FLOAT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }else if(Findelementbyname(temp_op.op1).E_type.equals("INT")){
	                                          System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                    }
	                              }else if(Findelementbyname(temp_op.op2)!=null){
	                                    if(Findelementbyname(temp_op.op2).E_type.equals("FLOAT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }else if(Findelementbyname(temp_op.op2).E_type.equals("INT")){
	                                          System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                    }
	                              }else{
	                                    String newty = temp_op.op1.split("T")[1];
	                                    String ty = TypeTable.get(Integer.parseInt(newty));
	                                    //System.out.println("ty is "+ty);
	                                    if(ty!=null){
	                                          if(ty.equals("FLOAT")){
	                                                System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                                //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                          }else if(ty.equals("INT")){   
	                                                System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                               // System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                          }
	                                    }
	                              }
	                             // Allregisters.get(rc).status = "Dirty";
	                              System.out.println("jlt "+"label"+temp_op.op3);
	                        }else if((temp_op.operation).equals("LE")){
	                              //System.out.println("case 5");
	                              ra = Ensure(temp_op.op1);
	                          //    if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                          //          free(ra);
	                          //    }
	                              rc = Ensure(temp_op.op2);
	                              if(Findelementbyname(temp_op.op1)!=null){
	                                    if(Findelementbyname(temp_op.op1).E_type.equals("FLOAT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }else if(Findelementbyname(temp_op.op1).E_type.equals("INT")){
	                                          System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                    }
	                              }else if(Findelementbyname(temp_op.op2)!=null){
	                                    if(Findelementbyname(temp_op.op2).E_type.equals("FLOAT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }else if(Findelementbyname(temp_op.op2).E_type.equals("INT")){
	                                          System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                    }
	                              }else{
	                                    String newty = temp_op.op1.split("T")[1];
	                                    String ty = TypeTable.get(Integer.parseInt(newty));
	                                    //System.out.println("ty is "+ty);
	                                    if(ty!=null){
	                                          if(ty.equals("FLOAT")){
	                                                System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                                //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                          }else if(ty.equals("INT")){
	                                                System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                                //System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                          }
	                                    }
	                              }
	                              //Allregisters.get(rc).status = "Dirty";
	                              System.out.println("jle "+"label"+temp_op.op3);
	                        }else if((temp_op.operation).equals("EQ")){
	                              //System.out.println("case 6");
	                              ra = Ensure(temp_op.op1);
	                          //    if(!newfunc.Cfgs.Out.get(i).contents.containsValue(temp_op.op1)){
	                          //          free(ra);
	                          //    }
	                              rc = Ensure(temp_op.op2);
	                              if(Findelementbyname(temp_op.op1)!=null){
	                                    if(Findelementbyname(temp_op.op1).E_type.equals("FLOAT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }else if(Findelementbyname(temp_op.op1).E_type.equals("INT")){
	                                          System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                    }
	                              }else if(Findelementbyname(temp_op.op2)!=null){
	                                    if(Findelementbyname(temp_op.op2).E_type.equals("FLOAT")){
	                                          System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                    }else if(Findelementbyname(temp_op.op2).E_type.equals("INT")){
	                                          System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                          //System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                    }
	                              }else{
	                                    String newty = temp_op.op1.split("T")[1];
	                                    String ty = TypeTable.get(Integer.parseInt(newty));
	                                   // System.out.println("ty is "+ty);
	                                    if(ty!=null){
	                                          if(ty.equals("FLOAT")){
	                                                System.out.println("cmpr "+CString("r",ra)+" "+CString("r",rc));
	                                               // System.out.println("cmpr "+temp_op.op1+" "+temp_op.op2);
	                                          }else if(ty.equals("INT")){
	                                                System.out.println("cmpi "+CString("r",ra)+" "+CString("r",rc));
	                                               // System.out.println("cmpi "+temp_op.op1+" "+temp_op.op2);
	                                          }
	                                    }
	                              }
	                              //Allregisters.get(rc).status = "Dirty";
	                              System.out.println("jeq "+"label"+temp_op.op3);
	                        }else if((temp_op.operation).equals("LABEL")){
	                              //System.out.println("");
	                              int h;
	                              for(h=0;h<4;h++){
	                                    register_type r = Allregisters.get(h);
	                                    if(r.status.equals("Dirty")){
	                                          GenStore(h,r.variable);
	                                    }
	                                    r.recentuse=h;
	                                    r.variable ="";
	                                    r.status ="Free";
	                              }
	                              System.out.println("label "+temp_op.op1);
	                        }else if((temp_op.operation).equals("JUMP")){
	                              //System.out.println("case 8");
	                              int h;
	                              for(h=0;h<4;h++){
	                                    register_type r = Allregisters.get(h);
	                                    if(r.status.equals("Dirty")){
	                                          GenStore(h,r.variable);
	                                    }
	                                    r.recentuse=h;
	                                    r.status ="Free";
	                              }
	                              System.out.println("jmp "+temp_op.op1);
	                        }else if((temp_op.operation).equals("POP")){
	                              if(temp_op.op1.equals("")){
	                                    System.out.println("pop ");
	                              }else{
	                                    ra = Ensure(temp_op.op1);
	                                    System.out.println("pop "+CString("r",ra));
	                              
	                                    // System.out.println("here");
	                                    Allregisters.get(ra).status = "Dirty";
	                                    
	                              }
	                        }else if((temp_op.operation).equals("PUSH")){
	                              if(temp_op.op1.equals("")){
	                                    System.out.println("push ");
	                              }else{
	                                    ra = Ensure(temp_op.op1);
	                                    System.out.println("push "+CString("r",ra));
	                                    
	                              }
	                        }else if((temp_op.operation).equals("JSR")){
	                              int h;
	                              for(h=0;h<4;h++){
	                                    register_type r = Allregisters.get(h);
	                                    if(r.status.equals("Dirty")){
	                                          GenStore(h,r.variable);
	                                    }
	                                    r.recentuse=h;
	                                    r.variable ="";
	                                    r.status ="Free";
	                              }
	                              System.out.println("push r3");
	                              System.out.println("push r2");
	                              System.out.println("push r1");
	                              System.out.println("push r0");
	                              System.out.println("jsr "+temp_op.op1); 
	                              System.out.println("pop r0"); 
	                              System.out.println("pop r1"); 
	                              System.out.println("pop r2"); 
	                              System.out.println("pop r3"); 
	                        }else if((temp_op.operation).equals("RET")){
	                              int h;
	                              for(h=0;h<4;h++){
	                                    register_type r = Allregisters.get(h);
	                                    if(r.status.equals("Dirty")){
	                                          GenStore(h,r.variable);
	                                    }
	                                    r.recentuse=h;
	                                    r.variable ="";
	                                    r.status ="Free";
	                              }
	                              System.out.println("unlnk");
	                              System.out.println("ret");  
	                        }else if((temp_op.operation).equals("LINK")){
	                              System.out.println("link "+temp_op.op1);
	                        }else{
	                              System.out.println(";combined");
	                        }
	                        //PrintRegs();
	                  } 
	            }      
	            System.out.println("end");
	      }