* Fwd: Re: your mail
@ 2004-02-23 21:08 kripa shankar
2004-02-23 21:21 ` kripa shankar
0 siblings, 1 reply; 2+ messages in thread
From: kripa shankar @ 2004-02-23 21:08 UTC (permalink / raw)
To: gcc, gcc-help; +Cc: gcc-help
--- kripa shankar <kripa82@yahoo.com> wrote:
> Date: Mon, 23 Feb 2004 10:10:19 -0800 (PST)
> From: kripa shankar <kripa82@yahoo.com>
> Subject: Re: your mail
> To: Michael Matz <matz@suse.de>
> CC: gcc@gnu.org, gcc-help@gcc.gnu.org,
> crossgcc@sources.redhat.com
>
> Hey Thanks for the reply..
> The compiler version is 2.95.I have added the dump
> file name ".greg2" after the "jump2" optimization
> and ".stack" optimization in the toplev.c file which
> is shown below.
> if (greg2_dump)
> open_dump_file(".greg2", decl_printable_name
> (decl,2));
> r1_greg2(config_info);
> dump_rtl(".greg2", decl, print_rtl_with_bb, insns);
> Also how can i update the lifeness of the register
> ???. I think thts the problem..the function call
> r1_greg2(config_info);
> calls my file "greg2mod.c" in which iam retrieving
> the head [first instruction] of the basic block 2
> and then inserting the two instructions which i have
> mentioned earlier using the macros at the end..after
> the pass , these are the codes that gets executed
>
> /* Now turn the rtl into assembler code. */
>
>
>
> TIMEVAR (final_time,
> { rtx x; char
> *fnname;
>
>
> /* Get the function's name, as described by its RTL.
> This may be different from the DECL_NAME name used
> in the source file. */
>
>
> x = DECL_RTL (decl);br>
> if (GET_CODE (x) != MEM)
> abort ();
> x = XEXP (x, 0);
> if (GET_CODE (x) != SYMBOL_REF)
> abort ();
> fnname = XSTR (x, 0);
> //This is where the call to the final.c file is done
>
> assemble_start_function (decl, fnname);
>
> final_start_function (insns,
> asm_out_file, optimize);
> final (insns, asm_out_file, optimize,
> 0);
> final_end_function (insns,
> asm_out_file, optimize);
> assemble_end_function (decl, fnname);
>
> if (! quiet_flag)
> fflush (asm_out_file);
> ......
> So how can i make the registers live??? pls help me
> kripa
> --- Michael Matz wrote:> Hi,> > On Mon, 23 Feb
> 2004, kripa shankar wrote:> > > ;; Start of basic
> block 2, registers live: 11 [fp]> 13 [sp]> > (note
> 62 41 45 [bb 2] NOTE_INSN_BASIC_BLOCK)> > (insn 45
> 62 46 (set (reg/i:SI 0 r0) > (const_int 0
> [0x0])) 176 {*movsi_insn} (nil) >
> (expr_list:REG_EQUAL (const_int 0 [0x0]) >
> (nil)))> > (insn 46 45 76 (use (reg/i:SI 0 r0)) -1
> (insn_list> 45 (nil)) (nil))> > (insn 76 46 77
> (set (reg:SI 7 r7) (plus:SI> (reg:SI 5 r5)
> (const_int 2 [0x2]))) -1> (nil) (nil))> >
> (insn 77 76 50 (set (reg:SI 6 r6) (plus:SI>
> (reg:SI 4 r4) (const_int 2 [0x2]))) -1>
> (nil) (nil))> > ;; End of basic block 2> > (note
> 50 77 63 0 NOTE_INSN_BLOCK_END)> > (note 63 50 0 ""
> NOTE_INSN_DELETED)> > > > The instructions inserted
> are r7 = r5 + 2;r6 = r4> + 2; But the problem> > is
> that the inserted instructions are not present> in
> both asm file> > (fourth.s) and the output binary
> file (fourth.o)..> I have inserted these> >
> instructions right after all the optimization>
> passess and before the> > final pass (final.c) where
> RTL gets converted into> Assembly. Kindly help> >
> me.> > There is not enough information. Where
> exactly have> you added the code to> add those
> insns? About which compiler version do> you speak?
> Produce all > dump files (-da) and look which dump
> misses them> first. The problem is, > that you
> include those instructions without updating>
> lifeness (i.e. the > compiler doesn't see, that r6
> and r7 really are> required after you've set > them.
> So, if there is any pass deleting useless> insns
> after you inserted > them, they will get deleted.> >
> > Ciao,> Michael.> > ------> Want more information?
> See the CrossGCC FAQ,>
> http://www.objsw.com/CrossGCC/> Want to unsubscribe?
> Send a note to>
> crossgcc-unsubscribe@sources.redhat.com> >
>
> ---------------------------------
> Do you Yahoo!?
> Yahoo! Mail SpamGuard - Read only the mail you want.
__________________________________
Do you Yahoo!?
Yahoo! Mail SpamGuard - Read only the mail you want.
http://antispam.yahoo.com/tools
^ permalink raw reply [flat|nested] 2+ messages in thread
* Fwd: Re: your mail
2004-02-23 21:08 Fwd: Re: your mail kripa shankar
@ 2004-02-23 21:21 ` kripa shankar
0 siblings, 0 replies; 2+ messages in thread
From: kripa shankar @ 2004-02-23 21:21 UTC (permalink / raw)
To: gcc, gcc-help; +Cc: gcc-help
--- kripa shankar <kripa82@yahoo.com> wrote:
> Date: Mon, 23 Feb 2004 10:10:19 -0800 (PST)
> From: kripa shankar <kripa82@yahoo.com>
> Subject: Re: your mail
> To: Michael Matz <matz@suse.de>
> CC: gcc@gnu.org, gcc-help@gcc.gnu.org,
> crossgcc@sources.redhat.com
>
> Hey Thanks for the reply..
> The compiler version is 2.95.I have added the dump
> file name ".greg2" after the "jump2" optimization
> and ".stack" optimization in the toplev.c file which
> is shown below.
> if (greg2_dump)
> open_dump_file(".greg2", decl_printable_name
> (decl,2));
> r1_greg2(config_info);
> dump_rtl(".greg2", decl, print_rtl_with_bb, insns);
> Also how can i update the lifeness of the register
> ???. I think thts the problem..the function call
> r1_greg2(config_info);
> calls my file "greg2mod.c" in which iam retrieving
> the head [first instruction] of the basic block 2
> and then inserting the two instructions which i have
> mentioned earlier using the macros at the end..after
> the pass , these are the codes that gets executed
>
> /* Now turn the rtl into assembler code. */
>
>
>
> TIMEVAR (final_time,
> { rtx x; char
> *fnname;
>
>
> /* Get the function's name, as described by its RTL.
> This may be different from the DECL_NAME name used
> in the source file. */
>
>
> x = DECL_RTL (decl);br>
> if (GET_CODE (x) != MEM)
> abort ();
> x = XEXP (x, 0);
> if (GET_CODE (x) != SYMBOL_REF)
> abort ();
> fnname = XSTR (x, 0);
> //This is where the call to the final.c file is done
>
> assemble_start_function (decl, fnname);
>
> final_start_function (insns,
> asm_out_file, optimize);
> final (insns, asm_out_file, optimize,
> 0);
> final_end_function (insns,
> asm_out_file, optimize);
> assemble_end_function (decl, fnname);
>
> if (! quiet_flag)
> fflush (asm_out_file);
> ......
> So how can i make the registers live??? pls help me
> kripa
> --- Michael Matz wrote:> Hi,> > On Mon, 23 Feb
> 2004, kripa shankar wrote:> > > ;; Start of basic
> block 2, registers live: 11 [fp]> 13 [sp]> > (note
> 62 41 45 [bb 2] NOTE_INSN_BASIC_BLOCK)> > (insn 45
> 62 46 (set (reg/i:SI 0 r0) > (const_int 0
> [0x0])) 176 {*movsi_insn} (nil) >
> (expr_list:REG_EQUAL (const_int 0 [0x0]) >
> (nil)))> > (insn 46 45 76 (use (reg/i:SI 0 r0)) -1
> (insn_list> 45 (nil)) (nil))> > (insn 76 46 77
> (set (reg:SI 7 r7) (plus:SI> (reg:SI 5 r5)
> (const_int 2 [0x2]))) -1> (nil) (nil))> >
> (insn 77 76 50 (set (reg:SI 6 r6) (plus:SI>
> (reg:SI 4 r4) (const_int 2 [0x2]))) -1>
> (nil) (nil))> > ;; End of basic block 2> > (note
> 50 77 63 0 NOTE_INSN_BLOCK_END)> > (note 63 50 0 ""
> NOTE_INSN_DELETED)> > > > The instructions inserted
> are r7 = r5 + 2;r6 = r4> + 2; But the problem> > is
> that the inserted instructions are not present> in
> both asm file> > (fourth.s) and the output binary
> file (fourth.o)..> I have inserted these> >
> instructions right after all the optimization>
> passess and before the> > final pass (final.c) where
> RTL gets converted into> Assembly. Kindly help> >
> me.> > There is not enough information. Where
> exactly have> you added the code to> add those
> insns? About which compiler version do> you speak?
> Produce all > dump files (-da) and look which dump
> misses them> first. The problem is, > that you
> include those instructions without updating>
> lifeness (i.e. the > compiler doesn't see, that r6
> and r7 really are> required after you've set > them.
> So, if there is any pass deleting useless> insns
> after you inserted > them, they will get deleted.> >
> > Ciao,> Michael.> > ------> Want more information?
> See the CrossGCC FAQ,>
> http://www.objsw.com/CrossGCC/> Want to unsubscribe?
> Send a note to>
> crossgcc-unsubscribe@sources.redhat.com> >
>
> ---------------------------------
> Do you Yahoo!?
> Yahoo! Mail SpamGuard - Read only the mail you want.
__________________________________
Do you Yahoo!?
Yahoo! Mail SpamGuard - Read only the mail you want.
http://antispam.yahoo.com/tools
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2004-02-23 21:18 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-02-23 21:08 Fwd: Re: your mail kripa shankar
2004-02-23 21:21 ` kripa shankar
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).