ianhinder / Kranc

A Mathematica package for generating code for solving time dependent partial differential equations
http://kranccode.org
GNU General Public License v2.0
28 stars 10 forks source link

Ensure READS/WRITES entries are not duplicated #131

Open ianhinder opened 8 years ago

ianhinder commented 8 years ago

Comer Duncan reports that the following schedule.ccl was created:

schedule formgk AT CCTK_INITIAL before CT_MultiLevel
{
  LANG: C
  SYNC: CT_g
  READS: grid::x(Everywhere)
  READS: grid::y(Everywhere)
  READS: grid::z(Everywhere)
  READS: grid::x(Everywhere)
  READS: grid::y(Everywhere)
  READS: grid::z(Everywhere)
  WRITES: CT_BrillAnalytic::g11(Interior)
  WRITES: CT_BrillAnalytic::g12(Interior)
  WRITES: CT_BrillAnalytic::g13(Interior)
  WRITES: CT_BrillAnalytic::g22(Interior)
  WRITES: CT_BrillAnalytic::g23(Interior)
  WRITES: CT_BrillAnalytic::g33(Interior)
} "formgk"

This looks like a bug, because Kranc should not create duplicate entries like this.

ianhinder commented 8 years ago

Example file demonstrating the problem is at https://gist.github.com/ianhinder/c2d3ca1ba646ca6618cd.