Since orientation status doesn't change during FD iterations, it doesn't make sense to query it every time. Just precompute pin offsets for all hard macros, store them in an array and use for each iteration. Also, instead of going over all macros and doing no offset calculations for soft macros, store the indices of hard macros in an array and update only those macros.
Since orientation status doesn't change during FD iterations, it doesn't make sense to query it every time. Just precompute pin offsets for all hard macros, store them in an array and use for each iteration. Also, instead of going over all macros and doing no offset calculations for soft macros, store the indices of hard macros in an array and update only those macros.