[flang] Implement derived type description table encoding
authorpeter klausler <pklausler@nvidia.com>
Mon, 7 Dec 2020 22:46:24 +0000 (14:46 -0800)
committerpeter klausler <pklausler@nvidia.com>
Tue, 8 Dec 2020 18:26:58 +0000 (10:26 -0800)
commit4fede8bc8a015477f2a8feeb30a1d2a2e155106d
treefe30e1232e3703cf0c932c91a94b02975e40f739
parent3e86fbc97189366866aac4286fb9c412c1fb526c
[flang] Implement derived type description table encoding

Define Fortran derived types that describe the characteristics
of derived types, and instantiations of parameterized derived
types, that are of relevance to the runtime language support
library.  Define a suite of corresponding C++ structure types
for the runtime library to use to interpret instances of the
descriptions.

Create instances of these description types in Semantics as
static initializers for compiler-created objects in the scopes
that define or instantiate user derived types.

Delete obsolete code from earlier attempts to package runtime
type information.

Differential Revision: https://reviews.llvm.org/D92802
25 files changed:
flang/docs/RuntimeTypeInfo.md
flang/include/flang/Semantics/runtime-type-info.h [new file with mode: 0644]
flang/include/flang/Semantics/scope.h
flang/lib/Semantics/CMakeLists.txt
flang/lib/Semantics/compute-offsets.cpp
flang/lib/Semantics/runtime-type-info.cpp [new file with mode: 0644]
flang/lib/Semantics/semantics.cpp
flang/lib/Semantics/tools.cpp
flang/module/__fortran_builtins.f90
flang/module/__fortran_type_info.f90 [new file with mode: 0644]
flang/module/iso_c_binding.f90
flang/runtime/CMakeLists.txt
flang/runtime/allocatable.cpp
flang/runtime/allocatable.h
flang/runtime/derived-type.cpp [deleted file]
flang/runtime/derived-type.h [deleted file]
flang/runtime/derived.cpp [new file with mode: 0644]
flang/runtime/derived.h [new file with mode: 0644]
flang/runtime/descriptor.cpp
flang/runtime/descriptor.h
flang/runtime/transformational.cpp
flang/runtime/type-info.h [new file with mode: 0644]
flang/test/Semantics/typeinfo01.f90 [new file with mode: 0644]
flang/tools/f18/CMakeLists.txt
flang/tools/f18/f18.cpp