This is the mail archive of the gcc-patches@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] |
Hi Steven, Jeff, I found a flaw in original patch, which results in inaccurate register pressure. Here comes the updated patches, improving code size a little bit on Thumb2/powerpc comparing to original patches. Please review. Thanks 2012-10-16 Bin Cheng <bin.cheng@arm.com> * gcse.c: Update copyright dates. (hoist_expr_reaches_here_p): Change parameter type from char * to sbitmap. 2012-10-16 Bin Cheng <bin.cheng@arm.com> * common.opt (flag_ira_hoist_pressure): New. * doc/invoke.texi (-fira-hoist-pressure): Describe. * ira-costs.c (ira_set_pseudo_classes): New parameter. * ira.h: Update copyright dates. (ira_set_pseudo_classes): Update prototype. * haifa-sched.c (sched_init): Update call. * ira.c (ira): Update call. * regmove.c: Update copyright dates. (regmove_optimize): Update call. * loop-invariant.c: Update copyright dates. (move_loop_invariants): Update call. * gcse.c: (struct bb_data): New structure. (BB_DATA): New macro. (curr_bb, curr_reg_pressure): New static variables. (should_hoist_expr_to_dom): Rename from hoist_expr_reaches_here_p. Change parameter expr_index to expr. New parameters pressure_class, nregs and hoisted_bbs. Use reg pressure to determine the distance expr can be hoisted. (hoist_code): Use reg pressure to direct the hoist process. (get_regno_pressure_class, get_pressure_class_and_nregs) (change_pressure, calculate_bb_reg_pressure): New. (one_code_hoisting_pass): Calculate register pressure. Allocate and free data. gcc/testsuite/ChangeLog 2012-10-16 Bin Cheng <bin.cheng@arm.com> * testsuite/gcc.dg/hoist-register-pressure.c: New test. > -----Original Message----- > From: gcc-patches-owner@gcc.gnu.org [mailto:gcc-patches-owner@gcc.gnu.org] On > Behalf Of Bin Cheng > Sent: Friday, October 12, 2012 4:09 PM > To: 'Steven Bosscher' > Cc: Jeff Law; gcc-patches@gcc.gnu.org > Subject: RE: [PATCH RFA] Implement register pressure directed hoist pass > > Hi, > This is the updated patches split from original one according to Steven's > suggestion. Also fixed spelling errors. > > Apart from this, I also implemented a draft patch simulating register pressure > accurately during hoisting, unfortunately the size data isn't better than this > patch. If it's right, this can prove my previous observation that decrease of > register pressure during hoisting process is rare. I will continue > investigating the correctness of the patch and see what I can get. > > Please review. Thanks > > And the ChangeLog: > > 2012-10-12 Bin Cheng <bin.cheng@arm.com> > > * gcse.c: Update copyright dates. > (hoist_expr_reaches_here_p): Change parameter type from char * > to sbitmap. > > 2012-10-12 Bin Cheng <bin.cheng@arm.com> > > * common.opt (flag_ira_hoist_pressure): New. > * doc/invoke.texi (-fira-hoist-pressure): Describe. > * ira-costs.c (ira_set_pseudo_classes): New parameter. > * ira.h: Update copyright dates. > (ira_set_pseudo_classes): Update prototype. > * haifa-sched.c (sched_init): Update call. > * ira.c (ira): Update call. > * regmove.c: Update copyright dates. > (regmove_optimize): Update call. > * loop-invariant.c: Update copyright dates. > (move_loop_invariants): Update call. > * gcse.c: (struct bb_data): New structure. > (BB_DATA): New macro. > (curr_bb, curr_reg_pressure): New static variables. > (should_hoist_expr_to_dom): Rename from hoist_expr_reaches_here_p. > Change parameter expr_index to expr. > New parameters pressure_class, nregs and hoisted_bbs. > Use reg pressure to determine the distance expr can be hoisted. > (hoist_code): Use reg pressure to direct the hoist process. > (get_regno_pressure_class, get_pressure_class_and_nregs) > (change_pressure, calculate_bb_reg_pressure): New. > (one_code_hoisting_pass): Calculate register pressure. Allocate > and free data. > > gcc/testsuite/ChangeLog > 2012-10-12 Bin Cheng <bin.cheng@arm.com> > > * testsuite/gcc.dg/hoist-register-pressure.c: New test.
Attachment:
hoist-reg-pressure-20121016-002.txt
Description: Text document
Attachment:
hoist-reg-pressure-20121016-001.txt
Description: Text document
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |