|
36 | 36 | #include "utl/Logger.h" |
37 | 37 |
|
38 | 38 | namespace mpl2 { |
| 39 | +using utl::MPL; |
39 | 40 |
|
40 | 41 | ////////////////////////////////////////////////////////////////// |
41 | 42 | // Class SACoreSoftMacro |
@@ -752,51 +753,91 @@ void SACoreSoftMacro::shrink() |
752 | 753 |
|
753 | 754 | void SACoreSoftMacro::printResults() const |
754 | 755 | { |
755 | | - logger_->report(std::string(80, '*')); |
756 | | - logger_->report("SACoreSoftMacro"); |
757 | | - logger_->report("number of macros : {}", macros_.size()); |
| 756 | + debugPrint(logger_, MPL, "macro_placement", 1, "SACoreSoftMacro"); |
| 757 | + debugPrint(logger_, |
| 758 | + MPL, |
| 759 | + "macro_placement", |
| 760 | + 1, |
| 761 | + "number of macros : {}", |
| 762 | + macros_.size()); |
758 | 763 | for (auto macro : macros_) |
759 | | - logger_->report("lx = {}, ly = {}, width = {}, height = {}, name = {}", |
760 | | - macro.getX(), |
761 | | - macro.getY(), |
762 | | - macro.getWidth(), |
763 | | - macro.getHeight(), |
764 | | - macro.getName()); |
765 | | - logger_->report("width = {}, outline_width = {}", width_, outline_width_); |
766 | | - logger_->report("height = {}, outline_height = {}", height_, outline_height_); |
767 | | - logger_->report( |
| 764 | + debugPrint(logger_, |
| 765 | + MPL, |
| 766 | + "macro_placement", |
| 767 | + 1, |
| 768 | + "lx = {}, ly = {}, width = {}, height = {}, name = {}", |
| 769 | + macro.getX(), |
| 770 | + macro.getY(), |
| 771 | + macro.getWidth(), |
| 772 | + macro.getHeight(), |
| 773 | + macro.getName()); |
| 774 | + debugPrint(logger_, |
| 775 | + MPL, |
| 776 | + "macro_placement", |
| 777 | + 1, |
| 778 | + "width = {}, outline_width = {}", |
| 779 | + width_, |
| 780 | + outline_width_); |
| 781 | + debugPrint(logger_, |
| 782 | + MPL, |
| 783 | + "macro_placement", |
| 784 | + 1, |
| 785 | + "height = {}, outline_height = {}", |
| 786 | + height_, |
| 787 | + outline_height_); |
| 788 | + debugPrint( |
| 789 | + logger_, |
| 790 | + MPL, |
| 791 | + "macro_placement", |
| 792 | + 1, |
768 | 793 | "outline_weight = {}, outline_penalty = {}, norm_outline_penalty = {}", |
769 | 794 | outline_weight_, |
770 | 795 | outline_penalty_, |
771 | 796 | norm_outline_penalty_); |
772 | | - logger_->report( |
773 | | - "wirelength_weight = {}, wirelength = {}, norm_wirelength = {}", |
774 | | - wirelength_weight_, |
775 | | - wirelength_, |
776 | | - norm_wirelength_); |
777 | | - logger_->report( |
778 | | - "guidance_weight = {}, guidance_penalty = {}, norm_guidance_penalty = " |
779 | | - "{}", |
780 | | - guidance_weight_, |
781 | | - guidance_penalty_, |
782 | | - norm_guidance_penalty_); |
783 | | - logger_->report( |
784 | | - "fence_weight = {}, fence_penalty = {}, norm_fence_penalty = {}", |
785 | | - fence_weight_, |
786 | | - fence_penalty_, |
787 | | - norm_fence_penalty_); |
788 | | - logger_->report( |
789 | | - "macro_blockage_weight = {}, macro_blockage_penalty = {}, " |
790 | | - "norm_macro_blockage_penalty = {}", |
791 | | - macro_blockage_weight_, |
792 | | - macro_blockage_penalty_, |
793 | | - norm_macro_blockage_penalty_); |
794 | | - logger_->report( |
795 | | - "notch_weight = {}, notch_penalty = {}, norm_notch_penalty = {}", |
796 | | - notch_weight_, |
797 | | - notch_penalty_, |
798 | | - norm_notch_penalty_); |
799 | | - logger_->report("final cost = {}", getNormCost()); |
| 797 | + debugPrint(logger_, |
| 798 | + MPL, |
| 799 | + "macro_placement", |
| 800 | + 1, |
| 801 | + "wirelength_weight = {}, wirelength = {}, norm_wirelength = {}", |
| 802 | + wirelength_weight_, |
| 803 | + wirelength_, |
| 804 | + norm_wirelength_); |
| 805 | + debugPrint(logger_, |
| 806 | + MPL, |
| 807 | + "macro_placement", |
| 808 | + 1, |
| 809 | + "guidance_weight = {}, guidance_penalty = {}, " |
| 810 | + "norm_guidance_penalty = {}", |
| 811 | + guidance_weight_, |
| 812 | + guidance_penalty_, |
| 813 | + norm_guidance_penalty_); |
| 814 | + debugPrint(logger_, |
| 815 | + MPL, |
| 816 | + "macro_placement", |
| 817 | + 1, |
| 818 | + "fence_weight = {}, fence_penalty = {}, norm_fence_penalty = {}", |
| 819 | + fence_weight_, |
| 820 | + fence_penalty_, |
| 821 | + norm_fence_penalty_); |
| 822 | + debugPrint(logger_, |
| 823 | + MPL, |
| 824 | + "macro_placement", |
| 825 | + 1, |
| 826 | + "macro_blockage_weight = {}, macro_blockage_penalty = {}, " |
| 827 | + "norm_macro_blockage_penalty = {}", |
| 828 | + macro_blockage_weight_, |
| 829 | + macro_blockage_penalty_, |
| 830 | + norm_macro_blockage_penalty_); |
| 831 | + debugPrint(logger_, |
| 832 | + MPL, |
| 833 | + "macro_placement", |
| 834 | + 1, |
| 835 | + "notch_weight = {}, notch_penalty = {}, norm_notch_penalty = {}", |
| 836 | + notch_weight_, |
| 837 | + notch_penalty_, |
| 838 | + norm_notch_penalty_); |
| 839 | + debugPrint( |
| 840 | + logger_, MPL, "macro_placement", 1, "final cost = {}", getNormCost()); |
800 | 841 | } |
801 | 842 |
|
802 | 843 | // fill the dead space by adjust the size of MixedCluster |
|
0 commit comments