On Fri, Sep 9, 2011 at 5:51 PM, Artem Shinkarov
<artyom.shinkar...@gmail.com> wrote:
> Hi, sorry for the delay, I had a lot of other stuff to do.
>
> In the attachment there is a new patch that fixes all the issues
> pointed by Joseph and almost all the issues pointed by Richard. The
> issues that are not fixed are explained further.
>
> Artem.
>
>>+      if (TREE_CODE (vect) == VECTOR_CST)
>>+        {
>>+            unsigned i;
>>+            tree vals = TREE_VECTOR_CST_ELTS (vect);
>>+            for (i = 0; vals; vals = TREE_CHAIN (vals), ++i)
>>+              if (i == index)
>>
>>operand_equal_p
>
> Sorry, I didn't get this comment. It looks fine to me without any changes.

Error on my side, the code is ok.

>>+  if (need_asgn)
>>+    {
>>+      TREE_ADDRESSABLE (tmpvec) = 1;
>>
>>this should be at the point we call create_tmp_var.
>
> Here we are talking about writing this line two times several lines
> upper. I would like to leave it just to avoid code duplication.

Well, it's just that they are supposed to be occuring in pairs only,
so it would make the code more understandable.  So please do the duplication.

>>Index: gcc/passes.c
>>===========================================================>========
>>--- gcc/passes.c        (revision 178354)
>>+++ gcc/passes.c        (working copy)
>>@@ -1354,7 +1354,6 @@ init_optimization_passes (void)
>>         NEXT_PASS (pass_vectorize);
>>           {
>>             struct opt_pass **p = &pass_vectorize.pass.sub;
>>-             NEXT_PASS (pass_lower_vector_ssa);
>>             NEXT_PASS (pass_dce_loop);
>>           }
>>          NEXT_PASS (pass_predcom);
>>@@ -1366,6 +1365,7 @@ init_optimization_passes (void)
>>         NEXT_PASS (pass_lim);
>>         NEXT_PASS (pass_tree_loop_done);
>>       }
>>+      NEXT_PASS (pass_lower_vector_ssa);
>>
>>This change should not be neccesary.
>
> Without this change the vector lowering with -Ox does not execute the
> pass at all. So the overall idea is to make sure that if we have -Ox
> we make lowering only once and as late as possible.
>
> But maybe I am just missing something.

Ah, I thought we had already converted the -O0 pass to work like the
complex lowering at -O0 (which uses a property).  So hm, I guess the
change is ok as well.

I'm on vacation for the next two weeks, conditional on the x86 approval
I'll take care of committing the patch after I return.

Richard.

>
>
> Thanks,
> Artem.
>
> P.S. X86 PEOPLE, WHERE ARE YOU? :)
>

Reply via email to