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

Stencils with multiple ranges should sometimes get access-pattern specs #22

Open
dorchard opened this issue Jul 5, 2016 · 2 comments
Open
Assignees

Comments

@dorchard
Copy link
Member

dorchard commented Jul 5, 2016

e.g. p(:,0) = sum(q(:,1,:))
Investigate further what the correct behaviour is here. This currently gets the specification
stencil readOnce, (reflexive(dim=1))*(reflexive(dim=3)) :: q
But I believe this is an example which is not a true stencil. Instead this should merely be an access pattern:
access readOnce, (reflexive(dim=1))*(reflexive(dim=3)) :: q

@dorchard dorchard self-assigned this Jul 5, 2016
@dorchard
Copy link
Member Author

Reconsider in light of 8b5c622

@dorchard
Copy link
Member Author

Note that the equivalent code here would be:

do i = 1, 2
  s = 0
  do j = 1, 2
    do k = 1, 3
      s = s + q(j,1,k)
    end do
  end do
  p(i,0) = s
end do

Which currently does not get the access stencil inferred which seems like a bug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants