I noticed I forgot to CC the list on the last email, I need to make "reply
all" my default.
Sorry for the double email!
---------- Forwarded message ----------
From: Nicholas Curtis <nicholas.curtis(a)uconn.edu>
Date: Mon, Mar 19, 2018 at 2:11 PM
Subject: Re: [Loopy] Issue with explicit vector temporaries / if-statements
To: Andreas Kloeckner <lists(a)informa.tiker.net>
It seems simply incorrect to me that that
'test' would become a
vector. Can you point to the logic that makes that
So 'test' will detect a "ilp" (really, vector) iname here
, pulls the vector size here
and then changes the shape / vectorizes 'test' here
It appears that this is only called from *realize_ilp *(where it's given an
iname), and *preprocess_kernel* (where no iname is supplied)
The heuristic would probably end up being implemented here as well.
if we deem it reasonable that some code 'out
there' might be
depending on this behavior
I don't know how much the explicit SIMD stuff is currently utilized. As
mentioned, the if statement w/ vector dtypes breaks compilation, so nothing
will depend on that one.
The pattern of:
<> temp = 1
resulting in a vector 'temp', might be used though... and seemingly,
indicates that we'll still need my syntax extension:
and corresponding (for forcing a vector type):
I suppose we'll see if anyone else weighs in on these emails when deciding
I'll get a PR in sometime soon (after we close out the pending shuffles PR)
with fixes for this and (depending on how ambitious I am) potentially other
vector-temporaries issues (e.g., making vector array literals for global
On Mon, Mar 19, 2018 at 1:48 PM, Andreas Kloeckner <lists(a)informa.tiker.net>
Nicholas Curtis <nicholas.curtis(a)uconn.edu>
- Does this seem like a workable patch to force
temporaries to scalar /
It seems simply incorrect to me that that 'test' would become a
vector. Can you point to the logic that makes that happen?
- Should I code up the mentioned heuristic (i.e,,
temporaries if they directly depend on the vector-iname)?
That seems sensible. If the current behavior is not outright nonsense
(and if we deem it reasonable that some code 'out there' might be
depending on this behavior), we might need a language version bump.
- Should we throw an exception for a
vector-dependent if statement that
contains instructions that are not simple assignments?
Yeah--this should throw Unvectorizable.
What about multiple instructions?
Same, I'm thinking.
Thanks for thinking about/working on these things!