Index: llvm/trunk/.gitattributes =================================================================== --- llvm/trunk/.gitattributes +++ llvm/trunk/.gitattributes @@ -0,0 +1,12 @@ +# binary files +test/Object/Inputs/*.a-* binary +test/tools/dsymutil/Inputs/* binary +test/tools/llvm-ar/Inputs/*.lib binary +test/tools/llvm-objdump/Inputs/*.a binary +test/tools/llvm-rc/Inputs/* binary +test/tools/llvm-strings/Inputs/numbers binary +test/MC/AsmParser/incbin_abcd binary +test/YAMLParser/spec-09-02.test binary + +# Windows line ending test +test/MC/AsmParser/preserve-comments-crlf.s text eol=crlf Index: llvm/trunk/docs/GettingStartedVS.rst =================================================================== --- llvm/trunk/docs/GettingStartedVS.rst +++ llvm/trunk/docs/GettingStartedVS.rst @@ -76,6 +76,11 @@ * With anonymous Subversion access: + *Note:* some regression tests require Unix-style line ending (``\n``). To + pass all regression tests, please add two lines *enable-auto-props = yes* + and *\* = svn:mime-type=application/octet-stream* to + ``C:\Users\\AppData\Roaming\Subversion\config``. + 1. ``cd `` 2. ``svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm`` 3. ``cd llvm`` Index: llvm/trunk/lib/MC/MCParser/AsmLexer.cpp =================================================================== --- llvm/trunk/lib/MC/MCParser/AsmLexer.cpp +++ llvm/trunk/lib/MC/MCParser/AsmLexer.cpp @@ -210,6 +210,8 @@ int CurChar = getNextChar(); while (CurChar != '\n' && CurChar != '\r' && CurChar != EOF) CurChar = getNextChar(); + if (CurChar == '\r' && CurPtr != CurBuf.end() && *CurPtr == '\n') + ++CurPtr; // If we have a CommentConsumer, notify it about the comment. if (CommentConsumer) { Index: llvm/trunk/test/MC/AsmParser/preserve-comments-crlf.s =================================================================== --- llvm/trunk/test/MC/AsmParser/preserve-comments-crlf.s +++ llvm/trunk/test/MC/AsmParser/preserve-comments-crlf.s @@ -0,0 +1,13 @@ + #RUN: llvm-mc -preserve-comments -n -triple i386-linux-gnu < %s > %t + #RUN: diff %s %t + .text + +foo: #Comment here + #comment here + nop + #if DIRECTIVE COMMENT + ## WHOLE LINE COMMENT + cmpl $196, %eax ## EOL COMMENT + #endif + .ident "clang version 3.9.0" + .section ".note.GNU-stack","",@progbits