Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lower default initialization of local and dummy entities #939

Merged
merged 1 commit into from
Jul 23, 2021

Conversation

jeanPerier
Copy link
Collaborator

When instantiating variables, identify the ones that must be default
initialized at runtime (locals and intent(out) dummies). Call the
default initialization runtime routine to perform the initialization.

Global variables that have no explicit initialization and have a default
initialization are left TODO. The runtime cannot be used for them, the
fir.global generation will need to be updated for these variables (it was
generating an undefined undefined until now). For now, simply catch and
add a hard TODO for these cases. For information, it is firing 13 times
in NAG F95 tests.

Runtime interface for finalization is added, but nothing is done with it
yet (Final procedures are not F95).

Copy link

@schweitzpgi schweitzpgi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

flang/lib/Lower/ConvertVariable.cpp Outdated Show resolved Hide resolved
When instantiating variables, identify the ones that must be default
initialized at runtime (locals and intent(out) dummies). Call the
default initialization runtime routine to perform the initialization.

Global variables that have no explicit initialization and have a default
initialization are left TODO. The runtime cannot be used for them, the
fir.global generation will need to be updated for these variables (it was
generating an undefined undefined until now). For now, simply catch and
add a hard TODO for these cases. For information, it is firing 13 times
in NAG F95 tests.

Runtime interface for finalization is added, but nothing is done with it
yet (Final procedures are not F95).
@jeanPerier jeanPerier force-pushed the jpr-derived-type-init-2 branch from 2da13ed to 896c6b3 Compare July 23, 2021 09:10
@jeanPerier jeanPerier merged commit 776a3da into fir-dev Jul 23, 2021
@jeanPerier jeanPerier deleted the jpr-derived-type-init-2 branch July 23, 2021 09:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants