Aaron Watry 7659157f1b Add hadd builtin
(x + y) >> 1 gets changed to:
(x>>1) + (y>>1) + (x&y&1)

Saves us having to do any llvm assembly and overflow checking in the addition.

Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
llvm-svn: 188476
2013-08-15 19:21:07 +00:00

5 lines
87 B
Common Lisp

#include <clc/clc.h>
#define __CLC_BODY <hadd.inc>
#include <clc/integer/gentype.inc>