@@ -767,11 +767,11 @@ t_swap_result PlacementAnnealer::try_swap_(MoveGenerator& move_generator,
767767 }
768768 move_outcome_stats.outcome = move_outcome;
769769
770- // If we force a router block move then it was not proposed by the
771- // move generator, so we should not calculate the reward and update
770+ // If we force a router block move or manual move then it was not proposed
771+ // by the move generator, so we should not calculate the reward and update
772772 // the move generators status since this outcome is not a direct
773- // consequence of the move generator
774- if (!router_block_move) {
773+ // consequence of the move generator.
774+ if (!router_block_move && !manual_move_enabled ) {
775775 move_generator.calculate_reward_and_process_outcome (move_outcome_stats, delta_c, REWARD_BB_TIMING_RELATIVE_WEIGHT);
776776 }
777777
@@ -830,6 +830,14 @@ void PlacementAnnealer::placement_inner_loop() {
830830
831831 // Inner loop begins
832832 for (int inner_iter = 0 , inner_crit_iter_count = 1 ; inner_iter < annealing_state_.move_lim ; inner_iter++) {
833+ #ifndef NO_GRAPHICS
834+ // Checks manual move flag for manual move feature
835+ t_draw_state* draw_state = get_draw_state_vars ();
836+ if (draw_state->show_graphics ) {
837+ manual_move_enabled = manual_move_is_selected ();
838+ }
839+ #endif /* NO_GRAPHICS*/
840+
833841 t_swap_result swap_result = try_swap_ (move_generator, placer_opts_.place_algorithm , manual_move_enabled);
834842
835843 if (swap_result.move_result == e_move_result::ACCEPTED) {
0 commit comments