platform/upstream/llvm.git
11 years agoRevert CostTable algorithm, will re-write
Renato Golin [Sun, 20 Jan 2013 20:57:20 +0000 (20:57 +0000)]
Revert CostTable algorithm, will re-write

llvm-svn: 172992

11 years ago[Support] Port ErrorOr<T> from lld to C++03.
Michael J. Spencer [Sun, 20 Jan 2013 20:32:30 +0000 (20:32 +0000)]
[Support] Port ErrorOr<T> from lld to C++03.

llvm-svn: 172991

11 years agoLoopVectorize: Fix a C++11 incompatibility.
Benjamin Kramer [Sun, 20 Jan 2013 20:29:52 +0000 (20:29 +0000)]
LoopVectorize: Fix a C++11 incompatibility.

llvm-svn: 172990

11 years agoPrune unused diagnostics.
Benjamin Kramer [Sun, 20 Jan 2013 19:29:01 +0000 (19:29 +0000)]
Prune unused diagnostics.

Courtesy of utils/find-unused-diagnostics.sh.

llvm-svn: 172988

11 years agoAdd instruction encodings / disassembly support for l2rus instructions.
Richard Osborne [Sun, 20 Jan 2013 18:51:15 +0000 (18:51 +0000)]
Add instruction encodings / disassembly support for l2rus instructions.

llvm-svn: 172987

11 years agoAdd instruction encodings / disassembly support for l3r instructions.
Richard Osborne [Sun, 20 Jan 2013 18:37:49 +0000 (18:37 +0000)]
Add instruction encodings / disassembly support for l3r instructions.

llvm-svn: 172986

11 years agoAdd instruction encodings / disassembler support for 2rus instructions.
Richard Osborne [Sun, 20 Jan 2013 17:22:43 +0000 (17:22 +0000)]
Add instruction encodings / disassembler support for 2rus instructions.

llvm-svn: 172985

11 years agoAdd instruction encodings / disassembly support 3r instructions.
Richard Osborne [Sun, 20 Jan 2013 17:18:47 +0000 (17:18 +0000)]
Add instruction encodings / disassembly support 3r instructions.

It is not possible to distinguish 3r instructions from 2r / rus instructions
using only the fixed bits. Therefore if an instruction doesn't match the
2r / rus format try to decode it as a 3r instruction before returning Fail.

llvm-svn: 172984

11 years agollvm/test/CodeGen/X86/win_ftol2.ll: Add -cpu=generic to appease valgrind.
NAKAMURA Takumi [Sun, 20 Jan 2013 15:40:02 +0000 (15:40 +0000)]
llvm/test/CodeGen/X86/win_ftol2.ll: Add -cpu=generic to appease valgrind.

On valgrind the processor is reported;
  Host CPU: athlon-fx

llvm-svn: 172983

11 years agoclang/utils/valgrind/x86_64-pc-linux-gnu_gcc-4.3.3.supp: Add /usr/bin/cmp.
NAKAMURA Takumi [Sun, 20 Jan 2013 15:30:41 +0000 (15:30 +0000)]
clang/utils/valgrind/x86_64-pc-linux-gnu_gcc-4.3.3.supp: Add /usr/bin/cmp.

FIXME: It could be removed if;

  - check-all included llvm/valgrind/supp, too.
  - clang-vg didn't use "check-all".

llvm-svn: 172982

11 years agollvm/utils/valgrind/x86_64-pc-linux-gnu.supp: Add /usr/bin/cmp.
NAKAMURA Takumi [Sun, 20 Jan 2013 15:30:29 +0000 (15:30 +0000)]
llvm/utils/valgrind/x86_64-pc-linux-gnu.supp: Add /usr/bin/cmp.

llvm-svn: 172981

11 years agoAdd bitreader to LINK_COMPONENTS in users of libclang, c-arcmt-test and c-index-test.
NAKAMURA Takumi [Sun, 20 Jan 2013 14:53:49 +0000 (14:53 +0000)]
Add bitreader to LINK_COMPONENTS in users of libclang, c-arcmt-test and c-index-test.

They don't link cygclang.dll, but libclang.a on cygwin.

llvm-svn: 172980

11 years agoCMake: Add add_compiler_rt_osx_object_library to create universal libraries on Mac
Alexey Samsonov [Sun, 20 Jan 2013 14:36:12 +0000 (14:36 +0000)]
CMake: Add add_compiler_rt_osx_object_library to create universal libraries on Mac

llvm-svn: 172979

11 years agoCMake: use add_compiler_rt_static_runtime to build TSan and MSan runtimes. No functio...
Alexey Samsonov [Sun, 20 Jan 2013 14:14:13 +0000 (14:14 +0000)]
CMake: use add_compiler_rt_static_runtime to build TSan and MSan runtimes. No functionality change.

llvm-svn: 172978

11 years agoCMake: Add add_compiler_rt_static_runtime function and use it to build generic compil...
Alexey Samsonov [Sun, 20 Jan 2013 13:58:10 +0000 (13:58 +0000)]
CMake: Add add_compiler_rt_static_runtime function and use it to build generic compiler-rt libraries

llvm-svn: 172977

11 years agoTemporary disable test added in r172828 as it seems to be flaky on the buildbots
Alexey Samsonov [Sun, 20 Jan 2013 13:41:26 +0000 (13:41 +0000)]
Temporary disable test added in r172828 as it seems to be flaky on the buildbots

llvm-svn: 172976

11 years agoFixup for r172828: use InternalScopedBuffer in favor of large stack buffers
Alexey Samsonov [Sun, 20 Jan 2013 13:22:06 +0000 (13:22 +0000)]
Fixup for r172828: use InternalScopedBuffer in favor of large stack buffers

llvm-svn: 172975

11 years agoAdd top-level Clang flag -f(no-)sanitize-address-zero-base-shadow that makes AddressS...
Alexey Samsonov [Sun, 20 Jan 2013 13:12:12 +0000 (13:12 +0000)]
Add top-level Clang flag -f(no-)sanitize-address-zero-base-shadow that makes AddressSanitizer use bottom of the address space for the shadow memory. On Linux it can be used with -fPIE/-pie to improve performance.

llvm-svn: 172974

11 years agoImplement OpenCL event_t as Clang builtin type, including event_t related OpenCL...
Guy Benyei [Sun, 20 Jan 2013 12:31:11 +0000 (12:31 +0000)]
Implement OpenCL event_t as Clang builtin type, including event_t related OpenCL restrictions (OpenCL 1.2 spec 6.9)

llvm-svn: 172973

11 years ago[docs] Document lld's usage of C++11 features.
Michael J. Spencer [Sun, 20 Jan 2013 10:39:17 +0000 (10:39 +0000)]
[docs] Document lld's usage of C++11 features.

llvm-svn: 172972

11 years agoFix a build error.
Nadav Rotem [Sun, 20 Jan 2013 09:39:17 +0000 (09:39 +0000)]
Fix a build error.

llvm-svn: 172971

11 years ago[docs] Update IRC information.
Michael J. Spencer [Sun, 20 Jan 2013 09:38:14 +0000 (09:38 +0000)]
[docs] Update IRC information.

llvm-svn: 172970

11 years agoMake LowerVSETCC a static function and use MVT instead of EVT.
Craig Topper [Sun, 20 Jan 2013 09:02:22 +0000 (09:02 +0000)]
Make LowerVSETCC a static function and use MVT instead of EVT.

llvm-svn: 172969

11 years agoRevert 172708.
Nadav Rotem [Sun, 20 Jan 2013 08:35:56 +0000 (08:35 +0000)]
Revert 172708.

The optimization handles esoteric cases but adds a lot of complexity both to the X86 backend and to other backends.
This optimization disables an important canonicalization of chains of SEXT nodes and makes SEXT and ZEXT asymmetrical.
Disabling the canonicalization of consecutive SEXT nodes into a single node disables other DAG optimizations that assume
that there is only one SEXT node. The AVX mask optimizations is one example. Additionally this optimization does not update the cost model.

llvm-svn: 172968

11 years agoChanged IRBuilder::CreateZExtOrTrunc and IRBuilder::CreateSExtOrTrunc so they also...
Michael Gottesman [Sun, 20 Jan 2013 07:33:26 +0000 (07:33 +0000)]
Changed IRBuilder::CreateZExtOrTrunc and IRBuilder::CreateSExtOrTrunc so they also work with vectors.

I also changed the name of a variable in IRBuilder::CreateFPExtOrFPTrunc to
match the names used in its two matching brethern as well.

llvm-svn: 172967

11 years agoUpdate the gcc-loops benchmark
Nadav Rotem [Sun, 20 Jan 2013 07:01:04 +0000 (07:01 +0000)]
Update the gcc-loops benchmark

llvm-svn: 172966

11 years agoUpdate the linpack benchmark with different array sizes.
Nadav Rotem [Sun, 20 Jan 2013 06:52:47 +0000 (06:52 +0000)]
Update the linpack benchmark with different array sizes.

llvm-svn: 172965

11 years agoLoopVectorizer: Implement a new heuristics for selecting the unroll factor.
Nadav Rotem [Sun, 20 Jan 2013 05:24:29 +0000 (05:24 +0000)]
LoopVectorizer: Implement a new heuristics for selecting the unroll factor.
We ignore the cpu frontend and focus on pipeline utilization. We do this because we
don't have a good way to estimate the loop body size at the IR level.

llvm-svn: 172964

11 years agoChange the cpu type in the test.
Nadav Rotem [Sun, 20 Jan 2013 05:20:56 +0000 (05:20 +0000)]
Change the cpu type in the test.

llvm-svn: 172963

11 years agoMore copy editing.
Michael Gottesman [Sun, 20 Jan 2013 05:12:35 +0000 (05:12 +0000)]
More copy editing.

llvm-svn: 172962

11 years agoDoxygenified and copy edited BasicBlock.h.
Michael Gottesman [Sun, 20 Jan 2013 05:03:42 +0000 (05:03 +0000)]
Doxygenified and copy edited BasicBlock.h.

llvm-svn: 172961

11 years agoDoxygenified Argument.h and performed some copy editing of the documentation.
Michael Gottesman [Sun, 20 Jan 2013 05:03:39 +0000 (05:03 +0000)]
Doxygenified Argument.h and performed some copy editing of the documentation.

llvm-svn: 172960

11 years agoConverted all method comments in IRBuilder.h to use doxygen style comments.
Michael Gottesman [Sun, 20 Jan 2013 05:03:37 +0000 (05:03 +0000)]
Converted all method comments in IRBuilder.h to use doxygen style comments.

This implies changing method documentation from the following style:

/// MethodName - Method description...

to

/// \brief Method description...

ala the LLVM Style Guide.

llvm-svn: 172959

11 years agoCorrected assert messages for CreateZExtOrTrunc/CreateSExtOrTrunc.
Michael Gottesman [Sun, 20 Jan 2013 04:19:39 +0000 (04:19 +0000)]
Corrected assert messages for CreateZExtOrTrunc/CreateSExtOrTrunc.

llvm-svn: 172958

11 years agoAdded IRBuilder::CreateFPExtOrFPTrunc.
Michael Gottesman [Sun, 20 Jan 2013 03:56:31 +0000 (03:56 +0000)]
Added IRBuilder::CreateFPExtOrFPTrunc.

This method serves an analogous purpose to CreateZExtOrTrunc/CreateSExtOrTrunc
but for floating point types.

In detail, it provides a manner when one is handling conversions of floating
point types of automatically selecting fpext, fptrunc, or identity depending on
the relative bitsize of the source and destination types.

llvm-svn: 172957

11 years agollvm/test/Other/close-stderr.ll: Mark this as XFAIL:valgrind. We got 127 instead...
NAKAMURA Takumi [Sun, 20 Jan 2013 03:35:39 +0000 (03:35 +0000)]
llvm/test/Other/close-stderr.ll: Mark this as XFAIL:valgrind. We got 127 instead of 1 here.

llvm-svn: 172956

11 years agoReleaseNotes: note Sphinx migration.
Sean Silva [Sun, 20 Jan 2013 03:32:55 +0000 (03:32 +0000)]
ReleaseNotes: note Sphinx migration.

llvm-svn: 172955

11 years agodocs: Nuke the old release notes.
Sean Silva [Sun, 20 Jan 2013 03:29:50 +0000 (03:29 +0000)]
docs: Nuke the old release notes.

This change also removes a bunch of boilerplate and stuffing which made
it unnecessarily hard to navigate and see the comparatively miniscule
actual content that was added to this document during the 3.2
development period (or maybe even sticking around from earlier
releases...).

The new organization (a flat list) optimizes for making it easy for
people who know about changes to add them to the document.  It's
completely trivial for anyone with basic knowledge of LLVM to come in
later (such as when preparing for the actual release) and cluster any
changes into logical groups. However, I have left some comments
indicating how to add larger descriptions, if someone is feeling
adventurous ;)

Hopefully this organization will highlight how little effort is being
put into producing accurate, high-quality release notes, prompting a
corresponding improvement for the 3.3 release.

I have preserved the changes to this document that are not present
in the 3.2 release notes. There were only two... I'm pretty sure we've
been busier than that... (version control shows +213347/-173656 raw
lines just in the LLVM repo since the 3.2 release).

llvm-svn: 172954

11 years agotrivial micro-optimization: lazily call the virtual method instead of eagerly calling it.
Chris Lattner [Sun, 20 Jan 2013 02:54:05 +0000 (02:54 +0000)]
trivial micro-optimization: lazily call the virtual method instead of eagerly calling it.

llvm-svn: 172953

11 years agoswitch llvm-bcanalyzer onto the new cursor APIs, allowing deletion of
Chris Lattner [Sun, 20 Jan 2013 02:50:32 +0000 (02:50 +0000)]
switch llvm-bcanalyzer onto the new cursor APIs, allowing deletion of
the old ReadRecord methods.

llvm-svn: 172952

11 years agoupdate to use the new BitcodeCursor readRecord that takes a StringRef blob parameter,
Chris Lattner [Sun, 20 Jan 2013 02:38:54 +0000 (02:38 +0000)]
update to use the new BitcodeCursor readRecord that takes a StringRef blob parameter,
and adopt "advance" in more places.

llvm-svn: 172951

11 years agodocs: Use proper markup.
Sean Silva [Sun, 20 Jan 2013 02:19:42 +0000 (02:19 +0000)]
docs: Use proper markup.

These are really definition lists.

llvm-svn: 172950

11 years agodocs: Inline documentation structure into homepage.
Sean Silva [Sun, 20 Jan 2013 02:19:36 +0000 (02:19 +0000)]
docs: Inline documentation structure into homepage.

This brings back {Ctrl,Cmd}-f'ability, and makes some really bad
organizational choices easier to see (and therefore fix).

llvm-svn: 172949

11 years agoconvert the bitstream reader itself and the IR .bc file parser to use the new advance...
Chris Lattner [Sun, 20 Jan 2013 02:13:19 +0000 (02:13 +0000)]
convert the bitstream reader itself and the IR .bc file parser to use the new advance() APIs,
simplifying things and making a bunch of details more private to BitstreamCursor.

llvm-svn: 172947

11 years agoadd an option to not auto-process abbreviations in advance()
Chris Lattner [Sun, 20 Jan 2013 02:12:39 +0000 (02:12 +0000)]
add an option to not auto-process abbreviations in advance()

llvm-svn: 172946

11 years agoNuke SetUpBuildDumpLog.
Sean Silva [Sun, 20 Jan 2013 01:58:28 +0000 (01:58 +0000)]
Nuke SetUpBuildDumpLog.

Also, it was the only reason that `argc` and `argv` were being passed
into createDiagnostics, so remove those parameters and clean up callers.

llvm-svn: 172945

11 years agoFix what appears to be a copy-paste error.
Sean Silva [Sun, 20 Jan 2013 01:58:26 +0000 (01:58 +0000)]
Fix what appears to be a copy-paste error.

This looks like it was copied from SetUpBuildDumpLog, which dumps to the
file `DiagOpts->DumpBuildInformation`. There is another member
`DiagOpts->DiagnosticLogFile` which appears to be unused. The fact that
this feature doesn't even print to the output file specified on the
command line makes me think that it should be ripped out.

llvm-svn: 172944

11 years agoThe last of PR14471: Debug info support for inline in-class initializer for float...
David Blaikie [Sun, 20 Jan 2013 01:19:17 +0000 (01:19 +0000)]
The last of PR14471: Debug info support for inline in-class initializer for float static members

llvm-svn: 172942

11 years agoThe last of PR14471 - emission of constant floats
David Blaikie [Sun, 20 Jan 2013 01:18:01 +0000 (01:18 +0000)]
The last of PR14471 - emission of constant floats

llvm-svn: 172941

11 years agostringref'ize readRecord and properly capitalize it. Add a compatibility method...
Chris Lattner [Sun, 20 Jan 2013 01:06:48 +0000 (01:06 +0000)]
stringref'ize readRecord and properly capitalize it.  Add a compatibility method to easy
the transition.

llvm-svn: 172940

11 years agoFixed trailing whitespace.
Michael Gottesman [Sun, 20 Jan 2013 01:04:14 +0000 (01:04 +0000)]
Fixed trailing whitespace.

llvm-svn: 172939

11 years agoadd back a #include needed on some builders.
Chris Lattner [Sun, 20 Jan 2013 00:57:52 +0000 (00:57 +0000)]
add back a #include needed on some builders.

llvm-svn: 172938

11 years agofinish converting the normal cases in ASTReader to use the new BitstreamCursor APIs.
Chris Lattner [Sun, 20 Jan 2013 00:56:42 +0000 (00:56 +0000)]
finish converting the normal cases in ASTReader to use the new BitstreamCursor APIs.

llvm-svn: 172937

11 years agoMake some helper methods static.
Craig Topper [Sun, 20 Jan 2013 00:50:58 +0000 (00:50 +0000)]
Make some helper methods static.

llvm-svn: 172936

11 years agoRemove DebugLoc argument from static function. It can easily be obtained from the...
Craig Topper [Sun, 20 Jan 2013 00:43:42 +0000 (00:43 +0000)]
Remove DebugLoc argument from static function. It can easily be obtained from the SVOp passed in.

llvm-svn: 172935

11 years ago[cindex.py]: Use spaces instead of tabs
Tobias Grosser [Sun, 20 Jan 2013 00:42:16 +0000 (00:42 +0000)]
[cindex.py]: Use spaces instead of tabs

The tabs slipped in accidentally.

llvm-svn: 172934

11 years agoUse MVT instead of EVT in more instruction lowering code.
Craig Topper [Sun, 20 Jan 2013 00:38:18 +0000 (00:38 +0000)]
Use MVT instead of EVT in more instruction lowering code.

llvm-svn: 172933

11 years agoconvert some more stuff over to use new cursor APIs.
Chris Lattner [Sun, 20 Jan 2013 00:00:22 +0000 (00:00 +0000)]
convert some more stuff over to use new cursor APIs.

llvm-svn: 172932

11 years agomove some private methods out of line, add a skipRecord() method.
Chris Lattner [Sun, 20 Jan 2013 00:00:00 +0000 (00:00 +0000)]
move some private methods out of line, add a skipRecord() method.

llvm-svn: 172931

11 years agoUse MVT instead of EVT in more of the shuffle lowering code.
Craig Topper [Sat, 19 Jan 2013 23:36:09 +0000 (23:36 +0000)]
Use MVT instead of EVT in more of the shuffle lowering code.

llvm-svn: 172930

11 years agoadd some optional flags to affect the way advance works.
Chris Lattner [Sat, 19 Jan 2013 23:31:15 +0000 (23:31 +0000)]
add some optional flags to affect the way advance works.

llvm-svn: 172928

11 years agoCapitalize LowerVectorIntExtend to be consistent with all the other lower functions...
Craig Topper [Sat, 19 Jan 2013 23:14:09 +0000 (23:14 +0000)]
Capitalize LowerVectorIntExtend to be consistent with all the other lower functions in this file.

llvm-svn: 172927

11 years agoFix a latent bug exposed by recent static member debug info changes.
David Blaikie [Sat, 19 Jan 2013 23:00:25 +0000 (23:00 +0000)]
Fix a latent bug exposed by recent static member debug info changes.

We weren't encoding boolean constants correctly due to modeling boolean as a
signed type & then sign extending an i1 up to a byte & getting 255.

llvm-svn: 172926

11 years agoActually update the test, fixup for r172923
Dmitri Gribenko [Sat, 19 Jan 2013 22:11:28 +0000 (22:11 +0000)]
Actually update the test, fixup for r172923

llvm-svn: 172925

11 years agoUse llvm::hexDigitValue in comment lexer
Dmitri Gribenko [Sat, 19 Jan 2013 22:06:05 +0000 (22:06 +0000)]
Use llvm::hexDigitValue in comment lexer

llvm-svn: 172924

11 years agoComment parsing: add more tests for html character references
Dmitri Gribenko [Sat, 19 Jan 2013 22:04:44 +0000 (22:04 +0000)]
Comment parsing: add more tests for html character references

llvm-svn: 172923

11 years agoswitch a bunch of ASTReader to use the new BitstreamCursor::advance* methods,
Chris Lattner [Sat, 19 Jan 2013 21:39:22 +0000 (21:39 +0000)]
switch a bunch of ASTReader to use the new BitstreamCursor::advance* methods,
which hide a bunch of private details of the cursor from clients and simplify
their code.  More to come.

llvm-svn: 172922

11 years agofix method name.
Chris Lattner [Sat, 19 Jan 2013 21:37:14 +0000 (21:37 +0000)]
fix method name.

llvm-svn: 172921

11 years agorandom tidying
Chris Lattner [Sat, 19 Jan 2013 21:35:35 +0000 (21:35 +0000)]
random tidying

llvm-svn: 172920

11 years agoAdd a new BitstreamEntry concept, and add two helper methods for walking
Chris Lattner [Sat, 19 Jan 2013 21:35:24 +0000 (21:35 +0000)]
Add a new BitstreamEntry concept, and add two helper methods for walking
through a BitstreamCursor that produce it: advance() and
advanceSkippingSubblocks(), representing the two most common ways clients
want to walk through bitcode.

llvm-svn: 172919

11 years agoDocumentation: remove more mentions of Tcl
Dmitri Gribenko [Sat, 19 Jan 2013 20:35:18 +0000 (20:35 +0000)]
Documentation: remove more mentions of Tcl

Followup for r172836

llvm-svn: 172918

11 years agoDocumentation: replace some non-ASCII characters by equivalent markup
Dmitri Gribenko [Sat, 19 Jan 2013 20:34:20 +0000 (20:34 +0000)]
Documentation: replace some non-ASCII characters by equivalent markup

llvm-svn: 172917

11 years agoInclude Support/ELF.h instead of Object/ELF.h. It is much lighter and completely
Jakub Staszak [Sat, 19 Jan 2013 19:56:11 +0000 (19:56 +0000)]
Include Support/ELF.h instead of Object/ELF.h. It is much lighter and completely
sufficient.

llvm-svn: 172916

11 years ago[analyzer] Don't show "Entered 'foo'" if 'foo' is implicit.
Jordan Rose [Sat, 19 Jan 2013 19:52:57 +0000 (19:52 +0000)]
[analyzer] Don't show "Entered 'foo'" if 'foo' is implicit.

Before:
  Calling implicit default constructor for 'Foo'  (where Foo is constructed)
  Entered call from 'test'  (at "=default" or 'Foo' declaration)
  Calling default constructor for 'Bar'  (at "=default" or 'Foo' declaration)

After:
  Calling implicit default constructor for 'Foo'  (where Foo is constructed)
  Calling default constructor for 'Bar'  (at "=default" or 'Foo' declaration)

This only affects the plist diagnostics; this note is never shown in the
other diagnostics.

llvm-svn: 172915

11 years agoEmit the function type of member function pointer types the same as member functions.
David Blaikie [Sat, 19 Jan 2013 19:20:56 +0000 (19:20 +0000)]
Emit the function type of member function pointer types the same as member functions.

Adding the pseudo first parameter to a member function pointer's function type
and mark it as artificial.

Combined with a fix to GDB ( http://sourceware.org/bugzilla/show_bug.cgi?id=14998 )
this fixes gdb.cp/member-ptr.exp with Clang.

llvm-svn: 172911

11 years agolibclangSerialization also depends on the bitreader.
Benjamin Kramer [Sat, 19 Jan 2013 19:10:12 +0000 (19:10 +0000)]
libclangSerialization also depends on the bitreader.

llvm-svn: 172910

11 years agoupdate header comment.
Chris Lattner [Sat, 19 Jan 2013 18:47:35 +0000 (18:47 +0000)]
update header comment.

llvm-svn: 172909

11 years agothese need the bitcode reader as well.
Chris Lattner [Sat, 19 Jan 2013 18:45:35 +0000 (18:45 +0000)]
these need the bitcode reader as well.

llvm-svn: 172908

11 years agofix the unit tests too.
Chris Lattner [Sat, 19 Jan 2013 18:30:39 +0000 (18:30 +0000)]
fix the unit tests too.

llvm-svn: 172907

11 years agothese now depend on the bitcode reader too.
Chris Lattner [Sat, 19 Jan 2013 18:28:24 +0000 (18:28 +0000)]
these now depend on the bitcode reader too.

llvm-svn: 172906

11 years agothis depends on the bitcode reader, since it is using it.
Chris Lattner [Sat, 19 Jan 2013 18:24:13 +0000 (18:24 +0000)]
this depends on the bitcode reader, since it is using it.

llvm-svn: 172905

11 years agoBitstreamReader hasn't aged well. It's been hacked on by various people and
Chris Lattner [Sat, 19 Jan 2013 18:19:39 +0000 (18:19 +0000)]
BitstreamReader hasn't aged well.  It's been hacked on by various people and
has past the point of making sense.  Lets tidy things up: first step, moving
a ton of big functions out of line.

llvm-svn: 172904

11 years agocmake: Install all polly include files
Tobias Grosser [Sat, 19 Jan 2013 14:17:52 +0000 (14:17 +0000)]
cmake: Install all polly include files

Contributed-by: Richard Membarth <richard.membarth@informatik.uni-erlangen.de>
llvm-svn: 172903

11 years agoLoopVectorizer: Emit memory checks into their own basic block.
Benjamin Kramer [Sat, 19 Jan 2013 13:57:58 +0000 (13:57 +0000)]
LoopVectorizer: Emit memory checks into their own basic block.

This separates the check for "too few elements to run the vector loop" from the
"memory overlap" check, giving a lot nicer code and allowing to skip the memory
checks when we're not going to execute the vector code anyways. We still leave
the decision of whether to emit the memory checks as branches or setccs, but it
seems to be doing a good job. If ugly code pops up we may want to emit them as
separate blocks too. Small speedup on MultiSource/Benchmarks/MallocBench/espresso.

Most of this is legwork to allow multiple bypass blocks while updating PHIs,
dominators and loop info.

llvm-svn: 172902

11 years ago[cindex.py] Add cache for CompletionChunk spellings
Tobias Grosser [Sat, 19 Jan 2013 11:03:44 +0000 (11:03 +0000)]
[cindex.py] Add cache for CompletionChunk spellings

Most of the CompletionChunks represent braces, colons or other one
character spellings. There is no need to call libclang, to figure out
how to write a colon. Instead we use an internal cache to retrieve the
correct spelling. As function calls from python are very expensive and
this is a performance critical part of auto completion this patch makes
formatting of auto completion results a lot faster.

Formatting time changes from 0.57 to 0.45 seconds

llvm-svn: 172901

11 years ago[cindex.py] Replace CachedProperty with our own implementation
Tobias Grosser [Sat, 19 Jan 2013 11:03:42 +0000 (11:03 +0000)]
[cindex.py] Replace CachedProperty with our own implementation

This is a very performance critical point for auto completion. The manual
implementation gives a large speedup. As it does not complicate the code a lot,
I figured it is worth the change. If anybody understands why the CachedProperty
is here so much slower, I am very interested in working on an improvement of
CachedProperty.

Formatting time changes from 0.72 to 0.57 seconds.

llvm-svn: 172900

11 years ago[cindex.py]: Speed up lookup of the completion kind
Tobias Grosser [Sat, 19 Jan 2013 11:03:40 +0000 (11:03 +0000)]
[cindex.py]: Speed up lookup of the completion kind

We can directly the number of the kind instead of going through the
completionChunkKindMap.

Formatting time changes from 0.84 to 0.72 seconds.

llvm-svn: 172899

11 years agoReplace the 'final' keyword with 'LLVM_FINAL' as GCC 4.6 doesn't support
Chandler Carruth [Sat, 19 Jan 2013 09:57:51 +0000 (09:57 +0000)]
Replace the 'final' keyword with 'LLVM_FINAL' as GCC 4.6 doesn't support
the keyword.

If anyone cares deeply about the final optimizations with GCC, we might
want to add a version test to the LLVM definition, but I'm perfectly
happy with this just only firing under Clang and modern MSVC builds.

llvm-svn: 172898

11 years agoAllow the LLD CMake build to work with -std=gnu++0x and -std=gnu++11 as
Chandler Carruth [Sat, 19 Jan 2013 09:41:42 +0000 (09:41 +0000)]
Allow the LLD CMake build to work with -std=gnu++0x and -std=gnu++11 as
well as c++0x and c++11. This can be especially useful when building
with GCC in C++11 mode.

llvm-svn: 172897

11 years agoFix the build with libstdc++ v4.6 on Linux by supplying an explicit move
Chandler Carruth [Sat, 19 Jan 2013 09:38:14 +0000 (09:38 +0000)]
Fix the build with libstdc++ v4.6 on Linux by supplying an explicit move
assignment operator. There is an issue where classes with deleted copy
constructors and user defined move constructors end up with an
implicitly deleted copy constructor that is selected instead of the
implicit move constructor. This is a bit of a hack, but it allows me to
build LLD in a bootstrap with libstdc++ which is my primary goal.

llvm-svn: 172896

11 years agoRe-sort the #include lines which have gotten out of order.
Chandler Carruth [Sat, 19 Jan 2013 09:10:38 +0000 (09:10 +0000)]
Re-sort the #include lines which have gotten out of order.

llvm-svn: 172895

11 years agoOn Sandybridge split unaligned 256bit stores into two xmm-sized stores.
Nadav Rotem [Sat, 19 Jan 2013 08:38:41 +0000 (08:38 +0000)]
On Sandybridge split unaligned 256bit stores into two xmm-sized stores.

llvm-svn: 172894

11 years agoUse MVT instead of EVT when computing shuffle immediates since they can only be for...
Craig Topper [Sat, 19 Jan 2013 08:27:45 +0000 (08:27 +0000)]
Use MVT instead of EVT when computing shuffle immediates since they can only be for legal types. Keeps compiler from generating unneeded checks and handling for extended types.

llvm-svn: 172893

11 years agoRe-sort all the headers. Lots of regressions have crept in here.
Chandler Carruth [Sat, 19 Jan 2013 08:09:44 +0000 (08:09 +0000)]
Re-sort all the headers. Lots of regressions have crept in here.
Manually fix the order of UnwrappedLineParser.cpp as that one didn't
have its associated header as the first header.

This also uncovered a subtle inclusion order dependency as CLog.h didn't
include LLVM.h to pick up using declarations it relied upon.

llvm-svn: 172892

11 years agoSort all of the includes. Several files got checked in with mis-sorted
Chandler Carruth [Sat, 19 Jan 2013 08:03:47 +0000 (08:03 +0000)]
Sort all of the includes. Several files got checked in with mis-sorted
includes.

llvm-svn: 172891

11 years agoMove an input header file under an Inputs directory to be consistent
Chandler Carruth [Sat, 19 Jan 2013 06:31:24 +0000 (06:31 +0000)]
Move an input header file under an Inputs directory to be consistent
with other auxilliary test inputs and simplify the identification of
inputs to tests.

llvm-svn: 172890

11 years agoReapply r172878 with test case.
Ted Kremenek [Sat, 19 Jan 2013 04:33:14 +0000 (04:33 +0000)]
Reapply r172878 with test case.

llvm-svn: 172888

11 years ago<rdar://problem/12350715>
Jason Molenda [Sat, 19 Jan 2013 03:53:42 +0000 (03:53 +0000)]
<rdar://problem/12350715>

Modify UnwindLLDB::SearchForSavedLocationForRegister so if the register
save locations for a register mid-stack is in another register (or in the
same register, indicating the reg wasn't modified in this frame), don't
return that as a found location.  Keep iterating down the array of frames
until a concrete location/value for the register is found, or until we
get to frame 0 where the reg value can be used as-is.

If lldb was trying to backtrace a program that blew out its stack via
recursion and the unwind instructions had some kind of
this-reg-is-saved-in-that-reg instruction, lldb would revert to doing
a recursive search for a concrete value and blow out its own stack.

llvm-svn: 172887

11 years agoFix five more cases of tokens which can legally follow a type specifier.
Richard Smith [Sat, 19 Jan 2013 03:48:05 +0000 (03:48 +0000)]
Fix five more cases of tokens which can legally follow a type specifier.

llvm-svn: 172886

11 years ago[PCH/Modules] Revert r172843, it caused a module to fail building.
Argyrios Kyrtzidis [Sat, 19 Jan 2013 03:14:56 +0000 (03:14 +0000)]
[PCH/Modules] Revert r172843, it caused a module to fail building.

llvm-svn: 172884