Commit Graph

20 Commits

Author SHA1 Message Date
Eli Friedman fcec630a57 Fix the representation of wide strings in the AST and IR so that it uses the native representation of integers for the elements. This fixes a bunch of nastiness involving
treating wide strings as a series of bytes.

Patch by Seth Cantrell.

llvm-svn: 143417
2011-11-01 02:23:42 +00:00
Richard Smith 9ca5c42582 Update all tests other than Driver/std.cpp to use -std=c++11 rather than
-std=c++0x. Patch by Ahmed Charles!

llvm-svn: 141900
2011-10-13 22:29:44 +00:00
Eric Christopher b58b3e879d Make constant aggregate constant initializers private linkage.
After talking with John making this the case for all of these is
the right way to go.

Fixes rdar://9804564 and PR10414

llvm-svn: 138418
2011-08-24 00:33:55 +00:00
Craig Topper 6d64a738fa Add tests for string literal concatenation.
llvm-svn: 137302
2011-08-11 05:57:09 +00:00
Craig Topper 54edccafc5 Add support for C++0x raw string literals.
llvm-svn: 137298
2011-08-11 04:06:15 +00:00
John McCall 9b24df470d Emit wide string literals with the appropriate alignment.
Patch by Craig Topper and Sundeep!

llvm-svn: 136856
2011-08-04 01:03:22 +00:00
Douglas Gregor 5e6fcb108f This patch makes the string/character literal tests run in C,
C++98/03, and C++0x mode, from Craig Topper!

llvm-svn: 136443
2011-07-29 01:08:54 +00:00
Douglas Gregor fb65e592e0 Add support for C++0x unicode string and character literals, from Craig Topper!
llvm-svn: 136210
2011-07-27 05:40:30 +00:00
Eli Friedman b857842c48 Add unnamed_addr to internal globals which are only used as an operand to memcpy. (Spotted by looking at IR.)
llvm-svn: 132226
2011-05-27 22:32:55 +00:00
Eli Friedman 6ffb623a52 Match llvm-gcc's string literals alignment by forcing alignment on string literals to 1. This can significantly impact the size of the string data, and as far as I know, the alignment doesn't help performance. rdar://9078969 .
llvm-svn: 132223
2011-05-27 22:13:20 +00:00
Rafael Espindola b7f60e3474 Add unnamed_addr when creating artificial string globals. For example, in
static const char foo[] = "foo";
static const char *bar = "bar";

the global created to hold "bar" will have it, but foo will not.

llvm-svn: 123192
2011-01-10 22:34:03 +00:00
Daniel Dunbar 29b8fb1771 tests: Force a triple to avoid wchar_t differences.
llvm-svn: 115970
2010-10-07 20:16:00 +00:00
Nico Weber 9762e0a234 Add support for 4-byte UCNs like \U12345678. Warn about UCNs in c90 mode.
llvm-svn: 115743
2010-10-06 04:57:26 +00:00
Daniel Dunbar 8fbe78f6fc Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'.
- This is designed to make it obvious that %clang_cc1 is a "test variable"
   which is substituted. It is '%clang_cc1' instead of '%clang -cc1' because it
   can be useful to redefine what gets run as 'clang -cc1' (for example, to set
   a default target).

llvm-svn: 91446
2009-12-15 20:14:24 +00:00
Daniel Dunbar a45cf5b6b0 Rename clang to clang-cc.
Tests and drivers updated, still need to shuffle dirs.

llvm-svn: 67602
2009-03-24 02:24:46 +00:00
Chris Lattner d42c29f9a2 fix some sema problems with wide strings and hook up basic codegen for them.
llvm-svn: 65582
2009-02-26 23:01:51 +00:00
Chris Lattner 75441a3870 eliminate some random .ll file outputs
llvm-svn: 63117
2009-01-27 18:56:08 +00:00
Daniel Dunbar 19d84c3c51 Update a number of CodeGen tests to not create .ll files in the test
directory.
 - Removed .ll from the svn:ignore lists to try and prevent this.
 - Added svn:ignore on test/Misc/Output

llvm-svn: 55104
2008-08-21 02:51:29 +00:00
Chris Lattner 40ad6cd854 no need to verify this, no errors/warnings are expected.
llvm-svn: 45371
2007-12-27 20:31:56 +00:00
Seo Sanghyeon 6f1b274976 String literal in aggregate expression
llvm-svn: 45330
2007-12-23 03:11:58 +00:00