Jakob Stoklund Olesen
c58894bc36
Add a RegisterClassInfo class that lazily caches information about
...
register classes.
It provides information for each register class that cannot be
determined statically, like:
- The number of allocatable registers in a class after filtering out the
reserved and invalid registers.
- The preferred allocation order with registers that overlap callee-saved
registers last.
- The last callee-saved register that overlaps a given physical register.
This information usually doesn't change between functions, so it is
reused for compiling multiple functions when possible. The many
possible combinations of reserved and callee saves registers makes it
unfeasible to compute this information statically in TableGen.
Use RegisterClassInfo to count available registers in various heuristics
in SimpleRegisterCoalescing, making the pass run 4% faster.
llvm-svn: 132450
2011-06-02 02:19:35 +00:00
Greg Clayton
a13ad2adcf
Use the correct accessor on CXXRecordDecl to know when a C++ class is dynamic.
...
llvm-svn: 132449
2011-06-02 01:26:44 +00:00
Akira Hatanaka
2446869410
Detect FI|cst pattern in MipsDAGToDAGISel::SelectAddr. Patch by Sasa Stankovic.
...
llvm-svn: 132448
2011-06-02 01:03:14 +00:00
Francois Pichet
fbf7e173d2
Fix 80-column violation.
...
llvm-svn: 132447
2011-06-02 00:47:27 +00:00
Eli Friedman
4e2cefffd5
Revert r132426; this test passes more often than not, and we don't have a way to mark tests as intermittently failing at the moment.
...
llvm-svn: 132446
2011-06-02 00:42:47 +00:00
Akira Hatanaka
d84c76f2a7
Test case for r132444.
...
llvm-svn: 132445
2011-06-02 00:25:53 +00:00
Akira Hatanaka
6627752050
Custom-lower FRAMEADDR. Patch by Sasa Stankovic.
...
llvm-svn: 132444
2011-06-02 00:24:44 +00:00
Akira Hatanaka
b579fe5f15
Add stuff for o32 ABI conformance.
...
llvm-svn: 132443
2011-06-02 00:09:17 +00:00
Eli Friedman
b576b1675c
When marking a block as being unanalyzable, use "Clobber" on the terminator instead of the first instruction in the block. This is a bit of a hack; "Clobber" isn't really the right marking in the first place. memdep doesn't really have any way of properly expressing "unanalyzable" at the moment. Using it on the terminator is much less ambiguous than using it on an arbitrary instruction, though.
...
In the given testcase, the "Clobber" was pointing to a load, and GVN was incorrectly assuming that meant that the "Clobber" load overlapped the load being analyzed (when they are actually unrelated).
The included testcase tests both this commit and r132434.
Part two of rdar://9429882. (r132434 was mislabeled.)
llvm-svn: 132442
2011-06-02 00:08:52 +00:00
Johnny Chen
f7626eff37
Turn off printing of command sent to the pexpect-spawned child process to make the script more robotic.
...
llvm-svn: 132441
2011-06-01 23:53:57 +00:00
Jim Ingham
190b959273
If somebody has deleted the breakpoint while we are testing the condition, then just continue.
...
llvm-svn: 132440
2011-06-01 23:52:47 +00:00
Jim Ingham
b7bac4a50e
Remove the "a.out" argument from somewhere on Greg's machine in the lldb-tool run scheme.
...
llvm-svn: 132439
2011-06-01 23:52:04 +00:00
Johnny Chen
1dba2230b5
Exercise the 'thread backtrace all' command instead of the currently 'thread backtrace' command.
...
This serves as a regression test against rdar://problem/9530511.
llvm-svn: 132438
2011-06-01 23:35:20 +00:00
Chad Rosier
6ded76be9c
Typos.
...
llvm-svn: 132437
2011-06-01 23:32:40 +00:00
Johnny Chen
f2ddc71310
The 'thread backtrace all' logical branch had the if (thread->GetStatus()) condition inverted.
...
rdar://problem/9530511
llvm-svn: 132435
2011-06-01 23:19:52 +00:00
Eli Friedman
4b6eeb9ca2
In MemoryDependenceAnalysis::getNonLocalPointerDepFromBB, if a given block is is deemed unanalyzable (and we execute one of the "goto PredTranslationFailure" statements), make sure we don't put information about the predecessors of that block into the returned data structures; this can lead to, among other things, extraneous results (which will confuse passes using memdep). Fixes an assert in GVN compiling ruby. Part of rdar://problem/9521954 .
...
Testcase coming up soon.
llvm-svn: 132434
2011-06-01 23:16:53 +00:00
Devang Patel
e7181b5fdb
A DBG_VALUE that truncates a range does not start another dbg value range.
...
llvm-svn: 132433
2011-06-01 23:00:17 +00:00
Douglas Gregor
7e51117db2
Improve the readability of the "Expressive Diagnostics" page, from Dave Yost!
...
llvm-svn: 132432
2011-06-01 22:45:49 +00:00
Douglas Gregor
b32e825ae4
Fix an incorrect warning about explicit template specializations for
...
nested types, from Michael Han!
llvm-svn: 132431
2011-06-01 22:37:07 +00:00
Johnny Chen
8831e18b17
Make 'run-until-faulted.py' script more interesting by modifying the example main.c program
...
to seg fault randomly instead of deterministically.
Example:
[15:10:43] johnny:/Volumes/data/lldb/svn/trunk/utils/test $ clang -g main.c
[15:10:46] johnny:/Volumes/data/lldb/svn/trunk/utils/test $ ./run-until-faulted.py -l $PWD/../../build/Debug/lldb -e a.out
lldb command: /Volumes/data/lldb/svn/trunk/utils/test/../../build/Debug/lldb
executable: a.out
executable options:
(lldb) sending 'file a.out' command...
file a.out
Current executable set to 'a.out' (x86_64).
(lldb) sending 'process launch -- ' command... (iteration: 0)
process launch --
Process 63630 launched: '/Volumes/data/lldb/svn/trunk/utils/test/a.out' (x86_64)
Hello, fault!
val=9
Better luck next time!
[KProcess 63630 exited with status = 0 (0x00000000)
(lldb) sending 'process launch -- ' command... (iteration: 1)
process launch --
Process 63633 launched: '/Volumes/data/lldb/svn/trunk/utils/test/a.out' (x86_64)
[KProcess 63633 exited with status = 0 (0x00000000)
sending 'process launch -- ' command... (iteration: 2)
[KHello, fault!
val=0
Better luck next time!
(lldb) process launch --
Process 63637 launched: '/Volumes/data/lldb/svn/trunk/utils/test/a.out' (x86_64)
Hello, fault!
val=15
Better luck next time!
[KProcess 63637 exited with status = 0 (0x00000000)
(lldb) sending 'process launch -- ' command... (iteration: 3)
process launch --
Process 63640 launched: '/Volumes/data/lldb/svn/trunk/utils/test/a.out' (x86_64)
Hello, fault!
val=2
Better luck next time!
[KProcess 63640 exited with status = 0 (0x00000000)
sending 'process launch -- ' command... (iteration: 4)
(lldb) process launch --
Process 63643 launched: '/Volumes/data/lldb/svn/trunk/utils/test/a.out' (x86_64)
[KProcess 63643 stopped
* thread #1 : tid = 0x2d03, 0x0000000100000e93 a.out`main + 99 at main.c:11, stop reason = EXC_BAD_ACCESS (code=1, address=0x0)
frame #0 : 0x0000000100000e93 a.out`main + 99 at main.c:11
8 u_int32_t val = (arc4random() & 0x0f);
9 printf("val=%u\n", val);
10 if (val == 0x07) // Lucky 7 :-)
-> 11 printf("Now segfault %d\n", *null_ptr);
12 else
13 printf("Better luck next time!\n");
14 }
(lldb)
* thread #1 : tid = 0x2d03, 0x0000000100000e93 a.out`main + 99 at main.c:11, stop reason = EXC_BAD_ACCESS (code=1, address=0x0)
frame #0 : 0x0000000100000e93 a.out`main + 99 at main.c:11
8 u_int32_t val = (arc4random() & 0x0f);
9 printf("val=%u\n", val);
10 if (val == 0x07) // Lucky 7 :-)
-> 11 printf("Now segfault %d\n", *null_ptr);
12 else
13 printf("Better luck next time!\n");
14 }
[KHello, fault!
val=7
(lldb)
llvm-svn: 132430
2011-06-01 22:12:27 +00:00
Devang Patel
324f843107
Do not drop constant values when a variable's content is described using .debug_loc entries.
...
llvm-svn: 132427
2011-06-01 22:03:25 +00:00
Argyrios Kyrtzidis
7e48d8ff0c
XFAIL the test on windows.
...
llvm-svn: 132426
2011-06-01 21:52:17 +00:00
Rafael Espindola
341d9b41d4
Add the necessary -L option for finding libprofile_rt.a. It might be a good
...
idea at some point to split out the directories where we install our runtime
libraries.
llvm-svn: 132425
2011-06-01 21:37:00 +00:00
Stuart Hastings
7adc95f69e
Recommit 132404 with fixes. rdar://problem/5993888
...
llvm-svn: 132424
2011-06-01 21:33:14 +00:00
Ted Kremenek
fb43639926
Rename -Wunknown-attributes to -Wattributes to match GCC.
...
llvm-svn: 132422
2011-06-01 20:09:40 +00:00
Howard Hinnant
bc95cf0d5f
Experimental support for a meaningful __is_swappable<T>::value. This does not appear to be strictly needed for correct functioning of the library. If it causes any problems, I'd rather pull it sooner rather than later.
...
llvm-svn: 132421
2011-06-01 19:59:32 +00:00
Eric Christopher
690030c116
Allow bitcasts between valid types of the same size and vector
...
types if the vector type is legal.
Fixes rdar://9306086
llvm-svn: 132420
2011-06-01 19:55:10 +00:00
Stuart Hastings
aab130d995
Revert 132404 to appease a buildbot. rdar://problem/5993888
...
llvm-svn: 132419
2011-06-01 19:52:20 +00:00
Nadav Rotem
22ad9bb7d9
Refactor LegalizeTypes: Erase LegalizeAction and make the type legalizer use
...
the TargetLowering enum.
llvm-svn: 132418
2011-06-01 19:47:10 +00:00
Johnny Chen
755faf7744
Make it clear that the Python script modify-python-lldb.py is responsible for post-processing
...
the SWIG-generated lldb.py module by adding comments in the post-processed file in order to
facilitate reading of the code.
llvm-svn: 132417
2011-06-01 19:21:08 +00:00
Andrew Trick
8ef3ad049d
SCEV: missing null check fix for r132360, dragonegg crash.
...
llvm-svn: 132416
2011-06-01 19:14:56 +00:00
Jakob Stoklund Olesen
e9cc8e90b7
Revert r132358 "Simplify the eviction policy by making the failsafe explicit."
...
This commit caused regressions in i386 flops-[568], matrix, salsa20,
256.bzip2, and enc-md5.
llvm-svn: 132413
2011-06-01 18:45:02 +00:00
Johnny Chen
2ced507a1e
Fix comment.
...
llvm-svn: 132412
2011-06-01 18:40:11 +00:00
Stuart Hastings
3ae49c03a4
Fix double FGETSIGN to work on x86_32; followup to 132396.
...
rdar://problem/5660695
llvm-svn: 132411
2011-06-01 18:32:25 +00:00
Eric Christopher
d949eb714a
Add a testcase, enabled only on arm, for llvm-gcc r132366.
...
llvm-svn: 132409
2011-06-01 18:23:56 +00:00
Stuart Hastings
41b1aa466d
Cleanup test case. rdar://problem/5660695
...
llvm-svn: 132408
2011-06-01 18:23:14 +00:00
Ted Kremenek
8c66ae7ddc
Remove derelict documentation.
...
llvm-svn: 132407
2011-06-01 17:45:02 +00:00
Howard Hinnant
e88f577da1
Turning on cxx_nullptr exposed a latent bug in is_function, causing nullptr to wrongly classify as a function. Fixed.
...
llvm-svn: 132406
2011-06-01 17:25:11 +00:00
Benjamin Kramer
10539ada05
Initialize IssueWidth to zero.
...
Fixes valgrind errors in the CellSPU backend.
llvm-svn: 132405
2011-06-01 17:19:08 +00:00
Stuart Hastings
7b7c102f2c
Add support for x86 CMPEQSS and friends. These instructions do a
...
floating-point comparison, generate a mask of 0s or 1s, and generally
DTRT with NaNs. Only profitable when the user wants a materialized 0
or 1 at runtime. rdar://problem/5993888
llvm-svn: 132404
2011-06-01 17:17:45 +00:00
Eli Friedman
ede23f760b
Don't use stdint.h; including it directly is not allowed from LLVM code because it doesn't exist on MSVC.
...
llvm-svn: 132403
2011-06-01 16:57:54 +00:00
Stuart Hastings
2380483355
Reapply 132348 with fixes. rdar://problem/6501862
...
llvm-svn: 132402
2011-06-01 16:42:47 +00:00
Stuart Hastings
6f89e2ffaa
A forthcoming SSE patch will break this test; since the test is also
...
valid for x87, re-target to x87. rdar://problem/5993888
llvm-svn: 132401
2011-06-01 16:13:09 +00:00
Douglas Gregor
981e37d727
The expression in a noexcept exception-specification is a
...
constant-expression, and, therefore, an unevaluated operand. Make it
so.
llvm-svn: 132400
2011-06-01 15:55:51 +00:00
Stuart Hastings
4d2fe66dc0
Test case for 132396. rdar://problem/5660695
...
llvm-svn: 132399
2011-06-01 15:50:29 +00:00
Jakob Stoklund Olesen
56ce3a0f01
Fix PR10059 and future variations by handling all register subclasses.
...
Add TargetRegisterInfo::hasSubClassEq and use it to check for compatible
register classes instead of trying to list all register classes in
X86's getLoadStoreRegOpcode.
llvm-svn: 132398
2011-06-01 15:32:10 +00:00
Douglas Gregor
39e9fa938c
Implement comparisons between nullptr and Objective-C object
...
pointers. Fixes PR10052.
llvm-svn: 132397
2011-06-01 15:12:24 +00:00
Stuart Hastings
fd5ecd0cec
Turn on FGETSIGN for x86. Followup to 132388. rdar://problem/5660695
...
llvm-svn: 132396
2011-06-01 14:04:17 +00:00
Joerg Sonnenberger
af5f23ee07
Add new -d option to tblgen. It writes a make(1)-style dependency file.
...
llvm-svn: 132395
2011-06-01 13:10:15 +00:00
Nadav Rotem
8b24a731f2
This patch is another step in the direction of adding vector select. In this
...
patch we add a flag to enable a new type legalization decision - to promote
integer elements in vectors. Currently, the rest of the codegen does not support
this kind of legalization. This flag will be removed when the transition is
complete.
llvm-svn: 132394
2011-06-01 12:51:46 +00:00