m2m模型翻译
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
478 B

6 months ago
  1. #ifndef __VSX__
  2. #error "VSX is not supported"
  3. #endif
  4. #include <altivec.h>
  5. #if (defined(__GNUC__) && !defined(vec_xl)) || (defined(__clang__) && !defined(__IBMC__))
  6. #define vsx_ld vec_vsx_ld
  7. #define vsx_st vec_vsx_st
  8. #else
  9. #define vsx_ld vec_xl
  10. #define vsx_st vec_xst
  11. #endif
  12. int main(void)
  13. {
  14. unsigned int zout[4];
  15. unsigned int z4[] = {0, 0, 0, 0};
  16. __vector unsigned int v_z4 = vsx_ld(0, z4);
  17. vsx_st(v_z4, 0, zout);
  18. return zout[0];
  19. }