1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 19:12:56 +02:00
Commit Graph

46901 Commits

Author SHA1 Message Date
Dale Johannesen
adb4b4f1de Fix FP_TO_UINT->i32 on ppc32 -mcpu=g5. This was
using Promote which won't work because i64 isn't
a legal type.  It's easy enough to use Custom, but
then we have the problem that when the type
legalizer is promoting FP_TO_UINT->i16, it has no
way of telling it should prefer FP_TO_SINT->i32
to FP_TO_UINT->i32.  I have uncomfortably hacked
this by making the type legalizer choose FP_TO_SINT
when both are Custom.
This fixes several regressions in the testsuite.

llvm-svn: 72891
2009-06-04 20:53:52 +00:00
Evan Cheng
dada49d18a RALinScan::attemptTrivialCoalescing() was returning a virtual register instead of the physical register it is allocated to. This resulted in virtual register(s) being added the live-in sets.
llvm-svn: 72890
2009-06-04 20:53:36 +00:00
Evan Cheng
7f49dfb5fa A value defined by an implicit_def can be liven to a use BB. This is unfortunate. But register allocator still has to add it to the live-in set of the use BB.
llvm-svn: 72889
2009-06-04 20:28:22 +00:00
Evan Cheng
8a6c448ab0 A value defined by an implicit_def can be liven to a use BB. This is unfortunate. But register allocator still has to add it to the live-in set of the use BB.
llvm-svn: 72888
2009-06-04 20:25:48 +00:00
Douglas Gregor
31439d9bde CMake: Use explicit dependencies for Xcode (as well as MSVC), to make
the CMake-generated Xcode project build properly.

llvm-svn: 72883
2009-06-04 19:53:37 +00:00
Nick Kledzik
5864847d7b <rdar://problem/6944342> libLTO for darwin should add -static when assembling .s
llvm-svn: 72881
2009-06-04 19:14:08 +00:00
Lang Hames
563729c80b Removed SimpleRewriter.
llvm-svn: 72880
2009-06-04 18:45:36 +00:00
Dale Johannesen
a9a7e5d234 For XTARGET to work on targets not in the list,
there must also be an XFAIL line.  Fix a couple
examples of this.

llvm-svn: 72876
2009-06-04 18:27:43 +00:00
Dan Gohman
05fe1217c7 Check in test changes that I accidentally left out of r72872.
llvm-svn: 72875
2009-06-04 18:22:31 +00:00
Douglas Gregor
8de3150a4d Properly detect malloc_zone_statistics in CMake build system
llvm-svn: 72873
2009-06-04 17:22:52 +00:00
Dan Gohman
882851fe9f Don't do the X * 0.0 -> 0.0 transformation in instcombine, because
instcombine doesn't know when it's safe. To partially compensate
for this, introduce new code to do this transformation in
dagcombine, which can use UnsafeFPMath.

llvm-svn: 72872
2009-06-04 17:12:12 +00:00
Dan Gohman
76bdd6f844 Fix comments.
llvm-svn: 72870
2009-06-04 16:49:15 +00:00
Torok Edwin
8c34bcb7ab --plugin is not needed for bfd anymore. Update docs.
llvm-svn: 72867
2009-06-04 16:08:10 +00:00
Sanjiv Gupta
aba7b3b661 Remove unused code.
llvm-svn: 72866
2009-06-04 15:16:24 +00:00
Oscar Fuentes
cbaf5a8795 CMake: Renamed LLVM_ENABLE_ASSERTS to
LLVM_ENABLE_ASSERTIONS. Fine-tuned the logic that controls the
definition of NDEBUG and _DEBUG macros.

Thanks to Jay Foad for this suggestions.

llvm-svn: 72864
2009-06-04 09:26:16 +00:00
Sanjiv Gupta
f0fb280dd7 Custom lower SUB with two register operands.
llvm-svn: 72861
2009-06-04 08:52:28 +00:00
Torok Edwin
a10c3b9bc6 Fix comments.
llvm-svn: 72858
2009-06-04 08:18:25 +00:00
Torok Edwin
5da9f51d1e Add support for outputting ANSI colors to raw_fd_ostream.
llvm-svn: 72854
2009-06-04 07:09:50 +00:00
Eli Friedman
11070e275f PR3739, part 2: Use an explicit store to spill XMM registers. (Previously,
the code tried to use "push", which doesn't exist for XMM registers.)

llvm-svn: 72836
2009-06-04 02:32:04 +00:00
Eli Friedman
fd27229206 PR3739, part 1: Disable the red zone on Win64.
llvm-svn: 72830
2009-06-04 02:02:01 +00:00
Dan Gohman
c2061b7d10 Remove a #include of <iostream>.
llvm-svn: 72828
2009-06-04 01:59:35 +00:00
Evan Cheng
e3a05e6690 Re-apply 72756 with fixes. One of those was introduced by we changed MachineInstrBuilder::addReg() interface.
llvm-svn: 72826
2009-06-04 01:15:28 +00:00
Lang Hames
e4f9b4a57c Removed more testing code that snuck in earlier.
llvm-svn: 72825
2009-06-04 01:04:22 +00:00
Nick Kledzik
870391a06e <rdar://problem/6940611> libLTO.dylib needs to let linker specify path to assembler
Add lto_codegen_set_assembler_path() API which allows the linker to specify the
path to the assembler tool to run.  When assembler is used (instead of compiler)
different command line options are used.
Add LTO_API_VERSION #define so clients (linkers) can conditionalize use of new APIs.

llvm-svn: 72823
2009-06-04 00:28:45 +00:00
Bruno Cardoso Lopes
32a9f8acaf Use uint8_t and int32_t in {JIT,Machine}CodeEmiters
llvm-svn: 72821
2009-06-04 00:15:51 +00:00
Stuart Hastings
8ec6d51936 Evan says it's wrong; back out 72808.
llvm-svn: 72817
2009-06-03 22:59:34 +00:00
Nick Kledzik
23e080b04e <rdar://problem/6941517> C++ static constructors not preserved for static executable using LTO
Move setRelocationModel() to be called before TargetMachine is instantiated.

llvm-svn: 72816
2009-06-03 22:52:12 +00:00
Daniel Dunbar
57d886ecbc Change LTO to run the global opt pass twice.
- This matches llvm-ld.

It took a bit of archeology to figure out what the right thing to do was
(whether this was intentionally added or intentionally removed). My final
conclusion is that Chris added this intentionally here:
  http://llvm.org/viewvc/llvm-project?view=rev&revision=16913
but the changes weren't propogated to llvm-ld until here:
  http://llvm.org/viewvc/llvm-project?view=rev&revision=34058
which was after lto.cpp had been cloned off (of llvm-ld), here:
  http://llvm.org/viewvc/llvm-project?view=rev&revision=29494

From the commit message, it looks like the motivation for running global opt
again is because we ran it prior to inlining. Based on that I updated the
comment and also only run the pass if we actually ran the inliner.

Chris, please review.

llvm-svn: 72811
2009-06-03 21:51:32 +00:00
Eli Friedman
dbf32ddf16 PR4317: Handle splits where the new block is unreachable correctly in
DominatorTreeBase::Split.

llvm-svn: 72810
2009-06-03 21:42:06 +00:00
Stuart Hastings
4f72cea26a Recognize another euphemism for MOVDQ2Q.
llvm-svn: 72808
2009-06-03 21:39:14 +00:00
Evan Cheng
b71402d6ae For Darwin / x86_64, override -relocation-model=static to pic if the output is assembly since Darwin assembler does not really support -static codeine.
I view this as a temporary workaround until the assembler / linker changes.

llvm-svn: 72806
2009-06-03 21:13:54 +00:00
Daniel Dunbar
6a35862267 Add createStandardLTOPasses to StandardPasses.h, and move lto and llvm-ld over.
- I know it sounds crazy, but I think all the pass lists are now coalesced into
   StandardPasses.h.

llvm-svn: 72805
2009-06-03 21:06:14 +00:00
Dan Gohman
fcdb0d4193 Convert Alpha and Mips to use a MachineFunctionInfo subclass to
carry GlobalBaseReg, and GlobalRetAddr too in Alpha's case. This
eliminates the need for them to search through the
MachineRegisterInfo livein list in order to identify these
virtual registers. EmitLiveInCopies is now the only user of the
virtual register portion of MachineRegisterInfo's livein data.

llvm-svn: 72802
2009-06-03 20:30:14 +00:00
Dan Gohman
691dd710e9 Remove the redundant TM member from X86DAGToDAGISel; replace it
with an accessor method which simply casts the parent class
SelectionDAGISel's TM to the target-specific type.

llvm-svn: 72801
2009-06-03 20:20:00 +00:00
Dan Gohman
6e9ad19ef7 Don't attempt to simplify an non-affine IV expression if it can't
be simplified to a loop-invariant value. This fixes PR4315.

llvm-svn: 72798
2009-06-03 19:11:31 +00:00
Mike Stump
a864e12f97 Make the buildbot see green (to make it easier to spot the next person
that puts a new warning in).

llvm-svn: 72797
2009-06-03 19:07:46 +00:00
Daniel Dunbar
fe1e04f85a Switch opt to using StandardPasses.h
- No functionality change, but please check if you don't believe me.

llvm-svn: 72789
2009-06-03 18:22:15 +00:00
Daniel Dunbar
cc8a220a38 Remove some silly code.
llvm-svn: 72788
2009-06-03 18:13:05 +00:00
Daniel Dunbar
2436bbf945 Add StandardPasses.h which embeds the standard compilation passes shared by
clang/llvm-gcc.
 - Implemented as inline functions for linking simplicity.

llvm-svn: 72786
2009-06-03 17:52:39 +00:00
Bruno Cardoso Lopes
8fa826d852 Move ELFCodeEmiter stuff to new files
llvm-svn: 72785
2009-06-03 17:47:27 +00:00
Bruno Cardoso Lopes
43896d0ee4 Revert 72650
llvm-svn: 72783
2009-06-03 16:55:02 +00:00
Dan Gohman
273546fbdc Remove unnecessary #includes.
llvm-svn: 72782
2009-06-03 16:47:12 +00:00
Sanjiv Gupta
ea551a1e7c Emit file directives correctly in case of a .bc is generated by llvm-ld after linking in several .bc files.
llvm-svn: 72781
2009-06-03 16:27:49 +00:00
Torok Edwin
29762633ee lets not forget about c++!
llvm-svn: 72778
2009-06-03 15:42:26 +00:00
Sanjiv Gupta
aa07dba151 FrameIndex could be used as a value (addressof (arg)) or as an address.
Expand it exactly like GlobalAddress.
Fix some more crashes (InsertBranch() not being implemented) for compiling hitec libs.

llvm-svn: 72776
2009-06-03 15:31:12 +00:00
Oscar Fuentes
3a964cbc3b CMake: Added missing source file to lib/CodeGen/CMakeLists.txt.
llvm-svn: 72775
2009-06-03 15:29:09 +00:00
Oscar Fuentes
86f4f18dca CMake: Implements and documents option LLVM_ENABLE_ASSERTS.
llvm-svn: 72774
2009-06-03 15:11:25 +00:00
Torok Edwin
e056d0b8cd Document how easy it is to use the gold plugin and have LTO with autotooled projects.
Please correct the documentation if I missed anything.

llvm-svn: 72773
2009-06-03 15:06:19 +00:00
Sanjiv Gupta
0679a0baee Fixed a bug in which signed comparisons were being used instead of unsigned comparisons.
llvm-svn: 72771
2009-06-03 13:36:44 +00:00
Duncan Sands
ab3e57c63f Avoid a warning "'U' might be used uninitialized in
this function" when using a not-too-smart compiler.

llvm-svn: 72768
2009-06-03 12:05:18 +00:00