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: [PR debug/41343] introduce debug expr temps


On Wed, Oct 7, 2009 at 9:48 AM, Alexandre Oliva <aoliva@redhat.com> wrote:
> On Oct ?6, 2009, Richard Guenther <richard.guenther@gmail.com> wrote:
>
>>> Anyhow, if we find it not to be true, it shouldn't be too hard to get
>>> debug temps into SSA operands, especially if we're to add vops to debug
>>> bind stmts as well.
>
>> Gah. ?Over my dead body!
>
> :-)
>
>> Fair enough. ?Mind adding a comment here? ?Mind adding
>> a DEBUG_DECL_UID macro that encapsulates the negation?
>
> Will do.
>
>>> But the bind point is that where the stmt was before, and the moved DEF
>>> might very well be referenced at a point between the bind point and the
>>> reinsertion point.
>
>> Please get some numbers here - I think this will for example
>> artificially add debug stmts on basic block removal.
>
> We remove basic blocks “backwards” too, from last to first stmt, and
> dominated before dominator. ?So, since the newly-added code only adds a
> debug stmt if it finds the removed SSA DEF is USEd in a debug stmt, it
> would only add a deug stmt if we were to remove a dominator without
> removing its dominated, i.e., if we were to remove an SSA DEF without
> removing its corresponding USEs. ?We don't do that, do we?

I'm not sure.  While we don't remove definitions that are still
used for regular SSA name uses we still can have debug-uses
in another basic-block, no?  Like

 if (0)
   {
     a_1 = ...;
   }
 else
   {
      ...
    }
 # DEBUG i => a_1

here when eliminating the unreachable block we would create
a debug-temp for a_1 just to remove it immediately again
(if that works at all and we're not confused here).

Richard.

> --
> Alexandre Oliva, freedom fighter ? ?http://FSFLA.org/~lxoliva/
> You must be the change you wish to see in the world. -- Gandhi
> Be Free! -- http://FSFLA.org/ ? FSF Latin America board member
> Free Software Evangelist ? ? ?Red Hat Brazil Compiler Engineer
>


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