Commit Graph

44076 Commits

Author SHA1 Message Date
Chris Lattner d2c3e86cc3 Fix 2006-04-28-Sign-extend-bool.ll for ia64.
llvm-svn: 51632
2008-05-28 04:00:06 +00:00
Chris Lattner c2fb8d7e2b reindent.
llvm-svn: 51631
2008-05-28 03:59:32 +00:00
Dan Gohman 68bddb8966 Fix the encoding for two more "rm" instructions that were using MRMSrcReg.
llvm-svn: 51630
2008-05-28 01:50:19 +00:00
Mon P Wang 5e3faf2343 Fixed X86 encoding error CVTPS2PD and CVTPD2PS when the source operand
is a memory location

llvm-svn: 51626
2008-05-28 00:42:27 +00:00
Nate Begeman f1e18c7c44 Don't attempt to create VZEXT_LOAD out of an extload. This an issue where the
code generator would do something like this:

f64 = load f32 <anyext>, f32mem
v2f64 = insertelt undef, %0, 0
v2f64 = insertelt %1, 0.0, 1

into 

v2f64 = vzext_load f32mem

which on x86 is movsd, when you really wanted a cvtss2sd/movsd pair.

llvm-svn: 51624
2008-05-28 00:24:25 +00:00
Nick Kledzik 1c4627c282 use space insted of tabs
llvm-svn: 51623
2008-05-28 00:06:14 +00:00
Chris Lattner a120a521a5 Fix a couple crashes on invalid input.
llvm-svn: 51622
2008-05-27 23:32:43 +00:00
Ted Kremenek ffdbeefc54 When the build command is xcodebuild, set the magical environment variable LDPLUSPLUS to g++ to ensure that C++ object files are linked with g++ instead of gcc.
llvm-svn: 51621
2008-05-27 23:18:07 +00:00
Ted Kremenek f9671ecbfd Correctly check to see if we are analyzing C++ files (skip).
llvm-svn: 51620
2008-05-27 23:17:16 +00:00
Devang Patel 1c56ace4df Check first member alignment and uses packed struct if required.
llvm-svn: 51619
2008-05-27 22:45:40 +00:00
Devang Patel d608074e09 Fix test case
llvm-svn: 51618
2008-05-27 22:44:22 +00:00
Nick Kledzik ce956e0613 fix infinite recursion if a global's initializer references the global
llvm-svn: 51617
2008-05-27 22:07:08 +00:00
Gabor Greif 29e0ad2ff1 Make Use::init() private, it breaks invariants, clients should assign or use set().
llvm-svn: 51615
2008-05-27 21:29:38 +00:00
Dan Gohman a61379eeea Use Function::getEntryBlock instead of Function::begin, for clarity.
llvm-svn: 51613
2008-05-27 20:55:29 +00:00
Dan Gohman 3ec5520286 Print debug output when any edge becomes executable, including
the first visited edge.

llvm-svn: 51612
2008-05-27 20:47:30 +00:00
Devang Patel 8b16aeb879 Add instcombine after global optimizations.
llvm-svn: 51611
2008-05-27 20:42:44 +00:00
Dan Gohman 4ec1b4e3f9 Fix a word-o and add an explicit keyword.
llvm-svn: 51610
2008-05-27 20:41:18 +00:00
Bill Wendling 2e44ec7c4d Incorporated feedback: Check that the implicitly defined operands aren't used
before deleting the instruction.

llvm-svn: 51609
2008-05-27 20:40:52 +00:00
Dan Gohman e3a6a18364 Tidy up whitespace in ConstantRange::print output.
llvm-svn: 51606
2008-05-27 20:29:07 +00:00
Devang Patel d38b712ee0 Use IPSCCPPass instead of IPConstantPropagationPass.
llvm-svn: 51605
2008-05-27 20:18:45 +00:00
Dan Gohman 221e9d0d22 Specify a target so that this tests tests what it's intended to test.
llvm-svn: 51600
2008-05-27 17:55:57 +00:00
Dan Gohman 923a375053 Make this test independent of the target-triple; the stack alignment
is specifically what this test depends on.

llvm-svn: 51599
2008-05-27 17:44:23 +00:00
Gabor Greif a3de9e4576 back out last commit: The .cpp file for a module should include its corresponding header first, even if redundant.
llvm-svn: 51598
2008-05-27 17:26:02 +00:00
Eli Friedman 203cdd5aae Add the copysign builtins; I ran into a program that wanted
__builtin_copysign.

llvm-svn: 51597
2008-05-27 15:59:57 +00:00
Eli Friedman 21911e89d5 A few more cases for aggregate values.
llvm-svn: 51596
2008-05-27 15:51:49 +00:00
Eli Friedman 5e2281ede8 Implementation of __builtin_ctlz.
llvm-svn: 51595
2008-05-27 15:32:46 +00:00
Eli Friedman 824f8c12fd Assume statement expressions have side effects; this gets rid of a lot
of extra warnings in the Python source.

llvm-svn: 51594
2008-05-27 15:24:04 +00:00
Matthijs Kooijman ca5bdef66a Use an explicit llvm:: prefix in the STATISTIC macro, so STATISTIC can still be
used when "using namespace llvm" is not in effect.

llvm-svn: 51592
2008-05-27 12:41:24 +00:00
Duncan Sands 698348dfac Fix some constructs that gcc-4.4 warns about.
llvm-svn: 51591
2008-05-27 11:50:51 +00:00
Gabor Greif 6974e1d380 prune unneeded #includes
llvm-svn: 51590
2008-05-27 11:06:03 +00:00
Gabor Greif e9408e6e96 remove unneeded reinterpret_casts
llvm-svn: 51589
2008-05-27 11:03:29 +00:00
Gabor Greif 0a0f2c1dcb We have the correct headers included to know that BB isa Value. No reinterpret_cast necessary.
llvm-svn: 51588
2008-05-27 10:48:39 +00:00
Eli Friedman 70f5a921b7 The cache is working again; re-enable it.
llvm-svn: 51587
2008-05-27 08:43:22 +00:00
Eli Friedman a904087b0d Get the type right for wide string literals; it's wchar_t, not char.
llvm-svn: 51586
2008-05-27 07:57:14 +00:00
Eli Friedman 6f024557ea Add FIXME.
llvm-svn: 51585
2008-05-27 05:09:49 +00:00
Eli Friedman aee9e54dca Don't swap function decls, and add them to the scope as they are
encountered.  Mixing up the decls is unintuitive, and confuses the AST 
destruction code. Fixes PR2360.

Note that there is a need to look up the characteristics and 
declarations of a function associated with a particular name or decl, 
but the original swapping code doesn't solve it properly. 
http://lists.cs.uiuc.edu/pipermail/cfe-dev/2008-May/001644.html is one 
suggestion for how to fix that.

llvm-svn: 51584
2008-05-27 05:07:37 +00:00
Eli Friedman 078c963a31 Add a more reliable check for whether a static declaration has already
been used.  In preparation for the fix to PR2360, but also a minor bug 
in its own right.

llvm-svn: 51583
2008-05-27 04:58:01 +00:00
Owen Anderson 698e72ec2c Remove ADCE from the optimization pipeline.
llvm-svn: 51581
2008-05-27 04:27:27 +00:00
Eli Friedman ac0285a683 Stop leaking the main Sema object. (Leak found using valgrind.)
llvm-svn: 51580
2008-05-27 04:23:47 +00:00
Eli Friedman 3e1d35b92d Stop leaking the target data. (Leak found with valgrind.)
llvm-svn: 51579
2008-05-27 04:22:24 +00:00
Eli Friedman bdef5df44e Generalize the float type generation code, and specifically fix the
codegen of X86 long double.

llvm-svn: 51578
2008-05-27 04:20:05 +00:00
Eli Friedman 3e113409cb Implementation of gcc mode attribute; this is significant because
it fixes PR2204.  Not too much to say about the implementation; it works 
in a similar way to the vector size attribute.

At some point, we need to modify the targets to provide information 
about the appropriate types.

llvm-svn: 51577
2008-05-27 03:33:27 +00:00
Eli Friedman 42ed07e10e Rewrite struct/union layout. This is mostly cleanup; this might also fix
a few bugs, but I don't know of any in particular. This has good effects 
besides cleanup, though: it also should make it easier to implement the 
aligned and packed attributes, and also target-specific struct layouts, 
because the code won't have to be duplicated in codegen.

llvm-svn: 51576
2008-05-27 03:14:44 +00:00
Eli Friedman e2bbfe22c7 Stop leaking the TUDecl.
llvm-svn: 51575
2008-05-27 03:08:09 +00:00
Eli Friedman 1c2d5f56f8 Change diagnostic per suggestion, to make it a bit clearer what is
happening.

llvm-svn: 51574
2008-05-27 02:01:50 +00:00
Nick Lewycky 3ebe82b57a InequalityGraph::node() can create new nodes, invalidating iterators across
the set of nodes. Fix makeEqual to handle this by creating the new node first
then iterating across them second.

llvm-svn: 51573
2008-05-27 00:59:05 +00:00
Nick Lewycky 6be65d2a84 Grammaro.
llvm-svn: 51572
2008-05-26 22:49:36 +00:00
Gabor Greif 2d3024d838 eliminate calls to deprecated Use::init() interface
llvm-svn: 51570
2008-05-26 21:33:52 +00:00
Nick Lewycky a61cc6ece0 Whoops -- forgot PR reference on this test.
llvm-svn: 51569
2008-05-26 20:23:33 +00:00
Nick Lewycky 213e114a2c The Linux ABI emits an extra "movl %esp, %ebp" in function prologue and
sometimes a "mov %ebp, %esp" in the epilogue.

Force these tests that rely on counting 'mov' to use i686-apple-darwin8.8.0
where they were written.

llvm-svn: 51568
2008-05-26 20:18:56 +00:00