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]

Re: [PATCH] PR middle-end/19774


Steven Bosscher wrote:
> On Wednesday 14 March 2007 19:43, Josh Conner wrote:
>> 2007-03-14  Josh Conner  <jconner@apple.com>
>>
>>         PR middle-end/19774
>>         * builtins.c (expand_builtin_alloca): Create NOTE_INSN_ALLOCA.
>>         * except.c (sjlj_emit_function_enter): Split into...
>>         (sjlj_generate_setjmp_sequence): ..., with logic to handle
>>         unregistering.
>>         (sjlj_emit_context_saves): ..., with logic for handling
>>         NOTE_INSN_ALLOCA.
>>         (sjlj_build_landing_pads): Call sjlj_emit_context_saves
>>         instead of sjlj_emit_function_enter.
>>         * final.c (final_scan_insn): Handle NOTE_INSN_ALLOCA.
>>         * insn-notes.def: Add NOTE_INSN_ALLOCA.
> 
> IMHO it's a bad idea to add new INSN notes.  People have tried to
> make the existing notes redundant -- especially the ones that would
> appear inside basic blocks -- and remove the ones that are unused.
> Adding new notes would make that effort more difficult again.
> 
> See also http://gcc.gnu.org/wiki/Speedup_areas under RTL, or
> http://gcc.gnu.org/ml/gcc-patches/2004-08/msg01383.html, or even
> insn-notes.def itself (and I quote):
> 
>    We are slowly removing the concept of insn-chain notes from the
>    compiler.  Adding new codes to this file is STRONGLY DISCOURAGED.
>    If you think you need one, look for other ways to express what you
>    mean, such as register notes or bits in the basic-block structure.  */
> 
> If it is up to me, your patch should be changed to avoid introducing
> your new NOTE_INSN_ALLOCA.

OK - thanks for pointing that out.  I'll see if I can use a REG note
instead, unless someone has a better suggestion.

- Josh


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