Bob Wilson
20c65a9d33
The Thumb tADDrSPi instruction is not valid when the destination is SP.
...
Check for that and try narrowing it to tADDspi instead. Radar 8724703.
llvm-svn: 120892
2010-12-04 04:40:19 +00:00
Rafael Espindola
9215947c83
There are two reasons why we might want to use
...
foo = a - b
.long foo
instead of just
.long a - b
First, on darwin9 64 bits the assembler produces the wrong result. Second,
if "a" is the end of the section all darwin assemblers (9, 10 and mc) will not
consider a - b to be a constant but will if the dummy foo is created.
Split how we handle these cases. The first one is something MC should take care
of. The second one has to be handled by the caller.
llvm-svn: 120889
2010-12-04 03:21:47 +00:00
Rafael Espindola
50b6170457
Next step: Only pad debug_line when the target is darwin. Add a FIXME to avoid
...
doing that if the target is darwin10 or newer.
This fixes
*) Direct object emission was producing objects without the workaround on
darwin9.
*) Assembly printing was producing objects with the workaround on linux.
llvm-svn: 120866
2010-12-04 00:31:13 +00:00
Jim Grosbach
8cef570ed9
Encode the 32-bit wide Thumb (and Thumb2) instructions with the high order
...
halfword being emitted to the stream first. rdar://8728174
llvm-svn: 120848
2010-12-03 22:31:40 +00:00
Jim Grosbach
c69ad2176a
When using the 'push' mnemonic for Thumb2 stmdb, be explicit when it's the
...
32-bit wide version by adding the .w suffix.
llvm-svn: 120838
2010-12-03 20:33:01 +00:00
Devang Patel
dad3193123
Hide tests, that check .loc, .file in output assembly, from darwin9 buildbot.
...
llvm-svn: 120750
2010-12-02 23:29:58 +00:00
Devang Patel
822facd787
Use set directive for StartMinusEndExpr.
...
This is a fix for llvm-gcc-i386-darwin9 buildbot failure.
llvm-svn: 120742
2010-12-02 21:32:30 +00:00
Stuart Hastings
55928bc576
Test case for r120740. Radar 8712503.
...
llvm-svn: 120741
2010-12-02 21:25:55 +00:00
Duncan Sands
b38ddd79ed
Adjust this test for the fact that the stores are no longer
...
being combined (which is being tracked as PR8699).
llvm-svn: 120734
2010-12-02 20:56:51 +00:00
Jim Grosbach
5a94ed2d67
XFAIL for now. If someone with access to an ARM/Linux host wants to have a look
...
that would be great. They're ARM JIT failures, so without that, it's tough.
llvm-svn: 120731
2010-12-02 20:20:32 +00:00
Evan Cheng
402157b66e
Fix test.
...
llvm-svn: 120730
2010-12-02 20:17:34 +00:00
Duncan Sands
84bd43844e
This test dates from the time when llvm-gcc had problems if two types were
...
named the same, so it had to qualify type names according to the enclosing
scope to ensure uniqueness. This is no longer needed for correctness (though
it may be helpful when reading the IR), so this test has lost its importance.
Zap it because dragonegg will never be able to produce the qualified type name
since modern gcc zaps language specific info (such as whether a type is nested
inside another - needed to get X::Y here) before dragonegg is reached.
llvm-svn: 120721
2010-12-02 18:19:23 +00:00
NAKAMURA Takumi
f8cc69a131
test/Archive/extract.ll: Use cmp instead of diff. Thanks to Danil Malyshev!
...
llvm-svn: 120698
2010-12-02 09:16:14 +00:00
Evan Cheng
4118b24aca
Fix and re-enable tail call optimization of expanded libcalls.
...
llvm-svn: 120622
2010-12-01 22:59:46 +00:00
Rafael Espindola
16b64c646a
Rename temporary symbols if they conflict with artificial symbols created
...
by the assembler. This was blocking parsing any large .s produced by clang for
example.
Fixes PR8596.
llvm-svn: 120603
2010-12-01 20:46:11 +00:00
Owen Anderson
8802c68592
Add correct encodings for STRD and LDRD, including fixup support. Additionally, update these to unified syntax.
...
llvm-svn: 120589
2010-12-01 19:18:46 +00:00
Evan Cheng
84162760b7
Speculatively disable x86 portion of r120501 to appease the x86_64 buildbot.
...
llvm-svn: 120549
2010-12-01 03:27:20 +00:00
Jason W Kim
4d960e071c
ARM/MC/ELF relocation "hello world" for movw/movt.
...
Lifted adjustFixupValue() from Darwin for sharing w ELF.
Test added
TODO:
refactor ELFObjectWriter::RecordRelocation more.
Possibly share more code with Darwin?
Lots more relocations...
llvm-svn: 120534
2010-12-01 02:40:06 +00:00
Chris Lattner
c3112f1e94
fix a bozo bug I introduced in r119930, causing a miscompile of
...
20040709-1.c from the gcc testsuite. I was using the size of a
pointer instead of the pointee. This fixes rdar://8713376
llvm-svn: 120519
2010-12-01 01:24:55 +00:00
NAKAMURA Takumi
ffb10289fb
test/Archive: FileCheck-ize, and remove *.toc. These may be CRLF-tolerant.
...
llvm-svn: 120506
2010-12-01 00:09:25 +00:00
Evan Cheng
f7e586d749
Enable sibling call optimization of libcalls which are expanded during
...
legalization time. Since at legalization time there is no mapping from
SDNode back to the corresponding LLVM instruction and the return
SDNode is target specific, this requires a target hook to check for
eligibility. Only x86 and ARM support this form of sibcall optimization
right now.
rdar://8707777
llvm-svn: 120501
2010-11-30 23:55:39 +00:00
Chris Lattner
c888f3ec58
Enhance DSE to handle the variable index case in PR8657.
...
llvm-svn: 120498
2010-11-30 23:43:23 +00:00
Chris Lattner
191aa08db1
remove fixme comment too.
...
llvm-svn: 120493
2010-11-30 23:25:01 +00:00
Chris Lattner
eee2bb2ff0
check in *all* files. This is now handled by my previous DSE commit.
...
llvm-svn: 120492
2010-11-30 23:23:59 +00:00
Chris Lattner
b9c5a6fa04
teach DSE to use GetPointerBaseWithConstantOffset to analyze
...
may-aliasing stores that partially overlap with different base
pointers. This implements PR6043 and the non-variable part of
PR8657
llvm-svn: 120485
2010-11-30 23:05:20 +00:00
Chris Lattner
41b6b286a3
enhance isRemovable to refuse to delete volatile mem transfers
...
now that DSE hacks on them. This fixes a regression I introduced,
by generalizing DSE to hack on transfers.
llvm-svn: 120445
2010-11-30 19:12:10 +00:00
Owen Anderson
e2a8781847
Add tests for more forms of Thumb2 loads and stores.
...
llvm-svn: 120436
2010-11-30 18:15:21 +00:00
Che-Liang Chiou
f594fe5fc5
ptx: add command-line options for gpu target and ptx version
...
llvm-svn: 120423
2010-11-30 10:14:14 +00:00
Eric Christopher
990bcd83b8
Not all platforms use _<func>. Duh.
...
llvm-svn: 120418
2010-11-30 09:23:54 +00:00
Bill Wendling
ae920bcc50
Add parsing for the Thumb t_addrmode_s4 addressing mode. This can almost
...
certainly be made more generic. But it does allow us to parse something like:
ldr r3, [r2, r4]
correctly in Thumb mode.
llvm-svn: 120408
2010-11-30 07:44:32 +00:00
Chris Lattner
7d444d0682
Rewrite the main DSE loop to be written in terms of reasoning
...
about pairs of AA::Location's instead of looking for MemDep's
"Def" predicate. This is more powerful and general, handling
memset/memcpy/store all uniformly, and implementing PR8701 and
probably obsoleting parts of memcpyoptimizer.
This also fixes an obscure bug with init.trampoline and i8
stores, but I'm not surprised it hasn't been hit yet. Enhancing
init.trampoline to carry the size that it stores would allow
DSE to be much more aggressive about optimizing them.
llvm-svn: 120406
2010-11-30 07:23:21 +00:00
Eric Christopher
f27f0b5234
Rewrite mwait and monitor support and custom lower arguments.
...
Fixes PR8573.
llvm-svn: 120404
2010-11-30 07:20:12 +00:00
Anders Carlsson
67e9e6234c
Add a puts optimization that converts puts() to putchar('\n').
...
llvm-svn: 120398
2010-11-30 06:19:18 +00:00
Anders Carlsson
2a46a03898
Fix a typo.
...
llvm-svn: 120394
2010-11-30 06:03:55 +00:00
Anders Carlsson
a2ad88fb73
Rename this test to FPuts.ll since it actually tests fputs.
...
llvm-svn: 120393
2010-11-30 05:59:26 +00:00
Chris Lattner
bea813875e
remove a use of llvm-dis
...
llvm-svn: 120383
2010-11-30 02:04:15 +00:00
Chris Lattner
56b0cc6974
merge one more away
...
llvm-svn: 120375
2010-11-30 01:06:43 +00:00
Chris Lattner
8e2909e4d8
I already merged partial-overwrite.ll -> PartialStore.ll
...
Merge context-sensitive.ll -> simple.ll and upgrade it.
llvm-svn: 120374
2010-11-30 01:05:07 +00:00
Chris Lattner
496eacefab
clean up DSE tests, removing some poorly reduced and useless old test,
...
merging more into other larger .ll files, filecheckizing along the way.
llvm-svn: 120373
2010-11-30 01:00:34 +00:00
Chris Lattner
083731f3d6
enhance basicaa to return "Mod" for a memcpy call when the
...
queried location doesn't overlap the source, and add a testcase.
llvm-svn: 120370
2010-11-30 00:43:16 +00:00
Chris Lattner
8ec1830a01
Teach basicaa that memset's modref set is at worst "mod" and never
...
contains "ref".
Enhance DSE to use a modref query instead of a store-specific hack
to generalize the "ignore may-alias stores" optimization to handle
memset and memcpy.
llvm-svn: 120368
2010-11-30 00:28:45 +00:00
Owen Anderson
b6e1c56c79
Correct Thumb2 encodings for a much wider range of loads and stores.
...
llvm-svn: 120364
2010-11-30 00:14:31 +00:00
Chris Lattner
975dcf5ac8
my previous patch would cause us to start deleting some volatile
...
stores, fix and add a testcase.
llvm-svn: 120363
2010-11-30 00:12:39 +00:00
Bob Wilson
bd3d3d2937
Add support for NEON VLD3-dup instructions.
...
The encoding for alignment in VLD4-dup instructions is still a work in progress.
llvm-svn: 120356
2010-11-30 00:00:35 +00:00
Owen Anderson
14abbb1a2e
Provide Thumb2 encodings for basic loads and stores.
...
llvm-svn: 120340
2010-11-29 22:44:32 +00:00
Evan Cheng
78baa6f30d
Mark Darwin call instructions as using "r7" to prevent the frame-register
...
assignment instructions from being moved below / above calls.
rdar://8690640
llvm-svn: 120339
2010-11-29 22:43:27 +00:00
Benjamin Kramer
af5a57ca66
Add missing colon.
...
llvm-svn: 120336
2010-11-29 22:39:38 +00:00
Benjamin Kramer
84bf47f2d8
Fix some broken CHECK lines.
...
llvm-svn: 120332
2010-11-29 22:34:55 +00:00
Chris Lattner
2f8a9e1eac
fix PR8677, patch by Jakub Staszak!
...
llvm-svn: 120325
2010-11-29 21:59:31 +00:00
Frits van Bommel
a59a8cf49f
Transform (extractvalue (load P), ...) to (load (gep P, 0, ...)) if the load has no other uses, shrinking the load.
...
llvm-svn: 120323
2010-11-29 21:56:20 +00:00