Commit Graph

143414 Commits

Author SHA1 Message Date
Guy Benyei 83c74e9fad Add static cast to unsigned char whenever a character classification function is called with a signed char argument, in order to avoid assertions in Windows Debug configuration.
llvm-svn: 175006
2013-02-12 21:21:59 +00:00
Dmitri Gribenko 4e472b6328 Add a test for r174980, that we used to accept
llvm-svn: 175005
2013-02-12 20:43:41 +00:00
Daniel Jasper f52ab8d60c Fix crash for incomplete labels in macros.
Still the formatting can be improved, but at least we don't assert any
more. This happened when trying to format lib/Sema/SemaType.cpp.

llvm-svn: 175003
2013-02-12 20:17:17 +00:00
Daniel Malea 4d3c008c7d Fix document typos, indentation in python code, and API examples.
Patch by Bruce Mitchener!

llvm-svn: 175002
2013-02-12 20:01:49 +00:00
Dan Gohman f377160d2f Record PRE predecessors with a SmallVector instead of a DenseMap, and
avoid a second pred_iterator traversal.

llvm-svn: 175001
2013-02-12 19:49:10 +00:00
Chad Rosier 868d668e78 [ms-inline asm] Update test case now that we are correctly parsing __emit directives.
llvm-svn: 175000
2013-02-12 19:42:57 +00:00
Chad Rosier 5f6b4d3fc5 [ms-inline asm] Pass the length of the IDVal, so we can do a proper AsmRewrite.
llvm-svn: 174999
2013-02-12 19:42:32 +00:00
Chad Rosier 93d629fdb8 [ms-inline asm] Accept the emit directive as either _emit or __emit.
llvm-svn: 174998
2013-02-12 19:31:23 +00:00
Daniel Dunbar 62b943935d [tests] Add support for a link_flags lit parameter.
- This is useful for testing with custom ABI libraries.
 - Patch by Michael van der Westhuizen.

llvm-svn: 174997
2013-02-12 19:28:51 +00:00
Aaron Ballman 396088cdb5 Fixing the MSVC compiler warning a different way; removed use of static_cast and instead used a signed integer parameter.
llvm-svn: 174996
2013-02-12 19:20:48 +00:00
Chad Rosier e348d2724a Typo.
llvm-svn: 174995
2013-02-12 19:15:05 +00:00
Dan Gohman 2001cd8f9e When disabling PRE for a value is directly redundant with itself
(through a loop), don't continue to iterate through the reamining
predecessors.

llvm-svn: 174994
2013-02-12 19:05:10 +00:00
Greg Clayton faf6df6e6e Added new "env" regular expression alias into the evironment settings section of the GDB/LLDB commands.
llvm-svn: 174993
2013-02-12 18:54:34 +00:00
Krzysztof Parzyszek 5974de4e7d Remove target-specific info from the testcase for DWARF/pubnames.
llvm-svn: 174992
2013-02-12 18:53:21 +00:00
Greg Clayton ef5651d93f <rdar://problem/13178743>
Added a new "env" regular expression alias. If "env" is typed on its own "settings show target.env-vars" will be run. Otherwise it can be used to set and environment variable: "env FOO=BAR".

llvm-svn: 174991
2013-02-12 18:52:24 +00:00
Shankar Easwaran 0da6d71b54 add support for merging common strings
llvm-svn: 174990
2013-02-12 18:46:53 +00:00
Chad Rosier e90add40a9 [ms-inline asm] Add a few test cases for the parsing of hexidecimal integers.
llvm-svn: 174989
2013-02-12 18:45:21 +00:00
Dan Gohman fd41de0b10 Check that pointers are removed from maps before calling delete on the pointers,
for tidiness' sake.

llvm-svn: 174988
2013-02-12 18:44:43 +00:00
Greg Clayton d901096345 <rdar://problem/13184389>
_regexp-list needs to treat "list -" as "source list -r"

llvm-svn: 174987
2013-02-12 18:42:05 +00:00
Aaron Ballman cd9e4e6063 Removing a signed/unsigned mismatch warning triggered in MSVC 11.
llvm-svn: 174986
2013-02-12 18:39:15 +00:00
Dan Gohman f60667020a Minor code simplification.
llvm-svn: 174985
2013-02-12 18:38:36 +00:00
Matt Kopec 92dd5cfe04 Fix ELF parsing where undefined symbols were being added to the symbol table with the incorrect symbol type.
llvm-svn: 174984
2013-02-12 18:30:30 +00:00
Chad Rosier f72d06a919 [ms-inline asm] Add support for lexing binary integers with a [bB] suffix.
This is complicated by backward labels (e.g., 0b can be both a backward label
and a binary zero).  The current implementation assumes [0-9]b is always a
label and thus it's possible for 0b and 1b to not be interpreted correctly for
ms-style inline assembly.  However, this is relatively simple to fix in the
inline assembly (i.e., drop the [bB]).

This patch also limits backward labels to [0-9]b, so that only 0b and 1b are
ambiguous.
Part of rdar://12470373

llvm-svn: 174983
2013-02-12 18:29:02 +00:00
Dmitri Gribenko 1c3e3c1433 Documentation: HowToUseAttributes: formatting (use monospaced font)
llvm-svn: 174982
2013-02-12 18:26:08 +00:00
Krzysztof Parzyszek 228daa6986 Allow optionally generating pubnames section in DWARF info. Introduce
option "generate-dwarf-pubnames" to control it, set to "false" by default.

llvm-svn: 174981
2013-02-12 18:00:14 +00:00
Dmitri Gribenko d1c91f1763 Accept over-qualified constructor in MSVC emulation mode
MSVC accepts this:

class A {
  A::A();
};

Clang accepts regular member functions with extra qualification as an MS
extension, but not constructors.  This changes the parser to defer rejecting
qualified constructors so that the same Sema logic can apply to constructors as
regular member functions.  This also improves the error message when MS
extensions are disabled (in my opinion). Before it was:

/Users/jason/Desktop/test.cpp:2:8: error: expected member name or ';' after declaration specifiers
  A::A();
  ~~~~ ^
1 error generated.

After:

/Users/jason/Desktop/test.cpp:2:6: error: extra qualification on member 'A'
  A::A();
  ~~~^
1 error generated.

Patch by Jason Haslam.

llvm-svn: 174980
2013-02-12 17:27:41 +00:00
Kay Tiong Khoo c5c9713fcf added test cases for r174920 (prefetch disassembly)
llvm-svn: 174979
2013-02-12 17:07:44 +00:00
Daniel Jasper 2204562acd Fix bug in the adjustment to existing lines.
Before (if only the second line was reformatted):
void f() {}
          void g() {}

After:
void f() {}
void g() {}

llvm-svn: 174978
2013-02-12 16:51:23 +00:00
Sergei Larin 5e76aa9714 Equal treatment of labels and other terminators in MI DAG construction.
MI sched DAG construction allows targets to include terminators into scheduling DAG.
Extend this functionality to labels as well.

llvm-svn: 174977
2013-02-12 16:36:03 +00:00
Krzysztof Parzyszek 97438dc75e Add support for the pubnames section to llvm-dwarfdump.
llvm-svn: 174976
2013-02-12 16:20:28 +00:00
Nico Weber 4444917f5c Formatter: Correctly format stars in `sizeof(int**)` and similar places.
This redoes how '*' and '&' are classified as pointer / reference markers when
followed by ')', '>', or ','.

Previously, determineStarAmpUsage() marked a single '*' and '&' followed by
')', '>', or ',' as pointer or reference marker. Now, all '*'s and '&'s
preceding ')', '>', or ',' are marked as pointer / reference markers. Fixes
PR14884.

Since only the last '*' in 'int ***' was marked as pointer before (the rest
were unary operators, which don't reach spaceRequiredBetween()),
spaceRequiredBetween() now had to be thought about handing multiple '*'s in
sequence.

Before:
  return sizeof(int * *);
  Type **A = static_cast<Type * *>(P);

Now:
  return sizeof(int**);
  Type **A = static_cast<Type **>(P);

While here, also make all methods of AnnotatingParser except parseLine()
private.

Review URL: http://llvm-reviews.chandlerc.com/D384

llvm-svn: 174975
2013-02-12 16:17:07 +00:00
Paul Redmond 7e7e3de43d Fix the lit test added in r174972
Patch by: Kevin Schoedel

llvm-svn: 174974
2013-02-12 16:07:27 +00:00
Jyotsna Verma 39f7a2b7a0 Hexagon: Add support to generate predicated absolute addressing mode
instructions.

llvm-svn: 174973
2013-02-12 16:06:23 +00:00
Paul Redmond 288604ed0c PR14562 - Truncation of left shift became undef
DAGCombiner::ReduceLoadWidth was converting (trunc i32 (shl i64 v, 32))
into (shl i32 v, 32) into undef. To prevent this, check the shift count
against the final result size.

Patch by: Kevin Schoedel
Reviewed by: Nadav Rotem

llvm-svn: 174972
2013-02-12 15:21:21 +00:00
Evgeniy Stepanov 71a4ab7141 [sanitizer] Tests for scanf parser in allowGnuMalloc=false mode.
llvm-svn: 174971
2013-02-12 14:37:55 +00:00
Evgeniy Stepanov e676f66fe3 [msan] Allow zero buf pointer in getcwd() interceptor.
llvm-svn: 174970
2013-02-12 14:36:22 +00:00
Evgeniy Stepanov b5ec3a2d55 [sanitizer] More accurate scanf parsing without GNU extensions.
In __isoc99_*scanf we don't have to worry about GNUisms, and can parse
%a accurately.

Patch by Jakub Jelinek.

llvm-svn: 174969
2013-02-12 14:29:34 +00:00
Justin Holewinski be8dc6499a [NVPTX] Disable vector registers
Vectors were being manually scalarized by the backend.  Instead,
let the target-independent code do all of the work.  The manual
scalarization was from a time before good target-independent support
for scalarization in LLVM. However, this forces us to specially-handle
vector loads and stores, which we can turn into PTX instructions that
produce/consume multiple operands.

llvm-svn: 174968
2013-02-12 14:18:49 +00:00
Edwin Vane e9dd3608ea Adding more overloads for allOf matcher
Adding overloads of allOf accepting 4 and 5 arguments.
    
Reviewer: klimek

llvm-svn: 174967
2013-02-12 13:55:40 +00:00
Timur Iskhodzhanov 584248cf3c Rename -constructors test to just -structors as in fact it tests dtors too. Also, fix a minor typo in the test.
llvm-svn: 174966
2013-02-12 13:22:47 +00:00
Evgeniy Stepanov a73704c0f8 [asan] Add new __isoc99_*scanf to ASan intercepted functions list.
llvm-svn: 174965
2013-02-12 12:45:29 +00:00
Alexander Potapenko 259e8127ad [ASan] Do not use kDefaultShort64bitShadowOffset on Mac, where the binaries may get mapped at 0x100000000+ and thus may interleave with the shadow.
llvm-svn: 174964
2013-02-12 12:41:12 +00:00
Michel Danzer 3bb17ebd93 R600: Fix regression with shadow array sampler on pre-SI GPUs.
'R600/SI: Use proper instructions for array/shadow samplers.' removed two
cases from TEX_SHADOW. Vincent Lejeune reported on IRC that this broke some
shadow array piglit tests with the r600g driver. Reinstating the removed
cases should fix this, and still works with radeonsi as well.

I will follow up with some lit tests which would have caught the regression.

NOTE: This is a candidate for the Mesa stable branch.

Tested-by: Vincent Lejeune <vljn@ovi.com>
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
llvm-svn: 174963
2013-02-12 12:11:23 +00:00
Evgeniy Stepanov d8cfb99a71 [sanitizer] Missing changes from r174960.
llvm-svn: 174962
2013-02-12 12:02:49 +00:00
Joe Abbey ba3e901e14 Adding a HowTo for Attributes.
This is based on Bill Wendling's email.  No additional content has been added,
but now there's a place for Attributes to capture future information.

llvm-svn: 174961
2013-02-12 11:45:22 +00:00
Evgeniy Stepanov 5fa8fb7d91 [sanitizer] Intercept __isoc99_*scanf.
llvm-svn: 174960
2013-02-12 11:34:52 +00:00
Kostya Serebryany e2e32b32e8 [asan] fix tests for the new ABI
llvm-svn: 174959
2013-02-12 11:14:24 +00:00
Kostya Serebryany 2659e96e4b [asan] change the default mapping offset on x86_64 to 0x7fff8000. This gives roughly 5% speedup. Since this is an ABI change, bump the asan ABI version by renaming __asan_init to __asan_init_v1. compiler-rt part
llvm-svn: 174958
2013-02-12 11:11:58 +00:00
Kostya Serebryany be73337ad2 [asan] change the default mapping offset on x86_64 to 0x7fff8000. This gives roughly 5% speedup. Since this is an ABI change, bump the asan ABI version by renaming __asan_init to __asan_init_v1. llvm part, compiler-rt part will follow
llvm-svn: 174957
2013-02-12 11:11:02 +00:00
Alexey Samsonov 93686fc6f1 [MSan] symbolize correct PC when printing Summary message
llvm-svn: 174956
2013-02-12 10:46:39 +00:00