r240350 - [modules] When building a module, if there are multiple matches for a header

İsmail Dönmez ismail at donmez.ws
Tue Jun 23 01:21:08 PDT 2015


On Tue, Jun 23, 2015 at 1:20 AM, Richard Smith
<richard-llvm at metafoo.co.uk> wrote:
> Author: rsmith
> Date: Mon Jun 22 17:20:47 2015
> New Revision: 240350
>
> URL: http://llvm.org/viewvc/llvm-project?rev=240350&view=rev
> Log:
> [modules] When building a module, if there are multiple matches for a header
> file in the loaded module maps and one of them is from the current module,
> that's the right match.
>
> Added:
>     cfe/trunk/test/Modules/Inputs/explicit-build-prefer-self/
>     cfe/trunk/test/Modules/Inputs/explicit-build-prefer-self/a.h
>     cfe/trunk/test/Modules/Inputs/explicit-build-prefer-self/b.h
>     cfe/trunk/test/Modules/Inputs/explicit-build-prefer-self/map
>     cfe/trunk/test/Modules/Inputs/explicit-build-prefer-self/x.h
>     cfe/trunk/test/Modules/explicit-build-prefer-self.cpp
> Modified:
>     cfe/trunk/lib/Lex/ModuleMap.cpp

Hi, either this or one of the other modules changes after this breaks
with MSVC 2013 here:

FAIL: Clang :: Modules/modules-with-same-name.m (4118 of 8281)
******************** TEST 'Clang :: Modules/modules-with-same-name.m'
FAILED ********************
Script:
--
rm -rf C:\cygwin64\home\ismail\src\llvm\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp
C:/cygwin64/home/ismail/src/llvm/dist/./bin/clang.EXE -cc1
-internal-isystem C:\cygwin64\home\ismail\src\llvm\dist\bin\..\li
b\clang\3.7.0\include -nostdsysteminc -fmodules -fimplicit-module-maps
-fmodules-cache-path=C:\cygwin64\home\ismail\src\llvm
\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp
-fmodules-ignore-macro=EXPECTED_PATH -fmodules-ignore-mac
ro=DIRECT -fsyntax-only
C:\cygwin64\home\ismail\src\llvm\tools\clang\test\Modules\modules-with-same-name.m
-verify -I C:\cyg
win64\home\ismail\src\llvm\tools\clang\test\Modules/Inputs/modules-with-same-name/path1/A
-DDIRECT -DEXPECTED_PATH=1
C:/cygwin64/home/ismail/src/llvm/dist/./bin/clang.EXE -cc1
-internal-isystem C:\cygwin64\home\ismail\src\llvm\dist\bin\..\li
b\clang\3.7.0\include -nostdsysteminc -fmodules -fimplicit-module-maps
-fmodules-cache-path=C:\cygwin64\home\ismail\src\llvm
\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp
-fmodules-ignore-macro=EXPECTED_PATH -fmodules-ignore-mac
ro=DIRECT -fsyntax-only
C:\cygwin64\home\ismail\src\llvm\tools\clang\test\Modules\modules-with-same-name.m
-verify -I C:\cyg
win64\home\ismail\src\llvm\tools\clang\test\Modules/Inputs/modules-with-same-name/path2/A
-DDIRECT -DEXPECTED_PATH=2
find C:\cygwin64\home\ismail\src\llvm\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp
-name "A-*.pcm" | C:
/cygwin64/home/ismail/src/llvm/dist/./bin\count.EXE 2
C:/cygwin64/home/ismail/src/llvm/dist/./bin/clang.EXE -cc1
-internal-isystem C:\cygwin64\home\ismail\src\llvm\dist\bin\..\li
b\clang\3.7.0\include -nostdsysteminc -fmodules -fimplicit-module-maps
-fmodules-cache-path=C:\cygwin64\home\ismail\src\llvm
\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp
-fmodules-ignore-macro=EXPECTED_PATH -fmodules-ignore-mac
ro=DIRECT -fsyntax-only
C:\cygwin64\home\ismail\src\llvm\tools\clang\test\Modules\modules-with-same-name.m
-verify -I C:\cyg
win64\home\ismail\src\llvm\tools\clang\test\Modules/Inputs/modules-with-same-name/DependsOnA
-I C:\cygwin64\home\ismail\src\
llvm\tools\clang\test\Modules/Inputs/modules-with-same-name/path1/A
-DEXPECTED_PATH=1
find C:\cygwin64\home\ismail\src\llvm\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp
-name "*.pcm" | C:/c
ygwin64/home/ismail/src/llvm/dist/./bin\count.EXE 3
C:/cygwin64/home/ismail/src/llvm/dist/./bin/clang.EXE -cc1
-internal-isystem C:\cygwin64\home\ismail\src\llvm\dist\bin\..\li
b\clang\3.7.0\include -nostdsysteminc -fmodules -fimplicit-module-maps
-fmodules-cache-path=C:\cygwin64\home\ismail\src\llvm
\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp
-fmodules-ignore-macro=EXPECTED_PATH -fmodules-ignore-mac
ro=DIRECT -fsyntax-only
C:\cygwin64\home\ismail\src\llvm\tools\clang\test\Modules\modules-with-same-name.m
-verify -I C:\cyg
win64\home\ismail\src\llvm\tools\clang\test\Modules/Inputs/modules-with-same-name/DependsOnA
-I C:\cygwin64\home\ismail\src\
llvm\tools\clang\test\Modules/Inputs/modules-with-same-name/path2/A
-DEXPECTED_PATH=2
find C:\cygwin64\home\ismail\src\llvm\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp
-name "*.pcm" | C:/c
ygwin64/home/ismail/src/llvm/dist/./bin\count.EXE 3
--
Exit Code: 1

Command Output (stdout):
--
Command 0: "rm" "-rf"
"C:\cygwin64\home\ismail\src\llvm\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp"
Command 0 Result: 0
Command 0 Output:


Command 0 Stderr:


Command 1: "C:/cygwin64/home/ismail/src/llvm/dist/./bin/clang.EXE"
"-cc1" "-internal-isystem" "C:\cygwin64\home\ismail\src\l
lvm\dist\bin\..\lib\clang\3.7.0\include" "-nostdsysteminc" "-fmodules"
"-fimplicit-module-maps" "-fmodules-cache-path=C:\cyg
win64\home\ismail\src\llvm\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp"
"-fmodules-ignore-macro=EXPECT
ED_PATH" "-fmodules-ignore-macro=DIRECT" "-fsyntax-only"
"C:\cygwin64\home\ismail\src\llvm\tools\clang\test\Modules\modules-
with-same-name.m" "-verify" "-I"
"C:\cygwin64\home\ismail\src\llvm\tools\clang\test\Modules/Inputs/modules-with-same-name/pa
th1/A" "-DDIRECT" "-DEXPECTED_PATH=1"
Command 1 Result: 0
Command 1 Output:
Command 1 Stderr:
                                         [8657/45789]


Command 2: "C:/cygwin64/home/ismail/src/llvm/dist/./bin/clang.EXE"
"-cc1" "-internal-isystem" "C:\cygwin64\home\ismail\src\l
lvm\dist\bin\..\lib\clang\3.7.0\include" "-nostdsysteminc" "-fmodules"
"-fimplicit-module-maps" "-fmodules-cache-path=C:\cyg
win64\home\ismail\src\llvm\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp"
"-fmodules-ignore-macro=EXPECT
ED_PATH" "-fmodules-ignore-macro=DIRECT" "-fsyntax-only"
"C:\cygwin64\home\ismail\src\llvm\tools\clang\test\Modules\modules-
with-same-name.m" "-verify" "-I"
"C:\cygwin64\home\ismail\src\llvm\tools\clang\test\Modules/Inputs/modules-with-same-name/pa
th2/A" "-DDIRECT" "-DEXPECTED_PATH=2"
Command 2 Result: 0
Command 2 Output:


Command 2 Stderr:


Command 3: "find"
"C:\cygwin64\home\ismail\src\llvm\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp"
"-nam
e" "A-*.pcm"
Command 3 Result: 0
Command 3 Output:


Command 3 Stderr:


Command 4: "C:/cygwin64/home/ismail/src/llvm/dist/./bin\count.EXE" "2"
Command 4 Result: 0
Command 4 Output:


Command 4 Stderr:


Command 5: "C:/cygwin64/home/ismail/src/llvm/dist/./bin/clang.EXE"
"-cc1" "-internal-isystem" "C:\cygwin64\home\ismail\src\l
lvm\dist\bin\..\lib\clang\3.7.0\include" "-nostdsysteminc" "-fmodules"
"-fimplicit-module-maps" "-fmodules-cache-path=C:\cyg
win64\home\ismail\src\llvm\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp"
"-fmodules-ignore-macro=EXPECT
ED_PATH" "-fmodules-ignore-macro=DIRECT" "-fsyntax-only"
"C:\cygwin64\home\ismail\src\llvm\tools\clang\test\Modules\modules-
with-same-name.m" "-verify" "-I"
"C:\cygwin64\home\ismail\src\llvm\tools\clang\test\Modules/Inputs/modules-with-same-name/De
pendsOnA" "-I" "C:\cygwin64\home\ismail\src\llvm\tools\clang\test\Modules/Inputs/modules-with-same-name/path1/A"
"-DEXPECTED
_PATH=1"
Command 5 Result: 0
Command 5 Output:


Command 5 Stderr:


Command 6: "find"
"C:\cygwin64\home\ismail\src\llvm\dist\tools\clang\test\Modules\Output\modules-with-same-name.m.tmp"
"-nam
e" "*.pcm"
Command 6 Result: 1
Command 6 Output:


Command 6 Stderr:
find: paths must precede expression: b.pcm
Usage: find [-H] [-L] [-P] [-Olevel] [-D
help|tree|search|stat|rates|opt|exec] [path...] [expression]



Command 7: "C:/cygwin64/home/ismail/src/llvm/dist/./bin\count.EXE" "3"
Command 7 Result: 1
Command 7 Output:


Command 7 Stderr:
Expected 3 lines, got 0.



--

********************



More information about the cfe-commits mailing list