[ET Trac] #2758: conditional read/write statements
    Samuel Cupp 
    trac-noreply at einsteintoolkit.org
       
    Mon Sep 18 21:09:21 CDT 2023
    
    
  
#2758: conditional read/write statements
 Reporter: Samuel Cupp
   Status: new
Milestone: 
  Version: 
     Type: enhancement
 Priority: minor
Component: Cactus
Currently, if a function reads or writes variables only under certain conditions, proper scheduling within the schedule.ccl would require duplicating the entire function schedule for every possibility. As a simple example,
```
if(CCTK_EQUALS(EOS, "Tabulated")) {
  schedule func at bin
  {
    LANG: C
    READS: var1
    WRITES: var2, var3
  }
} else {
  schedule func at bin
  {
    LANG: C
    READS: var1
    WRITES: var2
  }
}
```
Instead, having the ability to set these conditionals within the function scheduling like
```
schedule func at bin
{
  LANG: C
  READS: var1
  WRITES: var2
  if(CCTK_EQUALS(EOS, "Tabulated")) {
    WRITES: var3
  }
}
```
would make this scheduling much more compact **and** more readable.
--
Ticket URL: https://bitbucket.org/einsteintoolkit/tickets/issues/2758/conditional-read-write-statements
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.einsteintoolkit.org/pipermail/trac/attachments/20230919/cfb6ffc6/attachment-0001.htm>
    
    
More information about the Trac
mailing list