- Apr 30, 2011
-
-
Benjamin Kramer authored
This obviously helps a lot if the division would be turned into a libcall (think i64 udiv on i386), but div is also one of the few remaining instructions on modern CPUs that become more expensive when the bitwidth gets bigger. This also helps register pressure on i386 when dividing chars, divb needs two 8-bit parts of a 16 bit register as input where divl uses two registers. int foo(unsigned char a) { return a/10; } int bar(unsigned char a, unsigned char b) { return a/b; } compiles into (x86_64) _foo: imull $205, %edi, %eax shrl $11, %eax ret _bar: movzbl %dil, %eax divb %sil, %al movzbl %al, %eax ret llvm-svn: 130615
-
- Nov 07, 2009
-
-
Chris Lattner authored
(eliminating some extends) if the new type of the computation is legal or if both the source and dest are illegal. This prevents instcombine from changing big chains of computation into i64 on 32-bit targets for example. llvm-svn: 86398
-
- Sep 11, 2009
-
-
Dan Gohman authored
input filename so that opt doesn't print the input filename in the output so that grep lines in the tests don't unintentionally match strings in the input filename. llvm-svn: 81537
-
- Sep 09, 2009
-
-
Dan Gohman authored
llvm-svn: 81257
-
- Sep 08, 2009
-
-
Dan Gohman authored
of using llvm-as, now that opt supports this. llvm-svn: 81226
-
- Jul 14, 2009
-
-
Eli Friedman authored
llvm-svn: 75539
-