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

            Bug ID: 61968
           Summary: ICE (assembly failure) due to wrongly generating a
                    vtable for TYPE(*) / BT_ASSUMED_TYPE
           Product: gcc
           Version: 4.10.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: burnus at gcc dot gnu.org
                CC: jnorris at gcc dot gnu.org, pault at gcc dot gnu.org

Created attachment 33216
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=33216&action=edit
Testcase (test.f90)

Passing a TYPE(*) to CLASS(*) is properly rejected by the compiler, thus, there
is no need to attempt to generate a virtual table for TYPE(*) – ignoring the
problem that TYPE(*) has no real type.

My suspicion is that this happens during resolving the generic call, triggered
by the CLASS - even though the actual class call isn't and shouldn't be done.

The generated function looks in assembly as follows - unsurprisingly, the
assembler stumbles over it:

        .type   __copy_TYPE(*)_0_.2366, @function

Credit for finding the issue goes to Jim.

Reply via email to