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] Fix free_lang_data on asm stmts (PR lto/91572)


On Sun, Sep 01, 2019 at 02:30:12PM +0200, Richard Biener wrote:
> On September 1, 2019 1:55:14 PM GMT+02:00, Jakub Jelinek <jakub@redhat.com> wrote:
> >On Sat, Aug 31, 2019 at 03:02:18PM +0200, Richard Biener wrote:
> >> Ok, but I wonder if we can stream the constraint strings in a simpler
> >way - surely the type doesn't really matter?
> >> Why are they not identifier nodes? 
> >
> >I guess they have type because they are parsed like any other string
> >literals during parsing and once we parse them that way, it isn't worth
> >changing them to something else like an identifier.
> 
> Hmm, so we accept wide-char literals as well here? 
> 
> >Would it be enough to just clear their type during free lang data or
> >something similar?
> 
> I guess so.  Maybe do that during gimplification already?  Wonder how we
> pretty print asms then when we mangle their types.  Note the original
> patch is OK as-is I just wondered why we bother to even keep the asm
> constrains as something different than a char *.

The type was actually const char *, which was the problem on the testcase,
as nothing in the testcase required otherwise const char, so we made it
its own distinct type and then were unhappy that a streamed type was handled
that way.

	Jakub


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