go_write/read는 psy 레이어에서 intent(in/out) 생성시 사용할듯
grid property는 psy 레이어에서 kernel 코드 call 할 때 아규먼트 생성에 사용할듯
이러한 아규먼트를 사용하려면 fortran api에서 grid_init을 통해 해당 정보 값을 연결해 주어야 함!!
grid propertis 쓰지말고, GO_CU/CV/CT/CF 등만 쓰는것이 좋을듯
# Settings specific to the Gocean 1.0 API
# =======================================
[gocean1.0]
access_mapping = go_read: read, go_write: write, go_readwrite: readwrite
The detail for grid properties. There are four entries:
1) The name used in a kernel declaration.
2) The string required to dereference the property from the field.
A {0} is replaced with the name of the field variable
3) The type of the property: must be 'scalar' or 'array'.
4) The intrinsic type of the property: must be 'integer' or 'real'.
The following values are used by PSyclone, and are therefore required:
go_grid_xstop, go_grid_ystop,
gogrid{internal,whole}{inner,outer}{start,stop}
Details about the grid properties and their usage can be found in the
- iterates_over의 기능
<img width="465" alt="image" src="https://user-images.githubusercontent.com/89285343/158769412-221a0500-c19d-422c-b241-53caf7420c32.png">
- grid_offset, GO_CU/CV/CT/CF, 의 기능
def setup_bounds():
'''Populates the GOLoop._bounds_lookup dictionary. This is
used by PSyclone to look up the loop boundaries for each loop
it creates.'''
[Kernel 코드의 metadata]
GO_POINTWISE : 현재 이것만 지원
GO_WRITE/READ, GO_GRID_DX_V/W 등 grid properties
The detail for grid properties. There are four entries:
1) The name used in a kernel declaration.
2) The string required to dereference the property from the field.
A {0} is replaced with the name of the field variable
3) The type of the property: must be 'scalar' or 'array'.
4) The intrinsic type of the property: must be 'integer' or 'real'.
The following values are used by PSyclone, and are therefore required:
go_grid_xstop, go_grid_ystop,
gogrid{internal,whole}{inner,outer}{start,stop}
Details about the grid properties and their usage can be found in the
PSyclone documentation at:
https://psyclone.readthedocs.io/en/stable/gocean1p0.html#argument-metadata-meta-args
grid-properties = go_grid_xstop: {0}%%grid%%subdomain%%internal%%xstop: scalar: integer, go_grid_ystop: {0}%%grid%%subdomain%%internal%%ystop: scalar: integer, go_grid_data: {0}%%data: array: real, go_grid_internal_inner_stop: {0}%%internal%%xstop: scalar: integer, go_grid_internal_outer_stop: {0}%%internal%%ystop: scalar: integer, go_grid_whole_inner_stop: {0}%%whole%%xstop: scalar: integer, go_grid_whole_outer_stop: {0}%%whole%%ystop: scalar: integer, go_grid_internal_inner_start: {0}%%internal%%xstart: scalar: integer, go_grid_internal_outer_start: {0}%%internal%%ystart: scalar: integer, go_grid_whole_inner_start: {0}%%whole%%xstart: scalar: integer, go_grid_whole_outer_start: {0}%%whole%%ystart: scalar: integer, go_grid_area_t: {0}%%grid%%area_t: array: real, go_grid_area_u: {0}%%grid%%area_u: array: real, go_grid_area_v: {0}%%grid%%area_v: array: real, go_grid_mask_t: {0}%%grid%%tmask: array: integer, go_grid_dx_t: {0}%%grid%%dx_t: array: real, go_grid_dx_u: {0}%%grid%%dx_u: array: real, go_grid_dx_v: {0}%%grid%%dx_v: array: real, go_grid_dy_t: {0}%%grid%%dy_t: array: real, go_grid_dy_u: {0}%%grid%%dy_u: array: real, go_grid_dy_v: {0}%%grid%%dy_v: array: real, go_grid_lat_u: {0}%%grid%%gphiu: array: real, go_grid_lat_v: {0}%%grid%%gphiv: array: real, go_grid_dx_const: {0}%%grid%%dx: scalar: real, go_grid_dy_const: {0}%%grid%%dy: scalar: real, go_grid_nx: {0}%%grid%%nx: scalar: integer, go_grid_ny: {0}%%grid%%ny: scalar: integer, go_grid_x_min_index: {0}%%grid%%subdomain%%internal%%xstart: scalar: integer, go_grid_x_max_index: {0}%%grid%%subdomain%%internal%%xstop: scalar: integer, go_grid_y_min_index: {0}%%grid%%subdomain%%internal%%ystart: scalar: integer, go_grid_y_max_index: {0}%%grid%%subdomain%%internal%%ystop: scalar: integer
무차원 integer = GO_I_SCALAR, 무차원 real = GO_R_SCALAR
def setup_bounds(): '''Populates the GOLoop._bounds_lookup dictionary. This is used by PSyclone to look up the loop boundaries for each loop it creates.'''