public void handler() {
            /*UINT16*/
            int t1, t2;
            /*UINT8*/
            int tb;
            tb = IMMBYTE();
            //GETREG( t1, tb >> 4 );
            switch (tb >> 4) {
                case 0:
                    t1 = A();
                    break;
                case 1:
                    t1 = B();
                    break;
                case 2:
                    t1 = konami.x;
                    break;
                case 3:
                    t1 = konami.y;
                    break;
                case 4:
                    t1 = konami.s;
                    break; /* ? */

                case 5:
                    t1 = konami.u;
                    break;
                default:
                    t1 = 0xff;
                    if (errorlog != null) {
                        fprintf(errorlog, "Unknown TFR/EXG idx at PC:%04x\n", konami.pc);
                    }
                    break;
            }
            //GETREG( t2, tb & 0x0f );
            switch (tb & 0x0f) {
                case 0:
                    t2 = A();
                    break;
                case 1:
                    t2 = B();
                    break;
                case 2:
                    t2 = konami.x;
                    break;
                case 3:
                    t2 = konami.y;
                    break;
                case 4:
                    t2 = konami.s;
                    break; /* ? */

                case 5:
                    t2 = konami.u;
                    break;
                default:
                    t2 = 0xff;
                    if (errorlog != null) {
                        fprintf(errorlog, "Unknown TFR/EXG idx at PC:%04x\n", konami.pc);
                    }
                    break;
            }
            //SETREG( t2, tb >> 4 );
            switch (tb >> 4) {
                case 0:
                    A(t2);
                    break;
                case 1:
                    B(t2);
                    break;
                case 2:
                    konami.x = t2;
                    break;
                case 3:
                    konami.y = t2;
                    break;
                case 4:
                    konami.s = t2;
                    break; /* ? */

                case 5:
                    konami.u = t2;
                    break;
                default:
                    if (errorlog != null) {
                        fprintf(errorlog, "Unknown TFR/EXG idx at PC:%04x\n", konami.pc);
                    }
                    break;
            }
            //SETREG( t1, tb & 0x0f );
            switch (tb & 0x0f) {
                case 0:
                    A(t1);
                    break;
                case 1:
                    B(t1);
                    break;
                case 2:
                    konami.x = t1;
                    break;
                case 3:
                    konami.y = t1;
                    break;
                case 4:
                    konami.s = t1;
                    break; /* ? */

                case 5:
                    konami.u = t1;
                    break;
                default:
                    if (errorlog != null) {
                        fprintf(errorlog, "Unknown TFR/EXG idx at PC:%04x\n", konami.pc);
                    }
                    break;
            }
            if (konamilog != null) {
                fprintf(konamilog, "konami#%d exg :PC:%d,PPC:%d,A:%d,B:%d,D:%d,DP:%d,U:%d,S:%d,X:%d,Y:%d,CC:%d,EA:%d\n", cpu_getactivecpu(), konami.pc, konami.ppc, A(), B(), konami.d, konami.dp, konami.u, konami.s, konami.x, konami.y, konami.cc, ea);
            }

        }