public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "jakub at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/36631] [4.3/4.4 Regression] attribute always_inline  ->  sorry, unimplemented: recursive inlining
Date: Tue, 04 Nov 2008 16:05:00 -0000	[thread overview]
Message-ID: <20081104160344.17960.qmail@sourceware.org> (raw)
In-Reply-To: <bug-36631-16302@http.gcc.gnu.org/bugzilla/>



------- Comment #8 from jakub at gcc dot gnu dot org  2008-11-04 16:03 -------
Actually, looking at this some more, the problem is just that g has a wrong
DECL_ARG_TYPE.  When instantiate_class_template is called on B, it instantiates
g; class C is returned by lookup_template_class, but not yet a complete type,
so it doesn't have TYPE_HAS_INIT_REF set, nor TYPE_HAS_COMPLEX_INIT_REF, nor
TREE_ADDRESSABLE.  Then tsubst_decl <case PARM_DECL>:
            if (!DECL_TEMPLATE_PARM_P (r))
              DECL_ARG_TYPE (r) = type_passed_as (type);
is called, but the RECORD_TYPE C is still incomplete at this point, so
type_passed_as, seeing no TREE_ADDRESSABLE being set on type, returns type
itself.  Afterwards when require_complete_types_for_parms is called on
trigger's
parameters, instantiate_class_template is called on C and all the above
mentioned 3 bits are set.  But nothing goes back to fix up DECL_ARG_TYPE, at
least not until instantiate_pending_templates eventually calls
require_complete_types_for_parms on g's params.  But that is already way after
trigger has been gimplified.  So I believe we need to update DECL_ARG_TYPE
(parm)
from type_passed_as (TREE_TYPE (parm)) for calls a function is making, but am
not sure where would that be best done.  In genericization?


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36631


  parent reply	other threads:[~2008-11-04 16:05 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-25 17:08 [Bug c++/36631] New: [4.3 " josep dot m dot perez at bsc dot es
2008-07-04 21:50 ` [Bug c++/36631] [4.3/4.4 " jsm28 at gcc dot gnu dot org
2008-07-10 14:24 ` [Bug tree-optimization/36631] " rguenth at gcc dot gnu dot org
2008-07-31 14:45 ` hubicka at gcc dot gnu dot org
2008-08-07 15:26 ` rguenth at gcc dot gnu dot org
2008-08-27 22:10 ` jsm28 at gcc dot gnu dot org
2008-09-15 14:28 ` rguenth at gcc dot gnu dot org
2008-09-15 14:38 ` [Bug c++/36631] " rguenth at gcc dot gnu dot org
2008-10-21 12:16 ` jakub at gcc dot gnu dot org
2008-11-04 16:05 ` jakub at gcc dot gnu dot org [this message]
2008-11-04 16:45 ` jakub at gcc dot gnu dot org
2008-11-20  1:50 ` jakub at gcc dot gnu dot org
2008-11-20  1:52 ` [Bug c++/36631] [4.3 " jakub at gcc dot gnu dot org
2009-01-24 10:25 ` rguenth at gcc dot gnu dot org
2009-08-04 12:41 ` rguenth at gcc dot gnu dot org
2010-05-22 18:25 ` rguenth at gcc dot gnu dot org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20081104160344.17960.qmail@sourceware.org \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).