John Mosby
a8f0994ba7
fixed some typos in method comments, reworded some comments for clarity
...
llvm-svn: 90754
2009-12-07 09:06:37 +00:00
Oscar Fuentes
d4427a6b63
Fixes the Atomic implementation if compiled by MSVC compiler.
...
sys::cas_flag should be long on this platform, InterlockedAdd() is
defined only for the Itanium architecture (according to MSDN).
Patch by Michael Beck!
llvm-svn: 90748
2009-12-07 05:29:59 +00:00
Evan Cheng
2a99985e86
If BB is empty, insert PHI before end() instead of front().
...
llvm-svn: 90744
2009-12-07 03:07:01 +00:00
Anton Korobeynikov
615499bd84
Some pretty-printing
...
llvm-svn: 90742
2009-12-07 02:28:41 +00:00
Anton Korobeynikov
b4b8c71b20
Truncate the arguments of llvm.frameaddress / llvm.returnaddress intrinsics from i32 to platform's largest native type
...
llvm-svn: 90741
2009-12-07 02:28:26 +00:00
Anton Korobeynikov
d01ed4146b
Add lowering of returnaddr and frameaddr intrinsics. Shamelessly stolen from x86 :)
...
llvm-svn: 90740
2009-12-07 02:28:10 +00:00
Anton Korobeynikov
71b92ae4e0
Initial codegen support for MSP430 ISRs
...
llvm-svn: 90739
2009-12-07 02:27:53 +00:00
Anton Korobeynikov
fadc276b81
Add MSP430 interrupt calling conv. No functionality change yet.
...
llvm-svn: 90738
2009-12-07 02:27:35 +00:00
Anton Korobeynikov
02fa40119e
Add ability to select hw multiplier mode and select appropriate libcalls.
...
llvm-svn: 90737
2009-12-07 02:27:08 +00:00
Rafael Espindola
58789b1dd3
Fix typos. Thanks to John Tytgat for noticing it!
...
llvm-svn: 90728
2009-12-07 00:27:35 +00:00
Anton Korobeynikov
eee906f4f0
Dynamic stack realignment use of sp register as source/dest register
...
in "bic sp, sp, #15 " leads to unpredicatble behaviour in Thumb2 mode.
Emit the following code instead:
mov r4, sp
bic r4, r4, #15
mov sp, r4
llvm-svn: 90724
2009-12-06 22:39:50 +00:00
Chris Lattner
7066a138ff
fix PR5698
...
llvm-svn: 90708
2009-12-06 17:17:23 +00:00
Chris Lattner
c9a91632e1
remove extraneous comma clang warns about
...
llvm-svn: 90707
2009-12-06 16:58:41 +00:00
Chris Lattner
ea3007ddb8
constant fold loads from memcpy's from global constants. This is important
...
because clang lowers nontrivial automatic struct/array inits to memcpy from
a global array.
llvm-svn: 90698
2009-12-06 05:29:56 +00:00
Chris Lattner
8885e71303
add support for forwarding mem intrinsic values to non-local loads.
...
llvm-svn: 90697
2009-12-06 04:54:31 +00:00
Chris Lattner
6d180b4a2c
gvn is optimizing this better now.
...
llvm-svn: 90696
2009-12-06 04:16:05 +00:00
Chris Lattner
5eba6ee969
Handle forwarding local memsets to loads. For example, we optimize this:
...
short x(short *A) {
memset(A, 1, sizeof(*A)*100);
return A[42];
}
to 'return 257' instead of doing the load.
llvm-svn: 90695
2009-12-06 01:57:02 +00:00
Chris Lattner
aee232cb03
Add helper methods for forming shift operations with a constant
...
shift amount.
llvm-svn: 90694
2009-12-06 01:56:22 +00:00
Chris Lattner
f9ff4c0fc4
merge two tests.
...
llvm-svn: 90691
2009-12-06 01:47:24 +00:00
Oscar Fuentes
e1f5d048d7
CheckAtomic.cmake: Put all C++ code inside CHECK_CXX_SOURCE_COMPILES.
...
llvm-svn: 90685
2009-12-06 00:06:33 +00:00
Oscar Fuentes
ec99766e2e
Fix for atomic intrinsics detection when using MSVC.
...
Patch by Michael Beck!
llvm-svn: 90683
2009-12-05 23:19:33 +00:00
Dan Gohman
e6ce676cb2
Remove old DBG_LABEL code.
...
llvm-svn: 90669
2009-12-05 17:56:26 +00:00
Dan Gohman
d2797bf9ae
Remove the unused DisableLegalizeTypes option and related code.
...
llvm-svn: 90668
2009-12-05 17:51:33 +00:00
Bill Wendling
60e15336be
Calling InvalidateEntry during the refinement was breaking the bootstrap.
...
llvm-svn: 90656
2009-12-05 07:59:04 +00:00
Bill Wendling
a24fa4e67b
Final cleanups:
...
- Privatize a typedef.
- Call the InvalidateEntry when refining a type.
llvm-svn: 90655
2009-12-05 07:46:49 +00:00
Bill Wendling
887646a585
Temporarily revert r90502. It was causing the llvm-gcc bootstrap on PPC to fail.
...
llvm-svn: 90653
2009-12-05 07:30:23 +00:00
Nick Lewycky
6f5e732b75
Document that memory use intrinsics may also return Def results.
...
llvm-svn: 90651
2009-12-05 06:37:52 +00:00
Nick Lewycky
056fe5f97d
Fix indentation in switch statement.
...
llvm-svn: 90650
2009-12-05 06:37:24 +00:00
Nick Lewycky
10693e2bb0
Generalize this optimization to work on equality comparisons between any two
...
integers that are constant except for a single bit (the same n-th bit in each).
llvm-svn: 90646
2009-12-05 05:00:00 +00:00
Eric Christopher
2a9b28c14b
More updates to objectsize intrinsic docs.
...
llvm-svn: 90644
2009-12-05 02:46:03 +00:00
Dan Gohman
bdf1b76e0f
Don't print a space before the : between the file name and line number.
...
And separate the directory and file name with a '/'.
llvm-svn: 90641
2009-12-05 02:00:34 +00:00
Bill Wendling
fb8e8f8bd7
Inline methods which are called only once.
...
llvm-svn: 90640
2009-12-05 01:46:01 +00:00
Bill Wendling
7871b8a922
Refactor some code. No functionality change.
...
llvm-svn: 90639
2009-12-05 01:43:33 +00:00
Dan Gohman
b2fda9f9f4
Print newlines after printing labels for debug info, so that the output
...
isn't cluttered with things like "Llabel47:Llabel48: movq (%rsi), %xmm3"
llvm-svn: 90638
2009-12-05 01:42:34 +00:00
Dan Gohman
b352b42391
Don't blindly set the debug location for PHI node copies.
...
llvm-svn: 90637
2009-12-05 01:29:04 +00:00
Dan Gohman
c9454cd34f
Make TargetSelectInstruction protected and called from FastISel.cpp
...
instead of SelectionDAGISel.cpp.
llvm-svn: 90636
2009-12-05 01:27:58 +00:00
Dan Gohman
f9654e9258
Remove the target hook TargetInstrInfo::BlockHasNoFallThrough in favor of
...
MachineBasicBlock::canFallThrough(), which is target-independent and more
thorough.
llvm-svn: 90634
2009-12-05 00:44:40 +00:00
Dan Gohman
fc11083645
Simplify this code: don't call AnalyzeBranch before doing simpler checks.
...
llvm-svn: 90633
2009-12-05 00:32:59 +00:00
Dan Gohman
feeb2f07a1
The debug information for an LLVM Instruction applies to that Instruction
...
and that Instruction only. Implement this by setting the "current debug position"
back to Unknown after processing each instruction.
llvm-svn: 90632
2009-12-05 00:27:08 +00:00
Dan Gohman
cf29c2243b
Fix this code to use DIScope instead of DICompileUnit, as in r90181.
...
Don't print "SrcLine"; just print the filename and line number, which
is obvious enough and more informative.
llvm-svn: 90631
2009-12-05 00:23:29 +00:00
Dan Gohman
309e2283ab
Don't print the debug directory; it's often long and uninteresting. Omit
...
the column number if it is not known. Handle the case of a missing filename
better.
llvm-svn: 90630
2009-12-05 00:20:51 +00:00
Dan Gohman
247374da74
Minor code simplification.
...
llvm-svn: 90628
2009-12-05 00:05:43 +00:00
David Greene
4ab7e5fa6a
Remove an unneeded include.
...
llvm-svn: 90627
2009-12-05 00:03:24 +00:00
Dan Gohman
e23727694c
Remove now-redundant llvm-as invocations.
...
llvm-svn: 90626
2009-12-05 00:02:37 +00:00
David Greene
755852d0c3
Remove an unneeded include.
...
llvm-svn: 90625
2009-12-04 23:55:07 +00:00
Bill Wendling
87980517df
Add testcase for PR4262.
...
llvm-svn: 90623
2009-12-04 23:29:57 +00:00
Dan Gohman
e6b70ddf0c
Print a space between the comment character and the text.
...
llvm-svn: 90621
2009-12-04 23:19:55 +00:00
Bill Wendling
7993d94840
Temporarily revert r72620 because r72619 was reverted.
...
llvm-svn: 90619
2009-12-04 23:16:56 +00:00
Devang Patel
10e8f51059
In TAG_subrange_type, uppder bound is zero indexed.
...
llvm-svn: 90617
2009-12-04 23:10:24 +00:00
David Greene
7ff6aa2e62
Fix a bad merge.
...
llvm-svn: 90616
2009-12-04 23:08:02 +00:00