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

36865 Commits

Author SHA1 Message Date
Chris Lattner
7bc8284fed simplify some overly general code. The stack always grows down on x86.
llvm-svn: 98431
2010-03-13 08:04:35 +00:00
Benjamin Kramer
3e9e66d9e4 Fix another warning. There is a functionality change but I believe it's correct.
llvm-svn: 98430
2010-03-13 07:50:22 +00:00
Chris Lattner
ade5faaac4 factor some labels, simplify some code.
llvm-svn: 98429
2010-03-13 07:40:56 +00:00
Bob Wilson
163aa28fa1 Attempt to appease the arm-linux buildbot by fixing the JIT encodings for new
base register updating load/store-multiple instructions.

llvm-svn: 98427
2010-03-13 07:34:35 +00:00
Chris Lattner
836e8b5d1b various cleanups.
llvm-svn: 98426
2010-03-13 07:26:18 +00:00
Daniel Dunbar
e8b67adb94 MC/Mach-O: PCrel relocations weren't using the right base address, they are
relative to the fragment address, not its offset. This was masked by the text
section normally being at address 0.

llvm-svn: 98420
2010-03-13 02:38:00 +00:00
Daniel Dunbar
33c92a1a88 llvm-mc: Support -n, useful for comparing -integrated-as output since the
compiler may not lead with the text section.

llvm-svn: 98418
2010-03-13 02:20:57 +00:00
Evan Cheng
34c5c9af6f Fix a typo in ValueTracking that's causing instcombine to delete needed shift instructions.
llvm-svn: 98416
2010-03-13 02:20:29 +00:00
Chris Lattner
bfdbd2f3a2 reimplement the string pool used for inlined function
entries to not thrash std::strings and MCSymbols.

llvm-svn: 98415
2010-03-13 02:17:42 +00:00
Chris Lattner
14eafddc99 switch to the text section at the start of the .s file for darwin/x86
targets.  This is a temporary hack for the .o file writer that Daniel
wants :)

llvm-svn: 98413
2010-03-13 02:10:00 +00:00
Jeffrey Yasskin
819ce89d8f Delete MDNodes when LLVMContext is destroyed. Previous attempts: r97918, r97788.
Tested: clang debug bootstrap, llvm-gcc bootstrap, `make check-lit`
after configuring with --with-llvmgccdir (and this did run the
FrontendC* tests this time)

llvm-svn: 98410
2010-03-13 01:26:15 +00:00
Bob Wilson
0e8a3d7a13 Change ARM ld/st multiple instructions to have variant instructions for
writebacks to the address register.  This gets rid of the hack that the
first register on the list was the magic writeback register operand.  There
was an implicit constraint that if that operand was not reg0 it had to match
the base register operand.  The post-RA scheduler's antidependency breaker
did not understand that constraint and sometimes changed one without the
other.  This also fixes Radar 7495976 and should help the verifier work
better for ARM code.

There are now new ld/st instructions explicit writeback operands and explicit
constraints that tie those registers together.

llvm-svn: 98409
2010-03-13 01:08:20 +00:00
Devang Patel
e0b931e0ed Do not ignore arg_size() impact while counting bb instructions.
llvm-svn: 98408
2010-03-13 01:05:02 +00:00
Daniel Dunbar
9ffe22ec23 MC/X86: Add temporary hack to match shrl $1,%eax correctly, to support testing
other functionality on 403.gcc compiled at -O0.

llvm-svn: 98405
2010-03-13 00:47:29 +00:00
Devang Patel
40477c7760 Remove extra parameter.
llvm-svn: 98403
2010-03-13 00:45:31 +00:00
Bob Wilson
99388e001e Combine the code to build VLDM and VSTM instructions, since they are
mostly the same.

llvm-svn: 98402
2010-03-13 00:43:32 +00:00
Devang Patel
882e43e3cc Do not overestimate code size reduction in presense of debug info.
Use CodeMetrics.analyzeBasicBlock() to estimate BB size.

llvm-svn: 98401
2010-03-13 00:10:20 +00:00
Bob Wilson
a9130d7c7d Tidy up. No functional changes.
llvm-svn: 98398
2010-03-12 22:50:09 +00:00
Daniel Dunbar
8ad9589475 MC/Mach-O: Implement initial support for relaxation.
- The implementation is currently very brain dead and inefficient, but I have a
   clear plan on how to fix it.

 - The good news is, it works and correctly assembles 403.gcc (when built with
   Clang, at '-Os', '-Os -g', and '-O3'). Even better, at '-Os' and '-Os -g',
   the resulting binary is exactly equivalent to that when built with the system
   assembler. So it probably works! :)

llvm-svn: 98396
2010-03-12 22:07:14 +00:00
Bob Wilson
41bb0dca48 Remove obsolete comments. VLDM is implemented in ARMInstrVFP.td.
llvm-svn: 98395
2010-03-12 22:00:08 +00:00
Jeffrey Yasskin
876e602378 Fix LLVM build when the user specifies CPPFLAGS on the make command line.
llvm-svn: 98394
2010-03-12 21:42:14 +00:00
Chris Lattner
14ab9784f4 remove gone method, grr symlinks.
llvm-svn: 98392
2010-03-12 21:30:49 +00:00
Chris Lattner
4d7171c334 remove special case code that isn't needed anymore.
llvm-svn: 98391
2010-03-12 21:21:19 +00:00
Chris Lattner
5a5ea25649 inline GetGlobalValueSymbol into the rest its callers and
remove it.

llvm-svn: 98390
2010-03-12 21:19:23 +00:00
Chris Lattner
7a2e6110bc inline the now-trivial implementation of GetGlobalValueSymbol into
some of its callers.

llvm-svn: 98388
2010-03-12 21:09:07 +00:00
Chris Lattner
33f470bec2 eliminate the X86 version of GetGlobalValueSymbol, allowing
it to be non-virtual and soon disappear.

llvm-svn: 98387
2010-03-12 21:06:41 +00:00
Chris Lattner
41dbe0a1bd prune #includes, this file should be removed pending hte cygwin stub issue being resolved.
llvm-svn: 98386
2010-03-12 21:04:31 +00:00
Chris Lattner
ff05ae7a33 move fastcall/stdcall mangling up into Mangler.
llvm-svn: 98384
2010-03-12 21:03:47 +00:00
Daniel Dunbar
642fbbe84d MC: Factor out MCAssembler::EvaluateFixup, and simplify.
llvm-svn: 98381
2010-03-12 21:00:49 +00:00
Daniel Dunbar
14b9ff70e1 MC: Constify MCAsmLayout argument to MCExpr::EvaluteAs...
llvm-svn: 98380
2010-03-12 21:00:45 +00:00
Daniel Dunbar
71473e6b15 MC: Add MCAssembler::addFixup, which enforces that fixups are added in order.
llvm-svn: 98379
2010-03-12 21:00:38 +00:00
Chris Lattner
c101ad818c give Mangler access to TargetData.
llvm-svn: 98378
2010-03-12 20:47:28 +00:00
Chris Lattner
5611fd3bc7 make DecorateCygMingName a static method.
llvm-svn: 98377
2010-03-12 20:43:52 +00:00
Benjamin Kramer
19c12c8ef4 Add a virtual destructor and give vtable a home.
llvm-svn: 98376
2010-03-12 20:41:29 +00:00
Chris Lattner
4781fd7ca5 minor tidying, only do work if a function is
actually X86_StdCall or X86_FastCall.

llvm-svn: 98374
2010-03-12 19:48:03 +00:00
Chris Lattner
63328f1348 eliminate the string form of DecorateCygMingName
llvm-svn: 98373
2010-03-12 19:42:40 +00:00
Chris Lattner
2fd7c89502 remove the FnArgWords cache to make way for future changes.
llvm-svn: 98372
2010-03-12 19:31:03 +00:00
Bill Wendling
21a9744045 Add a beta-test for placing the LSDA into the TEXT section on X86.
llvm-svn: 98370
2010-03-12 19:20:40 +00:00
Devang Patel
04d151f5a6 Fix llc crash on invalid input.
llvm-svn: 98369
2010-03-12 19:18:30 +00:00
Chris Lattner
741b3e4e5f Remove some dead code. This method only gets called on
definitions.

llvm-svn: 98368
2010-03-12 19:14:18 +00:00
Chris Lattner
0bcd93798a use Mang->getSymbol instead of duplicating the logic, reduce indentation.
llvm-svn: 98367
2010-03-12 19:04:14 +00:00
Chris Lattner
01e70df9b2 finally give Mangler a getSymbol method, which returns an MCSymbol
for a global instead of messing around with string buffers.

llvm-svn: 98366
2010-03-12 18:55:20 +00:00
Chris Lattner
04cd48f865 remove dead code.
llvm-svn: 98365
2010-03-12 18:49:32 +00:00
Chris Lattner
683801add5 simplify code to use OutContext.GetOrCreateTemporarySymbol with
no arguments instead of having to come up with a unique name.
This also makes the code less fragile.

llvm-svn: 98364
2010-03-12 18:47:50 +00:00
Chris Lattner
956582f876 make the mangler take an MCContext instead of an MAI.
No functionality change.

llvm-svn: 98363
2010-03-12 18:44:54 +00:00
Chris Lattner
f4dce6a6d8 remove MAI argument from createAsmStreamer since it
can get it from the context now.

llvm-svn: 98361
2010-03-12 18:28:53 +00:00
Chris Lattner
4cc9a9004f fix a bug emitting .secrel32 that I introduced, PR6587, patch
by A.Mazur!

llvm-svn: 98360
2010-03-12 18:10:35 +00:00
Duncan Sands
01532e804a When constant folding GEP of GEP, do not crash if an index of
the inner GEP is not a ConstantInt.

llvm-svn: 98359
2010-03-12 17:55:20 +00:00
Jeffrey Yasskin
824bd1b30d Free DbgScopes in DwarfDebug::endFunction(). Also increased the const-ness of
several fields to make it easier to figure out where bugs might be creeping in.

llvm-svn: 98358
2010-03-12 17:45:06 +00:00
Duncan Sands
086a80eee3 Revert turning copysignl into a COPYSIGN node for the moment:
ppc calls copysignl with a 128 bit ppc long double, resulting
in a node that the type legalizer doesn't know how to expand.

llvm-svn: 98357
2010-03-12 17:41:34 +00:00