When calling a type-bound procedure from a polymoprhic array element,
the dynamic type needs to be extracted from the array descriptor
and passed to the embox operation for the pass-object.
Depends on D135809
Paths
| Differential D135856
[flang] Lower tbp dispatch calls for polymorphic array element ClosedPublic Authored by clementval on Oct 13 2022, 1:02 AM.
Details Summary When calling a type-bound procedure from a polymoprhic array element, Depends on D135809
Diff Detail
Event TimelineHerald added projects: Restricted Project, Restricted Project. · View Herald TranscriptOct 13 2022, 1:02 AM
jeanPerier added inline comments.
This revision is now accepted and ready to land.Oct 13 2022, 2:40 AM
clementval removed a parent revision: D135809: [flang] Add optional tdesc operand to fir.embox for polymorphic entities.Oct 13 2022, 5:28 AM Closed by commit rG4265f78dd7c4: [flang] Lower tbp dispatch calls for polymorphic array element (authored by clementval). · Explain WhyOct 13 2022, 5:48 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 467456 flang/include/flang/Optimizer/Dialect/FIROps.td
flang/lib/Lower/ConvertVariable.cpp
flang/lib/Optimizer/Builder/FIRBuilder.cpp
flang/test/Lower/dispatch.f90
|
Not sure this is the best way to retrieve the array descriptor to get the tdesc. This will probably need to be rework in the future to handle other cases.