Benjamin Kramer
1cb826b0ad
Clean up HiPE prologue emission a bit and avoid signed arithmetic tricks.
...
No intended functionality change.
llvm-svn: 175536
2013-02-19 17:32:57 +00:00
Rafael Espindola
1c040b5788
Move LLVM_LIBRARY_VISIBILITY for consistency with what was done to
...
PPCJITInfo.cpp in r175394.
llvm-svn: 175531
2013-02-19 17:14:33 +00:00
Eli Bendersky
b0b13b22a3
Make pass name more precise and fix comment.
...
llvm-svn: 175525
2013-02-19 16:38:32 +00:00
Craig Topper
f371e89264
Fix capitalization in comment to match function name.
...
llvm-svn: 175497
2013-02-19 07:43:59 +00:00
Jakub Staszak
1f199a0ef2
Use array_pod_sort instead of std::sort.
...
llvm-svn: 175472
2013-02-18 23:18:22 +00:00
NAKAMURA Takumi
3a8002f61d
X86FrameLowering.cpp: Fixup. Sorry for the breakage.
...
llvm-svn: 175467
2013-02-18 23:15:21 +00:00
NAKAMURA Takumi
a614ec7e6f
X86FrameLowering.cpp: Fix a warning in -Asserts. [-Wunused-variable]
...
llvm-svn: 175464
2013-02-18 23:08:49 +00:00
Chad Rosier
441e81287f
Remove a useless assert.
...
llvm-svn: 175463
2013-02-18 22:20:16 +00:00
Benjamin Kramer
5c6e653b72
Fix a 32/64 bit incompatibility in the HiPE prologue generation.
...
llvm-svn: 175458
2013-02-18 21:45:01 +00:00
Benjamin Kramer
53bc37ca2a
Support for HiPE-compatible code emission, patch by Yiannis Tsiouris.
...
llvm-svn: 175457
2013-02-18 20:55:12 +00:00
Benjamin Kramer
189fc5819a
X86: Add a note.
...
llvm-svn: 175408
2013-02-17 23:34:14 +00:00
Jakub Staszak
74010cd9c2
Return false instead of 0.
...
llvm-svn: 175402
2013-02-17 18:35:25 +00:00
NAKAMURA Takumi
f86d12caf0
[msvc x64] Update X86CompilationCallback_Win64.asm corresponding to r175267.
...
llvm-svn: 175363
2013-02-16 16:04:29 +00:00
Jakub Staszak
d784d96074
Minor cleanups. No functionality change.
...
llvm-svn: 175359
2013-02-16 13:34:26 +00:00
Bill Wendling
61375d8953
Reinitialize the ivars in the subtarget so that they can be reset with the new features.
...
llvm-svn: 175336
2013-02-16 01:36:26 +00:00
Chad Rosier
925c9b499e
[ms-inline asm] Do not omit the frame pointer if we have ms-inline assembly.
...
If the frame pointer is omitted, and any stack changes occur in the inline
assembly, e.g.: "pusha", then any C local variable or C argument references
will be incorrect.
I pass no judgement on anyone who would do such a thing. ;)
rdar://13218191
llvm-svn: 175334
2013-02-16 01:25:28 +00:00
Bill Wendling
e9434778f7
Temporary revert of 175320.
...
llvm-svn: 175322
2013-02-15 23:22:32 +00:00
Bill Wendling
a060d0efd8
Reinitialize the ivars in the subtarget.
...
When we're recalculating the feature set of the subtarget, we need to have the
ivars in their initial state.
llvm-svn: 175320
2013-02-15 23:18:01 +00:00
Bill Wendling
aef9c37c65
Use the 'target-features' and 'target-cpu' attributes to reset the subtarget features.
...
If two functions require different features (e.g., `-mno-sse' vs. `-msse') then
we want to honor that, especially during LTO. We can do that by resetting the
subtarget's features depending upon the 'target-feature' attribute.
llvm-svn: 175314
2013-02-15 22:31:27 +00:00
Chad Rosier
a915bbf4a1
[ms-inline asm] Adjust the EndLoc to account for the ']'.
...
llvm-svn: 175312
2013-02-15 21:58:13 +00:00
Rafael Espindola
91cbcbb909
Give these callbacks hidden visibility. It is better to not export them more
...
than we need to and some ELF linkers complain about directly accessing symbols
with default visibility.
llvm-svn: 175268
2013-02-15 14:15:59 +00:00
Rafael Espindola
9b7d4004bc
Don't make assumptions about the mangling of static functions in extern "C"
...
blocks. We still don't have consensus if we should try to change clang or
the standard, but llvm should work with compilers that implement the current
standard and mangle those functions.
llvm-svn: 175267
2013-02-15 14:08:43 +00:00
Benjamin Kramer
6ecb1e78a9
Make helpers static. Add missing include so LLVMInitializeObjCARCOpts gets C linkage.
...
llvm-svn: 175264
2013-02-15 12:30:38 +00:00
Eli Bendersky
a1c6635ca3
The operand listing is very much outdated.
...
llvm-svn: 175220
2013-02-14 23:17:03 +00:00
Jakub Staszak
701cc97e92
Simplify code. Remove "else after return".
...
llvm-svn: 175212
2013-02-14 21:50:09 +00:00
Kay Tiong Khoo
f809c6491d
added basic support for Intel ADX instructions
...
-feature flag, instructions definitions, test cases
llvm-svn: 175196
2013-02-14 19:08:21 +00:00
Nadav Rotem
accb0c747c
80-col
...
llvm-svn: 175189
2013-02-14 18:20:48 +00:00
Elena Demikhovsky
d0a0cc80cd
Fixed a bug in X86TargetLowering::LowerVectorIntExtend() (assertion failure).
...
Added a test.
llvm-svn: 175144
2013-02-14 08:20:26 +00:00
Rafael Espindola
8868faac14
Revert r175120 and r175121. Clang is producing the expected asm names again.
...
llvm-svn: 175133
2013-02-14 03:33:34 +00:00
Rafael Espindola
3c818086f2
Don't assume the mangling of static functions.
...
llvm-svn: 175121
2013-02-14 02:49:18 +00:00
Nick Lewycky
beba972659
Don't build tail calls to functions with three inreg arguments on x86-32 PIC.
...
Fixes PR15250!
llvm-svn: 175092
2013-02-13 21:59:15 +00:00
Chad Rosier
282edd7caa
[ms-inline-asm] Add support for memory references that have non-immediate
...
displacements.
rdar://12974533
llvm-svn: 175083
2013-02-13 21:33:44 +00:00
Benjamin Kramer
8e2637e2b0
X86: Disable generation of rep;movsl when %esi is used as a base pointer.
...
This happens when there is both stack realignment and a dynamic alloca in the
function. If we overwrite %esi (rep;movsl uses fixed registers) we'll lose the
base pointer and the next register spill will write into oblivion.
Fixes PR15249 and unbreaks firefox on i386/freebsd. Mozilla uses dynamic allocas
and freebsd a 4 byte stack alignment.
llvm-svn: 175057
2013-02-13 13:40:35 +00:00
Elena Demikhovsky
9e0df7cb01
Prevent insertion of "vzeroupper" before call that preserves YMM registers, since a caller uses preserved registers across the call.
...
llvm-svn: 175043
2013-02-13 08:02:04 +00:00
Eric Christopher
389ee71b0a
Check i1 as well as i8 variables for 8 bit registers for x86 inline
...
assembly.
llvm-svn: 175036
2013-02-13 06:01:05 +00:00
Kay Tiong Khoo
ab588efe42
Added 0x0D to 2-byte opcode extension table for prefetch* variants
...
Fixed decode of existing 3dNow prefetchw instruction
Intel is scheduled to add a compatible prefetchw (same encoding) to future CPUs
llvm-svn: 174920
2013-02-12 00:19:12 +00:00
Kay Tiong Khoo
d30b1a2ac7
*fixed disassembly of some i386 system insts with intel syntax
...
*added file for test cases for i386 intel syntax
llvm-svn: 174900
2013-02-11 19:46:36 +00:00
Eli Bendersky
ef4558abd3
This is a follow-up on r174446, now taking Atom processors into
...
account. Atoms use LEA for updating SP in prologs/epilogs, and the
exact LEA opcode depends on the data model.
Also reapplying the test case which was added and then reverted
(because of Atom failures), this time specifying explicitly the CPU in
addition to the triple. The test case now checks all variations (data
mode, cpu Atom vs. Core).
llvm-svn: 174542
2013-02-06 20:43:57 +00:00
Eli Bendersky
44a40ca143
Make sure the correct opcodes are used to SUB and ADD the stack
...
pointer in function prologs/epilogs. The opcodes should depend on the
data model (LP64 vs. ILP32) rather than the architecture bit-ness.
llvm-svn: 174446
2013-02-05 21:53:29 +00:00
Jakob Stoklund Olesen
dc69f6fbca
Move MRI liveouts to X86 return instructions.
...
llvm-svn: 174402
2013-02-05 17:59:48 +00:00
Eli Bendersky
530a3bc5fa
Fix comments
...
llvm-svn: 174390
2013-02-05 16:53:11 +00:00
Benjamin Kramer
2c9da989c2
X86: Open up some opportunities for constant folding by postponing shift lowering.
...
Fixes PR15141.
llvm-svn: 174327
2013-02-04 15:19:33 +00:00
Benjamin Kramer
0611298446
X86: Simplify code. No functionality change.
...
llvm-svn: 174326
2013-02-04 15:19:25 +00:00
Evgeniy Stepanov
1f5a71492d
More MSan/ASan annotations.
...
This change lets us bootstrap LLVM/Clang under ASan and MSan. It contains
fixes for 2 issues:
- X86JIT reads return address from stack, which MSan does not know is
initialized.
- bugpoint tests run binaries with RLIMIT_AS. This does not work with certain
Sanitizers.
We are no longer including config.h in Compiler.h with this change.
llvm-svn: 174306
2013-02-04 07:03:24 +00:00
David Sehr
8114a7a651
Two changes relevant to LEA and x32:
...
1) allows the use of RIP-relative addressing in 32-bit LEA instructions under
x86-64 (ILP32 and LP64)
2) separates the size of address registers in 64-bit LEA instructions from
control by ILP32/LP64.
llvm-svn: 174208
2013-02-01 19:28:09 +00:00
Chad Rosier
df782d2225
[PEI] Pass the frame index operand number to the eliminateFrameIndex function.
...
Each target implementation was needlessly recomputing the index.
Part of rdar://13076458
llvm-svn: 174083
2013-01-31 20:02:54 +00:00
Eric Christopher
258c867c0b
Whitespace.
...
llvm-svn: 174009
2013-01-31 00:50:48 +00:00
Eric Christopher
4e3e94c13d
Check and allow floating point registers to select the size of the
...
register for inline asm. This conforms to how gcc allows for effective
casting of inputs into gprs (fprs is already handled).
llvm-svn: 174008
2013-01-31 00:50:46 +00:00
Evan Cheng
d2ca4e2ed9
Restrict sin/cos optimization to 64-bit only for now. 32-bit is a bit messy and less critical.
...
llvm-svn: 173987
2013-01-30 22:56:35 +00:00
Evan Cheng
27e41c9f70
Remove dead code.
...
llvm-svn: 173812
2013-01-29 18:08:22 +00:00