diff mbox

Scalar vector binary operation

Message ID CABYV9SU3EPvnwdBXfuVP368rb8hWAAz6E__ZPFh=ty0GFzU7Ug@mail.gmail.com
State New
Headers show

Commit Message

Artem Shinkarov Sept. 28, 2011, 6:58 p.m. UTC
Hi

In the attachment there is a patch with the changes. I don't have
rights to commit to the cvs.

If we write about vector-related stuff, may be it would make sense to
mention that from now on we can make vector shifts and we can index
vector. These are changes from 4.6 (I guess), but they were never
mentioned in any changes.


Thanks,
Artem.


On Wed, Sep 28, 2011 at 3:46 PM, Ian Lance Taylor <iant@google.com> wrote:
> Artem Shinkarov <artyom.shinkaroff@gmail.com> writes:
>
>> I can try to put a description in the document. I am not sure that I
>> have rights to commit to the svn, but at least I can try to write the
>> text.
>>
>> There are also pending patches for vector-comparison (almost
>> submitted) and vector shuffling (still under discussion), but I hope
>> to finish both of them until the new release is coming.
>>
>> Could you point out where the cnhanges.html is located in svn?
>
> It's actually still in CVS, at gcc.gnu.org:/cvs/gcc.
>
> Ian
>

Comments

Gerald Pfeifer Dec. 5, 2011, 11:27 a.m. UTC | #1
On Wed, 28 Sep 2011, Artem Shinkarov wrote:
> In the attachment there is a patch with the changes. I don't have
> rights to commit to the cvs.

Thanks, Michael.  I have applied the patch on your behalf.

Gerald
diff mbox

Patch

Index: htdocs/gcc-4.7/changes.html
===================================================================
RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-4.7/changes.html,v
retrieving revision 1.38
diff -u -r1.38 changes.html
--- htdocs/gcc-4.7/changes.html	27 Sep 2011 18:42:56 -0000	1.38
+++ htdocs/gcc-4.7/changes.html	28 Sep 2011 18:52:33 -0000
@@ -150,6 +150,18 @@ 
       through which the compiler can be hinted about pointer alignment
       and can use it to improve generated code.
   </li>
+  <li>When a binary operation performed on vector types and one of the operands
+      is a uniform vector it is possible to replace the vector with the
+      generating element. For example:
+      <pre>
+typedef int v4si __attribute__ ((vector_size (16)));
+v4si res, a = {1,2,3,4};
+int x;
+
+res = 2 + a;  /* means {2,2,2,2} + a  */
+res = a - x;  /* means a - {x,x,x,x}  */
+      </pre>
+  </li>
 </ul>
 
 <h3>C++</h3>