Rules about type of comparison of gcc vector types

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I'm writing code about gcc vector types, which, in C, looks like this.

```C
typedef int v4si __attribute__ ((vector_size (16)));
```

The relevant documentation is as follows.

> The result of the comparison is a vector of the same width and number of elements as the comparison operands with a signed integral element type.

However, on architectures where different integral types have the same
width, e.g. `long` and `long long` are both 64-bit on x86-64 linux, it
is unclear which type will be used (on x86-64 linux, the type of both
`vector of long == vector of long` and `vector of long long == vector
of long long` are both `vector of long`). Are there any more specific
rules in such cases? Since I want to support many different
architectures, experimenting on all of them to find the rule seems
kind of tedious...

Thanks!



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux