Rev 81 | Rev 154 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 81 | Rev 108 | ||
---|---|---|---|
Line 42... | Line 42... | ||
42 | /* EPD glue command type */ |
42 | /* EPD glue command type */ |
43 | typedef siT egcommT, *egcommptrT; |
43 | typedef siT egcommT, *egcommptrT; |
44 | 44 | ||
45 | # define egcommL 26 |
45 | # define egcommL 26 |
46 | # define egcomm_nil (-1) |
46 | # define egcomm_nil (-1) |
47 | # define egcomm_epdapgn 0 |
47 | # define egcomm_epdapgn 0 /* append a PGN game to a file */ |
48 | # define egcomm_epdbfix 1 |
48 | # define egcomm_epdbfix 1 /* fix file for Bookup import */ |
49 | # define egcomm_epdcert 2 |
49 | # define egcomm_epdcert 2 /* display certain evaluation (if possible) */ |
50 | # define egcomm_epdcics 3 |
50 | # define egcomm_epdcics 3 /* slave to an Internet Chess Server */ |
51 | # define egcomm_epdcomm 4 |
51 | # define egcomm_epdcomm 4 /* slave to the Duplex referee program */ |
52 | # define egcomm_epddpgn 5 |
52 | # define egcomm_epddpgn 5 /* display the current game in PGN */ |
53 | # define egcomm_epddsml 6 |
53 | # define egcomm_epddsml 6 /* display SAN move list */ |
54 | # define egcomm_epddstr 7 |
54 | # define egcomm_epddstr 7 /* display PGN Seven Tag Roster */ |
55 | # define egcomm_epddtpv 8 |
55 | # define egcomm_epddtpv 8 /* display PGN tag pair value */ |
56 | # define egcomm_epdenum 9 |
56 | # define egcomm_epdenum 9 /* enumerate EPD file */ |
57 | # define egcomm_epdhelp 10 |
57 | # define egcomm_epdhelp 10 /* display EPD help */ |
58 | # define egcomm_epdlink 11 |
58 | # define egcomm_epdlink 11 /* slave to the Argus referee program */ |
59 | # define egcomm_epdlpgn 12 |
59 | # define egcomm_epdlpgn 12 /* load a PGN game from a file */ |
60 | # define egcomm_epdlrec 13 |
60 | # define egcomm_epdlrec 13 /* load an EPD record form a file */ |
61 | # define egcomm_epdmore 14 |
61 | # define egcomm_epdmore 14 /* more help */ |
62 | # define egcomm_epdnoop 15 |
62 | # define egcomm_epdnoop 15 /* no operation */ |
63 | # define egcomm_epdpfdn 16 |
63 | # define egcomm_epdpfdn 16 /* process file: data normalization */ |
64 | # define egcomm_epdpfdr 17 |
64 | # define egcomm_epdpfdr 17 /* process file: data repair */ |
65 | # define egcomm_epdpfga 18 |
65 | # define egcomm_epdpfga 18 /* process file: general analysis */ |
66 | # define egcomm_epdpflc 19 |
66 | # define egcomm_epdpflc 19 /* process file: locate cooks */ |
67 | # define egcomm_epdpfop 20 |
67 | # define egcomm_epdpfop 20 /* process file: operation purge */ |
68 | # define egcomm_epdscor 21 |
68 | # define egcomm_epdscor 21 /* score EPD benchmark result file */ |
69 | # define egcomm_epdshow 22 |
69 | # define egcomm_epdshow 22 /* show EPD four fields for current position */ |
70 | # define egcomm_epdspgn 23 |
70 | # define egcomm_epdspgn 23 /* save a PGN game to a file */ |
71 | # define egcomm_epdstpv 24 |
71 | # define egcomm_epdstpv 24 /* set PGN tag pair value */ |
72 | # define egcomm_epdtest 25 |
72 | # define egcomm_epdtest 25 /* developer testing */ |
73 | /* output text buffer */ |
73 | /* output text buffer */ |
74 | # define tbufL 256 |
74 | # define tbufL 256 |
75 | static char tbufv[tbufL]; |
75 | static char tbufv[tbufL]; |
76 | 76 | ||
77 | /* EPD glue command strings */ |
77 | /* EPD glue command strings */ |
Line 510... | Line 510... | ||
510 | tree->status[0].reversible = (uint8_t) hmvc; // Pierre-Marie Baty -- added type cast |
510 | tree->status[0].reversible = (uint8_t) hmvc; // Pierre-Marie Baty -- added type cast |
511 | /* copy the fullmove number */ |
511 | /* copy the fullmove number */ |
512 | move_number = fmvn; |
512 | move_number = fmvn; |
513 | /* set secondary host data items */ |
513 | /* set secondary host data items */ |
514 | SetChessBitBoards(tree); |
514 | SetChessBitBoards(tree); |
515 |
|
515 | rep_index = 0; |
516 | tree->rep_list[0] = HashKey; |
516 | tree->rep_list[0] = HashKey; |
517 | moves_out_of_book = 0; |
517 | moves_out_of_book = 0; |
518 | last_mate_score = 0; |
518 | last_mate_score = 0; |
519 | /* clear the host killer information */ |
519 | /* clear the host killer information */ |
520 | for (index = 0; index < MAXPLY; index++) { |
520 | for (index = 0; index < MAXPLY; index++) { |
Line 654... | Line 654... | ||
654 | s = EPDPGNHistory(default_gamptr); |
654 | s = EPDPGNHistory(default_gamptr); |
655 | if (s == NULL) |
655 | if (s == NULL) |
656 | *flagptr = 0; |
656 | *flagptr = 0; |
657 | else { |
657 | else { |
658 | /* append game to PGN output file */ |
658 | /* append game to PGN output file */ |
659 | sprintf(tv, "c%05hd.pgn", ((siT) _getpid())); // Pierre-Marie Baty -- |
659 | sprintf(tv, "c%05hd.pgn", ((siT) _getpid())); // Pierre-Marie Baty -- ISO C++ name fix |
660 | fptr = fopen(tv, "a"); |
660 | fptr = fopen(tv, "a"); |
661 | if (fptr == NULL) |
661 | if (fptr == NULL) |
662 | *flagptr = 0; |
662 | *flagptr = 0; |
663 | else { |
663 | else { |
664 | fprintf(fptr, "%s", s); |
664 | fprintf(fptr, "%s", s); |
Line 669... | Line 669... | ||
669 | /* clean up and remove the temporary history file */ |
669 | /* clean up and remove the temporary history file */ |
670 | if (history_file != NULL) { |
670 | if (history_file != NULL) { |
671 | fclose(history_file); |
671 | fclose(history_file); |
672 | history_file = NULL; |
672 | history_file = NULL; |
673 | }; |
673 | }; |
674 | sprintf(tv, "h%05hd.pml", ((siT) _getpid())); // Pierre-Marie Baty -- |
674 | sprintf(tv, "h%05hd.pml", ((siT) _getpid())); // Pierre-Marie Baty -- ISO C++ name fix |
675 | remove(tv); |
675 | remove(tv); |
676 | /* close the game structure */ |
676 | /* close the game structure */ |
677 | if (default_gamptr != NULL) { |
677 | if (default_gamptr != NULL) { |
678 | EPDGameClose(default_gamptr); |
678 | EPDGameClose(default_gamptr); |
679 | default_gamptr = NULL; |
679 | default_gamptr = NULL; |
Line 684... | Line 684... | ||
684 | /* clean up and remove the temporary history file */ |
684 | /* clean up and remove the temporary history file */ |
685 | if (history_file != NULL) { |
685 | if (history_file != NULL) { |
686 | fclose(history_file); |
686 | fclose(history_file); |
687 | history_file = NULL; |
687 | history_file = NULL; |
688 | }; |
688 | }; |
689 | sprintf(tv, "h%05hd.pml", ((siT) _getpid())); // Pierre-Marie Baty -- |
689 | sprintf(tv, "h%05hd.pml", ((siT) _getpid())); // Pierre-Marie Baty -- ISO C++ name fix |
690 | remove(tv); |
690 | remove(tv); |
691 | /* ensure game structure is closed */ |
691 | /* ensure game structure is closed */ |
692 | if (default_gamptr != NULL) { |
692 | if (default_gamptr != NULL) { |
693 | EPDGameClose(default_gamptr); |
693 | EPDGameClose(default_gamptr); |
694 | default_gamptr = NULL; |
694 | default_gamptr = NULL; |
695 | }; |
695 | }; |
696 | break; |
696 | break; |
697 | case refcom_execute: |
697 | case refcom_execute: |
698 | /* execute the supplied move */ |
698 | /* execute the supplied move */ |
699 | eopptr = EPDLocateEOPCode(epdptr0, epdso_sm); |
699 | eopptr = EPDLocateEOPCode(epdptr0, epdso_sm); |
700 | move = InputMove(tree, |
700 | move = InputMove(tree, 0, game_wtm, 0, 0, eopptr->eop_headeov->eov_str); |
701 | if (history_file) { |
701 | if (history_file) { |
702 | fseek(history_file, ((((move_number - 1) * 2) + 1 - game_wtm) * 10), |
702 | fseek(history_file, ((((move_number - 1) * 2) + 1 - game_wtm) * 10), |
703 | SEEK_SET); |
703 | SEEK_SET); |
704 | fprintf(history_file, "%9s\n", eopptr->eop_headeov->eov_str); |
704 | fprintf(history_file, "%9s\n", eopptr->eop_headeov->eov_str); |
705 | } |
705 | } |
706 | MakeMoveRoot(tree, |
706 | MakeMoveRoot(tree, game_wtm, move); |
707 | game_wtm = Flip(game_wtm); |
707 | game_wtm = Flip(game_wtm); |
708 | if (game_wtm) |
708 | if (game_wtm) |
709 | move_number++; |
709 | move_number++; |
710 | /* execute the move in the EPD Kit */ |
710 | /* execute the move in the EPD Kit */ |
711 | EPDGenMoves(); |
711 | EPDGenMoves(); |
Line 737... | Line 737... | ||
737 | case refcom_respond: |
737 | case refcom_respond: |
738 | /* execute the supplied move (if any) */ |
738 | /* execute the supplied move (if any) */ |
739 | eopptr = EPDLocateEOPCode(epdptr0, epdso_sm); |
739 | eopptr = EPDLocateEOPCode(epdptr0, epdso_sm); |
740 | if (eopptr != NULL) { |
740 | if (eopptr != NULL) { |
741 | move = |
741 | move = |
742 | InputMove(tree, |
742 | InputMove(tree, 0, game_wtm, 0, 0, eopptr->eop_headeov->eov_str); |
743 | if (history_file) { |
743 | if (history_file) { |
744 | fseek(history_file, ((((move_number - 1) * 2) + 1 - game_wtm) * 10), |
744 | fseek(history_file, ((((move_number - 1) * 2) + 1 - game_wtm) * 10), |
745 | SEEK_SET); |
745 | SEEK_SET); |
746 | fprintf(history_file, "%9s\n", eopptr->eop_headeov->eov_str); |
746 | fprintf(history_file, "%9s\n", eopptr->eop_headeov->eov_str); |
747 | } |
747 | } |
748 | MakeMoveRoot(tree, |
748 | MakeMoveRoot(tree, game_wtm, move); |
749 | game_wtm = Flip(game_wtm); |
749 | game_wtm = Flip(game_wtm); |
750 | if (game_wtm) |
750 | if (game_wtm) |
751 | move_number++; |
751 | move_number++; |
752 | /* execute the move in the EPD Kit */ |
752 | /* execute the move in the EPD Kit */ |
753 | EPDGenMoves(); |
753 | EPDGenMoves(); |
Line 765... | Line 765... | ||
765 | thinking = 1; |
765 | thinking = 1; |
766 | last_pv.pathd = 0; |
766 | last_pv.pathd = 0; |
767 | last_pv.pathl = 0; |
767 | last_pv.pathl = 0; |
768 | tree->status[1] = tree->status[0]; |
768 | tree->status[1] = tree->status[0]; |
769 | /* search */ |
769 | /* search */ |
770 |
|
770 | EGIterate((siT) game_wtm, (siT) think); |
771 | /* process search result */ |
771 | /* process search result */ |
772 | strcpy(tv, OutputMove(tree, last_pv.path[1] |
772 | strcpy(tv, OutputMove(tree, 0, game_wtm, last_pv.path[1])); |
773 | move = last_pv.path[1]; |
773 | move = last_pv.path[1]; |
774 | /* locate SAN move */ |
774 | /* locate SAN move */ |
775 | mptr = EPDSANDecodeAux(tv, 0); |
775 | mptr = EPDSANDecodeAux(tv, 0); |
776 | m = *mptr; |
776 | m = *mptr; |
777 | EPDSANEncode(&m, san); |
777 | EPDSANEncode(&m, san); |
Line 780... | Line 780... | ||
780 | fseek(history_file, ((((move_number - 1) * 2) + 1 - game_wtm) * 10), |
780 | fseek(history_file, ((((move_number - 1) * 2) + 1 - game_wtm) * 10), |
781 | SEEK_SET); |
781 | SEEK_SET); |
782 | fprintf(history_file, "%9s\n", san); |
782 | fprintf(history_file, "%9s\n", san); |
783 | } |
783 | } |
784 | /* update host position */ |
784 | /* update host position */ |
785 | MakeMoveRoot(tree, |
785 | MakeMoveRoot(tree, game_wtm, move); |
786 | game_wtm = Flip(game_wtm); |
786 | game_wtm = Flip(game_wtm); |
787 | if (game_wtm) |
787 | if (game_wtm) |
788 | move_number++; |
788 | move_number++; |
789 | /* create reply EPD structure */ |
789 | /* create reply EPD structure */ |
790 | epdptr1 = EPDGetCurrentPosition(); |
790 | epdptr1 = EPDGetCurrentPosition(); |
Line 814... | Line 814... | ||
814 | ponder = 0; |
814 | ponder = 0; |
815 | ponder_move = 0; |
815 | ponder_move = 0; |
816 | last_pv.pathd = 0; |
816 | last_pv.pathd = 0; |
817 | last_pv.pathl = 0; |
817 | last_pv.pathl = 0; |
818 | InitializeChessBoard(tree); |
818 | InitializeChessBoard(tree); |
819 | InitializeHashTables(); |
819 | InitializeHashTables(0); |
820 | game_wtm = 1; |
820 | game_wtm = 1; |
821 | move_number = 1; |
821 | move_number = 1; |
822 | /* open the temporary history file */ |
822 | /* open the temporary history file */ |
823 | if (history_file != NULL) { |
823 | if (history_file != NULL) { |
824 | fclose(history_file); |
824 | fclose(history_file); |
825 | history_file = NULL; |
825 | history_file = NULL; |
826 | }; |
826 | }; |
827 | sprintf(tv, "h%05hd.pml", ((siT) _getpid())); // Pierre-Marie Baty -- |
827 | sprintf(tv, "h%05hd.pml", ((siT) _getpid())); // Pierre-Marie Baty -- ISO C++ name fix |
828 | remove(tv); |
828 | remove(tv); |
829 | history_file = fopen(tv, "w+"); |
829 | history_file = fopen(tv, "w+"); |
830 | /* open the current game structure */ |
830 | /* open the current game structure */ |
831 | if (default_gamptr != NULL) |
831 | if (default_gamptr != NULL) |
832 | EPDGameClose(default_gamptr); |
832 | EPDGameClose(default_gamptr); |
Line 1192... | Line 1192... | ||
1192 | flag = 0; |
1192 | flag = 0; |
1193 | }; |
1193 | }; |
1194 | /* process the epdhelp command */ |
1194 | /* process the epdhelp command */ |
1195 | if (flag) { |
1195 | if (flag) { |
1196 | /* it is not clear exactly why the next statment is needed */ |
1196 | /* it is not clear exactly why the next statment is needed */ |
1197 |
|
1197 | getchar(); |
1198 | /* list all the commands */ |
1198 | /* list all the commands */ |
1199 | egcomm = 0; |
1199 | egcomm = 0; |
1200 | while (egcomm < egcommL) { |
1200 | while (egcomm < egcommL) { |
1201 | EGPL("Available EPD glue command list"); |
1201 | EGPL("Available EPD glue command list"); |
1202 | EGPL("-------------------------------"); |
1202 | EGPL("-------------------------------"); |
Line 1208... | Line 1208... | ||
1208 | egcomm++; |
1208 | egcomm++; |
1209 | }; |
1209 | }; |
1210 | if (egcomm < egcommL) { |
1210 | if (egcomm < egcommL) { |
1211 | EGPL(""); |
1211 | EGPL(""); |
1212 | EGPL("Press <return> for more command help"); |
1212 | EGPL("Press <return> for more command help"); |
1213 |
|
1213 | getchar(); |
1214 | EGPL(""); |
1214 | EGPL(""); |
1215 | }; |
1215 | }; |
1216 | }; |
1216 | }; |
1217 | }; |
1217 | }; |
1218 | return flag; |
1218 | return flag; |
Line 1487... | Line 1487... | ||
1487 | EGPL(""); |
1487 | EGPL(""); |
1488 | EGPL("This command performs no operation. It is provided for"); |
1488 | EGPL("This command performs no operation. It is provided for"); |
1489 | EGPL("development purposes."); |
1489 | EGPL("development purposes."); |
1490 | break; |
1490 | break; |
1491 | case egcomm_epdpfdn: |
1491 | case egcomm_epdpfdn: |
1492 | EGPL("epdpfdn: |
1492 | EGPL("epdpfdn: Process file: data normalization"); |
1493 | EGPL(""); |
1493 | EGPL(""); |
1494 | EGPL("This command takes two parameters. The first is the name of"); |
1494 | EGPL("This command takes two parameters. The first is the name of"); |
1495 | EGPL("an input EPD data file. The second is the name of the EPD"); |
1495 | EGPL("an input EPD data file. The second is the name of the EPD"); |
1496 | EGPL("output file to be produced from normalizing the input. The"); |
1496 | EGPL("output file to be produced from normalizing the input. The"); |
1497 | EGPL("normalization process produces a canonical external"); |
1497 | EGPL("normalization process produces a canonical external"); |
1498 | EGPL("representation for each EPD input record."); |
1498 | EGPL("representation for each EPD input record."); |
1499 | break; |
1499 | break; |
1500 | case egcomm_epdpfdr: |
1500 | case egcomm_epdpfdr: |
1501 | EGPL("epdpfdr: |
1501 | EGPL("epdpfdr: Process file: data repair"); |
1502 | EGPL(""); |
1502 | EGPL(""); |
1503 | EGPL("This command takes two parameters. The first is the name of"); |
1503 | EGPL("This command takes two parameters. The first is the name of"); |
1504 | EGPL("an input EPD data file. The second is the name of the EPD"); |
1504 | EGPL("an input EPD data file. The second is the name of the EPD"); |
1505 | EGPL("output file to be produced from repairing the input. The"); |
1505 | EGPL("output file to be produced from repairing the input. The"); |
1506 | EGPL("repair process attempts to map all chess move data present"); |
1506 | EGPL("repair process attempts to map all chess move data present"); |
1507 | EGPL("in the input into Standard Algebraic Notation. This repair"); |
1507 | EGPL("in the input into Standard Algebraic Notation. This repair"); |
1508 | EGPL("effort affects the am, bm, pm, pv, sm, and sv operations."); |
1508 | EGPL("effort affects the am, bm, pm, pv, sm, and sv operations."); |
1509 | break; |
1509 | break; |
1510 | case egcomm_epdpfga: |
1510 | case egcomm_epdpfga: |
1511 | EGPL("epdpfga: |
1511 | EGPL("epdpfga: Process file: general analysis"); |
1512 | EGPL(""); |
1512 | EGPL(""); |
1513 | EGPL("This command takes two parameters. The first is the name of"); |
1513 | EGPL("This command takes two parameters. The first is the name of"); |
1514 | EGPL("an input EPD data file. The second is the name of the EPD"); |
1514 | EGPL("an input EPD data file. The second is the name of the EPD"); |
1515 | EGPL("output file to be produced from applying general analysis"); |
1515 | EGPL("output file to be produced from applying general analysis"); |
1516 | EGPL("to each position in the input file. The output analysis is"); |
1516 | EGPL("to each position in the input file. The output analysis is"); |
1517 | EGPL("contained in the acd, acn, acs, ce, and pv operations."); |
1517 | EGPL("contained in the acd, acn, acs, ce, and pv operations."); |
1518 | break; |
1518 | break; |
1519 | case egcomm_epdpflc: |
1519 | case egcomm_epdpflc: |
1520 | EGPL("epdpflc: |
1520 | EGPL("epdpflc: Process file: locate cooks"); |
1521 | EGPL(""); |
1521 | EGPL(""); |
1522 | EGPL("This command is used to scan an EPD file and report on any"); |
1522 | EGPL("This command is used to scan an EPD file and report on any"); |
1523 | EGPL("checkmating cooks. The signle parameter is the name of the"); |
1523 | EGPL("checkmating cooks. The signle parameter is the name of the"); |
1524 | EGPL("EPD file to be scanned. Each record is scanned and if the"); |
1524 | EGPL("EPD file to be scanned. Each record is scanned and if the"); |
1525 | EGPL("centipawn evaluation indicates a forced mate, then the move"); |
1525 | EGPL("centipawn evaluation indicates a forced mate, then the move"); |
Line 1527... | Line 1527... | ||
1527 | EGPL("moves appearing in the bm (best moves) operation on the same"); |
1527 | EGPL("moves appearing in the bm (best moves) operation on the same"); |
1528 | EGPL("record. If the result move does not appear in the bm list,"); |
1528 | EGPL("record. If the result move does not appear in the bm list,"); |
1529 | EGPL("then the record is reported as a cook."); |
1529 | EGPL("then the record is reported as a cook."); |
1530 | break; |
1530 | break; |
1531 | case egcomm_epdpfop: |
1531 | case egcomm_epdpfop: |
1532 | EGPL("epdpfop: |
1532 | EGPL("epdpfop: Process file: operation purge"); |
1533 | EGPL(""); |
1533 | EGPL(""); |
1534 | EGPL("This command takes threee parameters. The first is the name"); |
1534 | EGPL("This command takes threee parameters. The first is the name"); |
1535 | EGPL("of an EPD operation mnemonic to be purged. The second is the"); |
1535 | EGPL("of an EPD operation mnemonic to be purged. The second is the"); |
1536 | EGPL("name fo the input EPD file, and the third is the name of the"); |
1536 | EGPL("name fo the input EPD file, and the third is the name of the"); |
1537 | EGPL("EPD output to be produced by purging the specified operation"); |
1537 | EGPL("EPD output to be produced by purging the specified operation"); |
1538 | EGPL("from the input file."); |
1538 | EGPL("from the input file."); |
1539 | break; |
1539 | break; |
1540 | case egcomm_epdscor: |
1540 | case egcomm_epdscor: |
1541 | EGPL("epdscor: |
1541 | EGPL("epdscor: Score EPD analysis file"); |
1542 | EGPL(""); |
1542 | EGPL(""); |
1543 | EGPL("This command takes one parameter. It is the name of an input"); |
1543 | EGPL("This command takes one parameter. It is the name of an input"); |
1544 | EGPL("EPD data file containing analysis result data. The input"); |
1544 | EGPL("EPD data file containing analysis result data. The input"); |
1545 | EGPL("data analysis is scanned and a brief statistical report is"); |
1545 | EGPL("data analysis is scanned and a brief statistical report is"); |
1546 | EGPL("displayed."); |
1546 | EGPL("displayed."); |
1547 | break; |
1547 | break; |
1548 | case egcomm_epdshow: |
1548 | case egcomm_epdshow: |
1549 | EGPL("epdshow: |
1549 | EGPL("epdshow: Show EPD four fields for the current position"); |
1550 | EGPL(""); |
1550 | EGPL(""); |
1551 | EGPL("This command takes no parameters. It causes the EPD four"); |
1551 | EGPL("This command takes no parameters. It causes the EPD four"); |
1552 | EGPL("data fields for the current position to be displayed."); |
1552 | EGPL("data fields for the current position to be displayed."); |
1553 | break; |
1553 | break; |
1554 | case egcomm_epdspgn: |
1554 | case egcomm_epdspgn: |
Line 1570... | Line 1570... | ||
1570 | EGPL("assigned. Underscore characters in the value are mapped"); |
1570 | EGPL("assigned. Underscore characters in the value are mapped"); |
1571 | EGPL("to blanks; this allows embedded spaces to appear in the"); |
1571 | EGPL("to blanks; this allows embedded spaces to appear in the"); |
1572 | EGPL("received value."); |
1572 | EGPL("received value."); |
1573 | break; |
1573 | break; |
1574 | case egcomm_epdtest: |
1574 | case egcomm_epdtest: |
1575 | EGPL("epdtest: |
1575 | EGPL("epdtest: Developer testing"); |
1576 | EGPL(""); |
1576 | EGPL(""); |
1577 | EGPL("This command takes no parameters. It is used for developer"); |
1577 | EGPL("This command takes no parameters. It is used for developer"); |
1578 | EGPL("testing purposes."); |
1578 | EGPL("testing purposes."); |
1579 | break; |
1579 | break; |
1580 | case egcomm_nil: |
1580 | case egcomm_nil: |
Line 1703... | Line 1703... | ||
1703 | sprintf(tbufv, "PFGA: EPD record: %ld", (record + 1)); |
1703 | sprintf(tbufv, "PFGA: EPD record: %ld", (record + 1)); |
1704 | EGPrintTB(); |
1704 | EGPrintTB(); |
1705 | if (((eopptr = EPDLocateEOPCode(epdptr, epdso_id)) != NULL) |
1705 | if (((eopptr = EPDLocateEOPCode(epdptr, epdso_id)) != NULL) |
1706 | && ((eovptr = eopptr->eop_headeov) != NULL) |
1706 | && ((eovptr = eopptr->eop_headeov) != NULL) |
1707 | && ((s = eovptr->eov_str) != NULL)) { |
1707 | && ((s = eovptr->eov_str) != NULL)) { |
1708 | EGPrint(" |
1708 | EGPrint(" ID: "); |
1709 | EGPrint(s); |
1709 | EGPrint(s); |
1710 | }; |
1710 | }; |
1711 | EGPrint("\n"); |
1711 | EGPrint("\n"); |
1712 | /* output record information to the log file */ |
1712 | /* output record information to the log file */ |
1713 | if (log_file != NULL) { |
1713 | if (log_file != NULL) { |
Line 1720... | Line 1720... | ||
1720 | }; |
1720 | }; |
1721 | /* set up the host current position */ |
1721 | /* set up the host current position */ |
1722 | EGPutHostPosition(); |
1722 | EGPutHostPosition(); |
1723 | /* set host search parameters */ |
1723 | /* set host search parameters */ |
1724 | tree->status[1] = tree->status[0]; |
1724 | tree->status[1] = tree->status[0]; |
1725 |
|
1725 | iteration = 0; |
1726 | ponder = 0; |
1726 | ponder = 0; |
1727 | /* get the starting time */ |
1727 | /* get the starting time */ |
1728 | start_time = time(NULL); |
1728 | start_time = time(NULL); |
1729 | /* run host search; EPD Kit position may be changed */ |
1729 | /* run host search; EPD Kit position may be changed */ |
1730 | result = EGIterate(EGMapToHostColor(EPDFetchACTC()), think); |
1730 | result = EGIterate(EGMapToHostColor(EPDFetchACTC()), think); |
1731 | /* refresh the EPD Kit current position */ |
1731 | /* refresh the EPD Kit current position */ |
1732 | EGGetHostPosition(); |
1732 | EGGetHostPosition(); |
1733 | /* extract analysis count: depth */ |
1733 | /* extract analysis count: depth */ |
1734 | host_acd = |
1734 | host_acd = iteration; |
1735 | if (host_acd == 0) |
1735 | if (host_acd == 0) |
1736 | host_acd = 1; |
1736 | host_acd = 1; |
1737 | /* insert analysis count: depth */ |
1737 | /* insert analysis count: depth */ |
1738 | EPDAddOpInt(epdptr, epdso_acd, host_acd); |
1738 | EPDAddOpInt(epdptr, epdso_acd, host_acd); |
1739 | /* extract analysis count: nodes */ |
1739 | /* extract analysis count: nodes */ |