File: vector_long.c

package info (click to toggle)
chibicc 1.0.23.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 5,832 kB
  • sloc: ansic: 62,911; sh: 275; makefile: 92
file content (14 lines) | stat: -rw-r--r-- 280 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#include "test.h"

typedef long long4 __attribute__((vector_size(16)));

int main() {
    long4 lv = {1, 2};
    long4 res;

    res = lv + 1; // scalar promotion
    printf("%ld %ld\n", res[0], res[1]);
    ASSERT(2, res[0]);
    ASSERT(3, res[1]);
    return 0;
}