This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: How to assign proper static_pass_number and recalculate other ones?


On 10/01/2015 02:47 AM, Konstantin Vladimirov wrote:
Hi,

I am creating my own RTL pass inside private backend (GCC 5.2.0) and I
want to register it via register_pass call from override_options hook,
to not interfere with platform-independent GCC code.

   register_pass (new my_cool_rtl_pass (g, "my_cool_pass"),
                  PASS_POS_INSERT_AFTER, "sched1", 1);

Everything just fine except the number of pass to print a dump file
name is assigned the very last one (about 280), whereas pass itself
should go immediately after sched1, so I want it to have static number
234 and dump file name as test.c.234.my_cool_pass. Now it runs after
sched1 correctly, but have large number and visually goes in dump-all
list at the end.

Can I inside pass manager update all pass numbers after pass insertion
to preserve visible dump order the same as run order?
David probably knows best what's currently possible with dump numbers in the pass manager. He's on PTO this week.

ISTM that whatever we're currently doing that if a pass is inserted by a plug-in that pass #s ought to auto-magically update themselves.

jeff


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]