This is a leftover from when we didn't have support for multicomponent
models. Could you please change it as part of your merge request? I think
you just need to extend your loop to cover grid 0 and remove the eax-eaz
aliases in sym.py. If that doesn't work, I will take a closer look at it
after your code is merged.


On Mon, Mar 10, 2014 at 3:23 PM, Niels Looije <notifications@github.com>wrote:

> In sailfish/sym_codegen.py:
>
> > @@ -146,7 +146,9 @@ def _use_pointers(str):
> >
> >  def _use_vectors(str):
> >      ret = str.replace('vx', 'v0[0]').replace('vy', 'v0[1]').replace('vz', 'v0[2]')
> > -    ret = ret.replace('g1eax', 'ea1[0]').replace('g1eay', 'ea1[1]').replace('g1eaz', 'ea1[2]')
> > +    for dist in range(1,9):
> > +        s1 = 'g%sea' % dist; s2 = 'ea%s' % dist
> > +        ret = ret.replace(s1+'x', s2+'[0]').replace(s1+'y', s2+'[1]').replace(s1+'z', s2+'[2]')
>
> fixed
> It is a little strange that for i=0 the replace is 'eax'->'ea0[0]' etc and
> for i>0 'g%seax'->'ea%s[0]' etc. why not all in the form
> 'g%seax'->'ea%s[0]'? then could just iterate over all grid rather than
> explicitely setting i=0 after setting i>0. This took me a while to figure
> out when debugging the code.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/sailfish-team/sailfish/pull/28/files#r10430965>
> .
>



-- 
Michal Januszewski
http://mjanusz.github.com/homepage/