[flang] Lower type-bound procedure call needing dynamic dispatch to fir.dispatch
authorValentin Clement <clementval@gmail.com>
Wed, 12 Oct 2022 13:24:21 +0000 (15:24 +0200)
committerValentin Clement <clementval@gmail.com>
Wed, 12 Oct 2022 13:24:49 +0000 (15:24 +0200)
commit7883900c04fc6ba2dd3f6c5d260d1e272e1fe343
treecadb3ee713c20b8c8ba65dcef507efc83b7e35f9
parentb1d7a95e4e4a2b57cbe02636bbe357dc48d615c5
[flang] Lower type-bound procedure call needing dynamic dispatch to fir.dispatch

Lower call with polymorphic entities to fir.dispatch operation. This patch only
focus one lowering with simple scalar polymorphic entities. A follow-up patch
will deal with allocatble, pointer and array of polymorphic entities as they
require box manipulation for the passed-object.

Reviewed By: jeanPerier

Differential Revision: https://reviews.llvm.org/D135649
flang/include/flang/Lower/CallInterface.h
flang/include/flang/Optimizer/Dialect/FIRType.h
flang/lib/Lower/CallInterface.cpp
flang/lib/Lower/ConvertExpr.cpp
flang/lib/Lower/Mangler.cpp
flang/lib/Optimizer/Builder/BoxValue.cpp
flang/lib/Optimizer/Builder/FIRBuilder.cpp
flang/lib/Optimizer/Dialect/FIROps.cpp
flang/test/Lower/dispatch.f90 [new file with mode: 0644]