Akira Hatanaka
70199b7136
Revert r141932, r141936 and r141937.
...
llvm-svn: 141959
2011-10-14 17:16:39 +00:00
Jim Grosbach
b06728a837
Fix typo. "__sync_fetch_and-xor_4" should be "__sync_fetch_and_xor_4".
...
Pointed out by George Russell.
llvm-svn: 141956
2011-10-14 15:53:48 +00:00
Nick Lewycky
610fc64d78
An instruction's operands aren't necessarily instructions or constants. They
...
could be arguments, for example.
No testcase because this is a bug-fix broken out of a larger optimization patch.
llvm-svn: 141951
2011-10-14 09:38:46 +00:00
Craig Topper
0a11eb1b21
Add X86 ANDN instruction. Including instruction selection.
...
llvm-svn: 141947
2011-10-14 07:06:56 +00:00
Craig Topper
6b2120a8e1
Add X86 TZCNT instruction and patterns to select it. Also added core-avx2 processor which is gcc's name for Haswell.
...
llvm-svn: 141939
2011-10-14 03:21:46 +00:00
Akira Hatanaka
24e913fbe2
Definition of function getMipsRegisterNumbering.
...
Patch by Jack Carter and Reed Kotler at Mips.
llvm-svn: 141938
2011-10-14 03:04:24 +00:00
Akira Hatanaka
516b4b0352
Add definition of class MipsELFWriterInfo.
...
Patch by Jack Carter and Reed Kotler at Mips.
llvm-svn: 141937
2011-10-14 02:55:47 +00:00
Akira Hatanaka
9922f8d014
Add missing relocation types.
...
Patch by Jack Carter and Reed Kotler at Mips.
llvm-svn: 141936
2011-10-14 02:47:50 +00:00
Akira Hatanaka
32fd6013f5
Add ELF relocation types for Mips.
...
Patch by Jack Carter and Reed Kotler at Mips.
llvm-svn: 141935
2011-10-14 02:43:18 +00:00
Akira Hatanaka
b1ede8157d
Fixup enumerations.
...
Patch by Jack Carter at Mips.
llvm-svn: 141934
2011-10-14 02:38:56 +00:00
Akira Hatanaka
a5d655b991
Add more Mips relocation types.
...
Patch by Jack Carter at Mips.
llvm-svn: 141932
2011-10-14 02:17:30 +00:00
Jakob Stoklund Olesen
a31553dbf7
Ban rematerializable instructions with side effects.
...
TableGen infers unmodeled side effects on instructions without a
pattern. Fix some instruction definitions where that was overlooked.
Also raise an error if a rematerializable instruction has unmodeled side
effects. That doen't make any sense.
llvm-svn: 141929
2011-10-14 01:00:49 +00:00
Jakob Stoklund Olesen
d7827f928d
V_SET0 has no side effects.
...
TableGen will mark any pattern-less instruction as having unmodeled side
effects. This is extra bad for V_SET0 which gets rematerialized a lot.
This was part of the cause for PR11125, but the real bug was fixed
in r141923.
llvm-svn: 141924
2011-10-14 00:39:50 +00:00
Jakob Stoklund Olesen
98e48aef6f
Add value numbers when spilling dead defs.
...
When spilling around an instruction with a dead def, remember to add a
value number for the def.
The missing value number wouldn't normally create problems since there
would be an incoming live range as well. However, due to another bug
we could spill a dead V_SET0 instruction which doesn't read any values.
The missing value number caused an empty live range to be created which
is dangerous since it doesn't interfere with anything.
This fixes part of PR11125.
llvm-svn: 141923
2011-10-14 00:34:31 +00:00
Eli Friedman
667bf19c57
Avoid undefined behavior in negation in LSR. Patch by Ahmed Charles.
...
Someone more familiar with LSR should double-check that the extra cast is actually doing the right thing in the overflow cases; I'm not completely confident that's that case.
llvm-svn: 141916
2011-10-13 23:48:33 +00:00
Eli Friedman
94373219c3
Fix undefined shift. Patch by Ahmed Charles.
...
llvm-svn: 141914
2011-10-13 23:36:06 +00:00
Eli Friedman
d1174d008e
Simplify assertion, and avoid undefined shift. Based on patch by Ahmed Charles.
...
llvm-svn: 141912
2011-10-13 23:27:48 +00:00
Michael J. Spencer
5cbe7170de
Support/Windows: Add support modifying memory permissions on Windows. Patch by Aaron Ballman!
...
llvm-svn: 141910
2011-10-13 23:16:01 +00:00
Eli Friedman
219f1841f7
Fix undefined shifts and abs in Alpha backend. Based on patch by Ahmed Charles.
...
llvm-svn: 141909
2011-10-13 23:13:35 +00:00
Michael J. Spencer
1c388c42ea
Support/Windows: Add efficent RW mutex on Windows. Patch by Aaron Ballman!
...
llvm-svn: 141907
2011-10-13 23:10:56 +00:00
Lang Hames
b0db984fab
Fixed typo.
...
llvm-svn: 141906
2011-10-13 23:04:49 +00:00
Eli Friedman
a1d8196452
Avoid undefined behavior in signed integer negation. Patch by Ahmed Charles.
...
llvm-svn: 141905
2011-10-13 22:49:56 +00:00
Eli Friedman
74b48114e3
Simplify and avoid undefined shift. Based on patch by Ahmed Charles.
...
llvm-svn: 141903
2011-10-13 22:40:23 +00:00
Michael J. Spencer
10caa055b0
ELF: Fix the section that relocations apply to. Add test to verify. Patch by Danil Malyshev!
...
llvm-svn: 141901
2011-10-13 22:30:10 +00:00
Michael J. Spencer
4ee36e15ad
llvm-object: Add inline relocation information to disassembly.
...
llvm-svn: 141897
2011-10-13 22:17:18 +00:00
Eli Friedman
e702d68556
Enhance the memdep interface so that users can tell the difference between a dependency which cannot be calculated and a path reaching the entry point of the function. This patch introduces isNonFuncLocal, which replaces isUnknown in some cases.
...
Patch by Xiaoyi Guo.
llvm-svn: 141896
2011-10-13 22:14:57 +00:00
Andrew Trick
923129b028
Reapply r141870, SCEV expansion of post-inc.
...
Speculatively reapply to see if this test case still crashes on
linux. I may have fixed it in my last checkin.
llvm-svn: 141895
2011-10-13 21:55:29 +00:00
Eric Christopher
0ffa8593b3
Don't forget to reconstruct D after changing the scope that we're
...
looking at.
llvm-svn: 141892
2011-10-13 21:43:44 +00:00
Richard Osborne
72a63ff457
Update IntrinsicsXCore.td with the normal LLVM notice at the top of the file.
...
llvm-svn: 141889
2011-10-13 21:08:11 +00:00
Michael J. Spencer
309e0cb513
llvm-objdump: Fix whitespace.
...
llvm-svn: 141886
2011-10-13 20:37:20 +00:00
Michael J. Spencer
fa3f63c14a
llvm-objdump: Fix dumping of multiple symbols with the same address.
...
This happens in COFF because there is a symbol for the beginning of each
section.
llvm-svn: 141885
2011-10-13 20:37:08 +00:00
Michael J. Spencer
9a10012151
COFF: Implement sectionContainsSymbol for relocatable files only.
...
llvm-svn: 141884
2011-10-13 20:36:54 +00:00
Andrew Trick
03cd1b6a5d
Fix memory corruption I introduced a few checkins ago.
...
Self-review easily caught this obvious bug.
llvm-svn: 141880
2011-10-13 18:49:23 +00:00
NAKAMURA Takumi
0a86c2d187
configure: [cygming] Set --disable-embed-stdcxx by default on --enable-shared.
...
Many distros provide stdc++.dll recently. --enable-embed-stdcxx might confuse people.
llvm-svn: 141875
2011-10-13 18:04:52 +00:00
Owen Anderson
9f90e2252c
SETEND is not allowed in an IT block.
...
llvm-svn: 141874
2011-10-13 17:58:39 +00:00
Andrew Trick
109f7dbd1e
Revert r141870. The test case crashes on linux with data corruption. A deeper issue was exposed.
...
llvm-svn: 141873
2011-10-13 17:58:24 +00:00
NAKAMURA Takumi
ca62ac7536
docs/CMake.html: Clarify LLVM_LIT_TOOLS_DIR as :PATH.
...
llvm-svn: 141872
2011-10-13 17:36:02 +00:00
Michael J. Spencer
fe0e806423
Fix incorrect ELF typedefs.
...
llvm-svn: 141871
2011-10-13 17:33:52 +00:00
Andrew Trick
05d7cb17d5
LSR: Reuse the post-inc expansion of expressions.
...
This avoids unnecessary expansion of expressions and allows the SCEV
expander to work on expression DAGs, not just trees.
Fixes PR11090.
llvm-svn: 141870
2011-10-13 17:31:47 +00:00
Daniel Dunbar
86b464dff5
build: Remove some stray LLVMC configure variables.
...
llvm-svn: 141869
2011-10-13 17:27:34 +00:00
Andrew Trick
38d4b87695
SCEV: Rewrite TrandformForPostIncUse to handle expression DAGs, not
...
just expression trees.
Partially fixes PR11090. Test case will be with the full fix.
llvm-svn: 141868
2011-10-13 17:21:09 +00:00
Andrew Trick
5286636188
Slightly more useful tracing.
...
llvm-svn: 141867
2011-10-13 17:06:38 +00:00
Benjamin Kramer
a705595096
Force CPU type on test so it doesn't accidentally emit movbe instead of bswap on Intel Atom CPUs.
...
llvm-svn: 141863
2011-10-13 14:27:54 +00:00
Kalle Raiskila
15993a5d28
Mark 'branch indirect' instruction as an indirect branch.
...
Not having it confused assembly printing of jumptables.
llvm-svn: 141862
2011-10-13 11:40:03 +00:00
Bill Wendling
dcd9c25744
More closely follow libgcc, which has code after the `ret' instruction to
...
release the stack segment and reset the stack pointer. Place the code in its own
MBB to make the verifier happy.
llvm-svn: 141859
2011-10-13 08:24:19 +00:00
Bill Wendling
2a571af745
Revert r141854 because it was causing failures:
...
http://lab.llvm.org:8011/builders/llvm-x86_64-linux/builds/101
--- Reverse-merging r141854 into '.':
U test/MC/Disassembler/X86/x86-32.txt
U test/MC/Disassembler/X86/simple-tests.txt
D test/CodeGen/X86/bmi.ll
U lib/Target/X86/X86InstrInfo.td
U lib/Target/X86/X86ISelLowering.cpp
U lib/Target/X86/X86.td
U lib/Target/X86/X86Subtarget.h
llvm-svn: 141857
2011-10-13 07:48:07 +00:00
Bill Wendling
a6bf25f30a
Should not add instructions to a BB after a return instruction. The machine instruction verifier doesn't like this, nor do I.
...
llvm-svn: 141856
2011-10-13 07:42:32 +00:00
Cameron Zwarich
fcbdff2af3
Use an existing method.
...
llvm-svn: 141855
2011-10-13 07:36:41 +00:00
Craig Topper
eb29e18c9b
Add X86 TZCNT instruction and patterns to select it. Also added core-avx2 processor which is gcc's name for Haswell.
...
llvm-svn: 141854
2011-10-13 07:09:14 +00:00
Craig Topper
0d25fa802f
Add 'implicit EFLAGS' to patterns for popcnt and lzcnt
...
llvm-svn: 141853
2011-10-13 06:18:52 +00:00