This document aims to give insights at the representation of parameterized
derived-type (PDTs) in FIR and how PDTs are lowered to FIR and interact
with the runtime.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Thanks, @clementval for this detailed Design Document. I did a quick read and have a few nit comments or questions.
| flang/docs/ParameterizedDerivedTypes.md | ||
|---|---|---|
| 23 | ||
| 108 | Nit: The parameters are missing here. | |
| 124 | Nit: The parameters are missing here. | |
| 152 | Nit: parameters are missing here. | |
| 159 | Nit: parameters are missing here. | |
| 673 | ||
| 686 | ||
| 823 | Nit: Something is missing in this sentence. | |
| 824 | In all the following operations could you clarify whether any operation is being extended to accomodate type parameters? | |
| 926 | I understand that no change is proposed here but is the typeparams field required here give that both res and buffer have the parameters in their type? | |
| 931 | Are any changes required for the ArrayValueCopy pass? | |
Address review comments
| flang/docs/ParameterizedDerivedTypes.md | ||
|---|---|---|
| 824 | The operation design is already accommodating type parameters. Lowering and codegen will need to use them accordingly. | |
| 926 | the actual length parameters value is available only if the buffer or res is boxed since they are stored in the addendum. | |
| 931 | Likely not in term of design but any part that is handling type parameter right now will need to be double check and adapted to the chosen solution and implementation. | |
| flang/docs/ParameterizedDerivedTypes.md | ||
|---|---|---|
| 143 | It turned out that the runtime had to traverse components anyway in order to perform byte-swapped unformatted I/O, so this part is already done now. | |