Commit Graph

127435 Commits

Author SHA1 Message Date
Stepan Dyatkovskiy 0beab5e1cd Recommited r156374 with critical fixes in BitcodeReader/Writer:
Ordinary patch for PR1255.
Added new case-ranges orientated methods for adding/removing cases in SwitchInst. After this patch cases will internally representated as ConstantArray-s instead of ConstantInt, externally cases wrapped within the ConstantRangesSet object.
Old methods of SwitchInst are also works well, but marked as deprecated. So on this stage we have no side effects except that I added support for case ranges in BitcodeReader/Writer, of course test for Bitcode is also added. Old "switch" format is also supported.

llvm-svn: 156704
2012-05-12 10:48:17 +00:00
Jay Foad ca0c499609 Teach Function::hasAddressTaken that BlockAddress doesn't really take
the address of a function.

llvm-svn: 156703
2012-05-12 08:30:16 +00:00
Sirish Pande 8bb9745a5e Make sure new value jump is enabled for Hexagon V5 as well.
llvm-svn: 156700
2012-05-12 05:54:15 +00:00
Jordy Rose 6393f82b5b [analyzer] RetainCountChecker: track ObjC boxed expression objects.
llvm-svn: 156699
2012-05-12 05:10:43 +00:00
Sirish Pande 4bd20c50eb Support for Hexagon feature, New Value Jump.
llvm-svn: 156698
2012-05-12 05:10:30 +00:00
Akira Hatanaka 763ab85690 Fix test cases.
llvm-svn: 156697
2012-05-12 03:25:16 +00:00
Akira Hatanaka a6c3fd8317 Remove MipsEmitGPRestore.cpp.
llvm-svn: 156696
2012-05-12 03:24:03 +00:00
Akira Hatanaka 3ecc5273c1 Delete all functions that are no longer needed in MipsFunctionInfo, including
the ones that get or set the frame index for the $gp save slot. 

Remove the piece of code in MipsFunctionInfo::getGlobalBaseReg() which returns
GP. This function should always return a virtual register.

llvm-svn: 156695
2012-05-12 03:22:13 +00:00
Akira Hatanaka 2e31e036b6 Stop reserving register $gp. Do not call isGPFI to check whether a frame object
is the $gp save slot.

llvm-svn: 156694
2012-05-12 03:21:18 +00:00
Akira Hatanaka 0fb87feb39 Do not add the pass which restores $gp after every function call.
llvm-svn: 156693
2012-05-12 03:19:51 +00:00
Akira Hatanaka f542ebd958 Make the following changes in MipsISelLowering.cpp:
- Stop creating stack frame objects needed for saving $gp.
- Insert a node that copies the global pointer register to register $gp
  before the call node. This will ensure $gp is valid at the entry of the
  called function.

llvm-svn: 156692
2012-05-12 03:19:04 +00:00
Akira Hatanaka c980f8453a Make the following changes in MipsFrameLowering.cpp:
- Stop emitting instructions needed to initialize the global pointer register.
- Stop emitting .cprestore directive.
- Do not take into account the $gp save slot when computing stack size.

llvm-svn: 156691
2012-05-12 03:18:00 +00:00
Jakob Stoklund Olesen 2d247c806f Speed up computeComposites() by using the new SubReg -> SubIdx map.
TableGen doesn't need to search through the SubRegs map to find an
inverse entry.

llvm-svn: 156690
2012-05-12 02:02:26 +00:00
Akira Hatanaka 8f3573034b Make the following changes in MipsAsmPrinter.cpp:
- Remove code which lowers pseudo SETGP01.
- Fix LowerSETGP01. The first two of the three instructions that are emitted to
  initialize the global pointer register now use register $2.
- Stop emitting .cpload directive.

llvm-svn: 156689
2012-05-12 00:48:43 +00:00
Chad Rosier 10702d5f22 Hoist simpler checks above llvm::PointerMayBeCaptured. No functional change intended.
llvm-svn: 156687
2012-05-12 00:43:40 +00:00
Jim Ingham dff0440405 Add a useful error message to "log enable" with the wrong number of arguments, and reject "log enable lldb" which just silently did nothing before.
llvm-svn: 156686
2012-05-12 00:38:30 +00:00
Jakob Stoklund Olesen 165473247f Don't look for empty live ranges in the unions.
Empty live ranges represent undef and still get allocated, but they
won't appear in LiveIntervalUnions.

Patch by Patrik Hägglund!

llvm-svn: 156685
2012-05-12 00:33:28 +00:00
Greg Clayton 1a362fbb86 <rdar://problem/11439169>
"lldb -a i386" doesn't set the calculator mode correctly if run on a 64 bit system. 

The previous logic always used the current host architecture, not the default architecture. The default arch gets set into a static varaible in lldb_private::Target when an arch is set from the command line:

lldb -a i386

We now use the default arch correctly.

llvm-svn: 156680
2012-05-12 00:26:42 +00:00
Akira Hatanaka d918f77ba3 Insert instructions to the entry basic block which initializes the global
pointer register. 


This is the first of the series of patches which clean up the way global pointer
register is used. The patches will make the following improvements:

- Make $gp an allocatable temporary register rather than reserving it.
- Use a virtual register as the global pointer register and let the register
  allocator decide which register to assign to it or whether spill/reloads are
  needed.
- Make sure $gp is valid at the entry of a called function, which is necessary
  for functions using lazy binding.
- Remove the need for emitting .cprestore and .cpload directives.

llvm-svn: 156671
2012-05-12 00:17:17 +00:00
Greg Clayton 950971f77c <rdar://problem/11439022>
Restore expressions with no target.

llvm-svn: 156669
2012-05-12 00:01:21 +00:00
Jim Ingham 031177e4df Fix a comment I had incorrectly altered.
llvm-svn: 156668
2012-05-11 23:49:49 +00:00
Jim Ingham 7ba6e99158 Found one more place where the OkayToDiscard needs to be consulted.
Also changed the defaults for SBThread::Step* to not delete extant plans.
Also added some test cases to test more complex stepping scenarios.

llvm-svn: 156667
2012-05-11 23:47:32 +00:00
Douglas Gregor 87a170c1e6 Teach the parser to deal with multiple spellings for the same
attribute, rather than requiring multiple cases in consumers of this
information.

llvm-svn: 156666
2012-05-11 23:37:49 +00:00
Michael J. Spencer a39c9bceeb Add doxygen comments.
llvm-svn: 156665
2012-05-11 23:34:39 +00:00
Anna Zaks 3236bad851 [analyzer] Test variable modified types.
llvm-svn: 156664
2012-05-11 23:34:14 +00:00
Akira Hatanaka 0661b81bca Do not replace operands of pseudo instructions with register $zero.
llvm-svn: 156663
2012-05-11 23:22:18 +00:00
Chad Rosier a33015d4e0 Revert 156658.
llvm-svn: 156662
2012-05-11 23:21:01 +00:00
Anna Zaks e7e7c9ebf9 [analyzer] Do not walk the types for call graph construction.
llvm-svn: 156661
2012-05-11 23:15:18 +00:00
Anna Zaks 5983aa67d5 [analyzer] Test objC boxing.
llvm-svn: 156660
2012-05-11 23:15:16 +00:00
Anna Zaks 2d10fdd4ec [analyzer] Add buffer overflow test case.
llvm-svn: 156659
2012-05-11 23:15:11 +00:00
Chad Rosier e40f5d3ee0 [fast-isel] Fast-isel doesn't use the expect intrinsic.
llvm-svn: 156658
2012-05-11 23:10:58 +00:00
Douglas Gregor 4f362c7960 Make sure that we recognize __attribute__((align)) as a synonym for
__attribute__((aligned)). Fixes <rdar://problem/11435441>, a
regression I introduced in r156003. This is the narrow fix; a more
comprehensive fix is coming.

llvm-svn: 156657
2012-05-11 23:01:43 +00:00
Akira Hatanaka 5d60c36f37 Use regular expression to match register names.
llvm-svn: 156656
2012-05-11 23:00:40 +00:00
Bill Wendling 7d878db4e1 Make the URL a link instead.
llvm-svn: 156655
2012-05-11 22:38:33 +00:00
Richard Smith 7d847b1ec1 When diagnosing inaccessible temporary destructors in decltype expressions, use
the correct type and the correct source location in the diagnostic. Spotted by
Johannes Schaub!

llvm-svn: 156654
2012-05-11 22:20:10 +00:00
Matt Beaumont-Gay d873508975 Merge branch 'format-string-braced-init'
llvm-svn: 156653
2012-05-11 22:10:59 +00:00
Michael J. Spencer 93303819ac [Support/StringRef] Add find_last_not_of and {r,l,}trim.
llvm-svn: 156652
2012-05-11 22:08:50 +00:00
Greg Clayton 0021bd2fe3 Remove comments and an extra print statement.
llvm-svn: 156651
2012-05-11 21:57:50 +00:00
Akira Hatanaka 8ab86cb344 Coerce byval aggregate arguments to integers whose size matches the integer
register size of the target architecture.
 

llvm-svn: 156650
2012-05-11 21:56:58 +00:00
Bill Wendling 393f432ddf Remove extraneous ; and the resulting warning.
llvm-svn: 156649
2012-05-11 21:56:04 +00:00
Bill Wendling 9cc768581a Add mention of Glasgow Haskell Compiler.
llvm-svn: 156648
2012-05-11 21:42:37 +00:00
Argyrios Kyrtzidis 45f5118248 The Lexer constructor expects a source location at the start of the
file buffer, not at the start of lexing.

Fixes assertion hit in format diagnostics. rdar://11418366

llvm-svn: 156647
2012-05-11 21:39:18 +00:00
Chad Rosier aa9cb9df59 [fast-isel] Add support for selecting @llvm.trap().
llvm-svn: 156646
2012-05-11 21:33:49 +00:00
Brendon Cahoon 5edcf8822d Updated instruction table due to addded intrinsics.
llvm-svn: 156644
2012-05-11 21:10:16 +00:00
Akira Hatanaka c37eddf7a7 Fix handling of vector return types.
A vector should be returned via the hidden pointer argument except if its size
is equal to or smaller than 16-bytes and the target ABI is N32 or N64.

llvm-svn: 156642
2012-05-11 21:01:17 +00:00
Filipe Cabecinhas 1a96ef800b Make every Python API __len__() method return a PyIntObject.
swig 2.0+ seems to default to using PyLongObjects, but the __len__()
method _must_ return a PyIntObject.

llvm-svn: 156639
2012-05-11 20:39:42 +00:00
Filipe Cabecinhas 0bfed4bc7a Fix SBProcess::ReadMemory's typemap to handle PyLongObjects.
llvm-svn: 156638
2012-05-11 20:38:28 +00:00
Filipe Cabecinhas 0c543ea186 Make issue_11588/Test11588 work with a recent swig that converts ints to PyLongObjects
llvm-svn: 156637
2012-05-11 20:37:34 +00:00
Sirish Pande 95d0117bb3 Remove warnings from HexagonVLIWPacketizer.
llvm-svn: 156636
2012-05-11 20:00:34 +00:00
Duncan Sands 1367e49f6b Some release notes for dragonegg.
llvm-svn: 156635
2012-05-11 19:59:43 +00:00