spcl / spcl/dace

Copy from non-Stream data to a Stream generated erroneous code

Open
#368 0 comments 0 reactions 0 assignees View on GitHub
bug codegen
Dominant language
Python
Stars
593
Forks
163
Avg merge
2d 23h
Merged PRs (30d)
60

Description

**Describe the bug**
Currently, when copying directly from data to data, the memlet can be written in 2 different but equivalent ways.
The memlet data and subset are based either on the source of the edge or the destination.
When copying from non-Stream data to a Stream, the correct push code is generated only when the memlet is based around the destination.
If the memlet uses the source data and subset, then CopyND code is generated, which doesn't compile.

**To Reproduce**
Steps to reproduce the behavior:
You may use the test `tests/python_frontend/transients_test.py` from the python-frontend-docs branch, but in master (the issue has been fixed in the python-frontend-docs branch, by checking whether the destination is a Stream and adjusting the memlet accordingly).

**Expected behavior**
Regardless of the memlet being based around the source or destination, push code should be generated when writing to a Stream.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.