public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "fxcoudert at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/115070] [13/14/15 Regression] ICE using IEEE_ARITHMETIC in a derived type method with class, intent(out)
Date: Thu, 16 May 2024 10:59:43 +0000	[thread overview]
Message-ID: <bug-115070-4-7aNUc4EHI3@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-115070-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115070

--- Comment #6 from Francois-Xavier Coudert <fxcoudert at gcc dot gnu.org> ---
So the var_decl in question is fpstate.0:

 <var_decl 0x1034e1200 fpstate.0
    type <array_type 0x1036c4b28
        type <integer_type 0x1035003f0 c_char public unsigned QI
            size <integer_cst 0x1034bce70 constant 8>
            unit-size <integer_cst 0x1034bce88 constant 1>
            align:8 warn_if_not_align:0 symtab:0 alias-set -1 canonical-type
0x1035003f0 precision:8 min <integer_cst 0x1034bced0 0> max <integer_cst
0x1034bceb8 255>
            pointer_to_this <pointer_type 0x103503bb8>>
        BLK
        size <integer_cst 0x103546988 constant 264>
        unit-size <integer_cst 0x103546aa8 constant 33>
        align:8 warn_if_not_align:0 symtab:0 alias-set -1 canonical-type
0x1036c4b28
        domain <integer_type 0x1036c4a80 type <integer_type 0x1035007e0>
            DI
            size <integer_cst 0x1034bcd80 constant 64>
            unit-size <integer_cst 0x1034bcd98 constant 8>
            align:64 warn_if_not_align:0 symtab:0 alias-set -1 canonical-type
0x1036c4a80 precision:64 min <integer_cst 0x1034bd050 0> max <integer_cst
0x103546a60 32>>
        pointer_to_this <pointer_type 0x1036c4bd0>>
    addressable used ignored BLK s.f90:10:17 size <integer_cst 0x103546988 264>
unit-size <integer_cst 0x103546aa8 33>
    align:8 warn_if_not_align:0 context <function_decl 0x1036c8100 my_sub>>

And if I look at the tree dump, it seems the variable is indeed not created
correctly:

__attribute__((fn spec (". w ")))
void my_sub (struct __class_my_mod_My_type_t & restrict obs)
{
  try
    {
      _gfortran_ieee_procedure_entry ((void *) &fpstate.0);

see the missing declaration for fpstate.0. But it is created by
gfc_create_var(), like so many other local variables in the front-end, so I
have no idea why it's disappearing.

  parent reply	other threads:[~2024-05-16 10:59 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-13 14:23 [Bug fortran/115070] New: ICE using IEEE_ARITHMETIC in a derived type method with intent(out) statement bardeau at iram dot fr
2024-05-13 17:09 ` [Bug fortran/115070] [13/14/15 Regression] ICE using IEEE_ARITHMETIC in a derived type method with class, intent(out) anlauf at gcc dot gnu.org
2024-05-13 17:24 ` anlauf at gcc dot gnu.org
2024-05-15  6:31 ` pault at gcc dot gnu.org
2024-05-16 10:00 ` bardeau at iram dot fr
2024-05-16 10:17 ` fxcoudert at gcc dot gnu.org
2024-05-16 10:59 ` fxcoudert at gcc dot gnu.org [this message]
2024-05-17 14:32 ` pault at gcc dot gnu.org
2024-05-21  9:20 ` jakub at gcc dot gnu.org
2024-05-21 12:03 ` pault at gcc dot gnu.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=bug-115070-4-7aNUc4EHI3@http.gcc.gnu.org/bugzilla/ \
    --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).