Go to file
James Molloy 2b21a7cf36 Reapply r237539 with a fix for the Chromium build.
Make sure if we're truncating a constant that would then be sign extended
that the sign extension of the truncated constant is the same as the
original constant.

> Canonicalize min/max expressions correctly.
>
> This patch introduces a canonical form for min/max idioms where one operand
> is extended or truncated. This often happens when the other operand is a
> constant. For example:
>
> %1 = icmp slt i32 %a, i32 0
> %2 = sext i32 %a to i64
> %3 = select i1 %1, i64 %2, i64 0
>
> Would now be canonicalized into:
>
> %1 = icmp slt i32 %a, i32 0
> %2 = select i1 %1, i32 %a, i32 0
> %3 = sext i32 %2 to i64
>
> This builds upon a patch posted by David Majenemer
> (https://www.marc.info/?l=llvm-commits&m=143008038714141&w=2). That pass
> passively stopped instcombine from ruining canonical patterns. This
> patch additionally actively makes instcombine canonicalize too.
>
> Canonicalization of expressions involving a change in type from int->fp
> or fp->int are not yet implemented.

llvm-svn: 237821
2015-05-20 18:41:25 +00:00
clang [CodeGen] Check x86_64-arguments.c tests on AVX as well. NFC. 2015-05-20 18:39:16 +00:00
clang-tools-extra docs: Spell a couple of cmake options with =ON in the docs 2015-05-18 05:05:49 +00:00
compiler-rt Revert some of "Silence some CMake 3.3 dev warnings in compiler-rt" 2015-05-20 18:39:59 +00:00
debuginfo-tests New round of fixes for "Always compile debuginfo-tests for the host triple" 2014-10-18 23:47:59 +00:00
libclc Use a more accurate implementation for exp 2015-05-13 03:55:09 +00:00
libcxx Start a to-do list for libc++ 2015-05-20 17:39:54 +00:00
libcxxabi LIBCXXABI_LIBUNWIND_INCLUDES is already set before calling find_path, and find_path will not update it. 2015-05-09 21:03:01 +00:00
libunwind Code cleanup: Remove duplicated line. 2015-05-17 13:49:18 +00:00
lld [ARM] Add needed symbols during dynamic executable linking 2015-05-20 13:39:33 +00:00
lldb Implement attach to process on Windows. 2015-05-20 18:31:17 +00:00
llgo benchcomp: Add macho_symsizes mode for comparing Mach-O object symbol sizes. 2015-05-12 22:14:26 +00:00
llvm Reapply r237539 with a fix for the Chromium build. 2015-05-20 18:41:25 +00:00
openmp Makefile fix for testsuite -- Follow up to r237618 2015-05-19 21:28:33 +00:00
polly Add diagnostic for unsigned integer comparisions 2015-05-20 15:37:11 +00:00