llvm/lib
David Majnemer 5a1a1856a4 Windows: Add support for unicode command lines
Summary:
The MSVCRT deliberately sends main() code-page specific characters.
This isn't too useful to LLVM as we end up converting the arguments to
UTF-16 and subsequently attempt to use the result as, for example, a
file name.  Instead, we need to have the ability to access the Unicode
command line and transform it to UTF-8.

This has the distinct advantage over using the MSVC-specific wmain()
function as our entry point because:
 - It doesn't work on cygwin.
 - It only work on MinGW with caveats and only then on certain versions.
 - We get to keep our entry point as main(). :)

N.B.  This patch includes fixes to other parts of lib/Support/Windows
s.t. we would be able to take advantage of getting the Unicode paths.
E.G.  clang spawning clang -cc1 would want to give it Unicode arguments.

Reviewers: aaron.ballman, Bigcheese, rnk, ruiu

Reviewed By: rnk

CC: llvm-commits, ygao

Differential Revision: http://llvm-reviews.chandlerc.com/D1834

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192069 91177308-0d34-0410-b5e6-96231b3b80d8
2013-10-06 20:25:49 +00:00
..
Analysis Rename DataLayout variables TD -> DL 2013-10-03 19:50:01 +00:00
AsmParser Add support for aliases with linkonce_odr. 2013-10-06 15:10:43 +00:00
Bitcode AutoUpgrade: upgrade from scalar TBAA format to struct-path aware TBAA format. 2013-09-28 00:22:27 +00:00
CodeGen Add support for aliases with linkonce_odr. 2013-10-06 15:10:43 +00:00
DebugInfo [DebugInfo] Further simplify DWARFDebugAranges public interface 2013-10-02 07:12:47 +00:00
ExecutionEngine Adding multiple GOT handling to RuntimeDyldELF 2013-10-05 01:52:09 +00:00
IR Add support for aliases with linkonce_odr. 2013-10-06 15:10:43 +00:00
IRReader Add 'const' qualifiers to static const char* variables. 2013-07-16 01:17:10 +00:00
Linker Implement function prefix data as an IR feature. 2013-09-16 01:08:15 +00:00
LTO Remove some really nasty uses of hasRawTextSupport. 2013-10-05 16:42:21 +00:00
MC Remove some really nasty uses of hasRawTextSupport. 2013-10-05 16:42:21 +00:00
Object Object/COFF: Rename getXXX{Begin,End} -> xxx_{begin,end}. 2013-09-27 21:47:05 +00:00
Option Fix another mistake in r190442. 2013-09-10 23:22:56 +00:00
Support Windows: Add support for unicode command lines 2013-10-06 20:25:49 +00:00
TableGen Add an error check for a typo I accidentally made in a td file that caused an assert to fire. 2013-08-20 04:22:09 +00:00
Target X86: Don't fold spills into SSE operations if the stack is unaligned. 2013-10-06 13:48:22 +00:00
Transforms UpdatePHINodes in BasicBlockUtils should not crash on duplicate predecessors 2013-10-04 23:41:05 +00:00
CMakeLists.txt Move LTO support library to a component, allowing it to be tested 2013-09-24 23:52:22 +00:00
LLVMBuild.txt Move LTO support library to a component, allowing it to be tested 2013-09-24 23:52:22 +00:00
Makefile Move LTO support library to a component, allowing it to be tested 2013-09-24 23:52:22 +00:00