diff options
author | Chris Lattner <sabre@nondot.org> | 2007-06-22 21:44:33 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2007-06-22 21:44:33 +0000 |
commit | e9a6453ded48e319aec7a8be4a0a477915aaa8f8 (patch) | |
tree | 7813978379d937ec2b371b9d3a8d18d9c51cd889 /clang/CodeGen/CodeGenFunction.cpp | |
parent | c6395936ae1c35e755a3fd7e4a67c7b47142643c (diff) | |
download | bcm5719-llvm-e9a6453ded48e319aec7a8be4a0a477915aaa8f8.tar.gz bcm5719-llvm-e9a6453ded48e319aec7a8be4a0a477915aaa8f8.zip |
add some infrastructure for codegen'ing complex numbers. implement addition
of complex. We now produce optimal code for:
void test(_Complex float *Y) {
*Y = *Y + *Y;
}
$ clang -emit-llvm cg.c | llvm-as | opt -std-compile-opts | llc -march=x86-64
...
_test:
movss (%rdi), %xmm0
addss %xmm0, %xmm0
movss 4(%rdi), %xmm1
movss %xmm0, (%rdi)
addss %xmm1, %xmm1
movss %xmm1, 4(%rdi)
ret
llvm-svn: 39673
Diffstat (limited to 'clang/CodeGen/CodeGenFunction.cpp')
0 files changed, 0 insertions, 0 deletions