Hi all, LLVM+clang builds fine under Cygwin 1.7, but "make check-all" fails to run because lit doesn't find the freshly built clang. The reason is as follows: in llvm/utils/lit/lit/Util.py, in the "which" method, there's 66: # Get suffixes to search. 67: pathext = os.environ.get('PATHEXT', '').split(os.pathsep) The problem is, PATHEXT is imported verbatim from the Windows environment into the Cygwin environment, so it contains for example PATHEXT=.COM;.EXE;.BAT;.CMD;.WSH However, under Cygwin os.pathsep is the Unix-style ':' rather than the Windows-style ';' so this fails to chop up PATHEXT. The end result is that the "which" method ends up looking for the file "clang.COM;.EXE;.BAT;.CMD;.WSH" with little success. If PATHEXT is only relevant on Windows, perhaps the split should be done with a hardcoded ';' instead of os.pathsep Otherwise, it should be the responsibility of the user to set PATHEXT to the appropriate form in his Cygwin environment, e.g. with something like this in .bashrc PATHEXT=`cygpath -p -u $PATHEXT` This should be documented in LLVM somewhere (perhaps in GettingStarted.html ?) Any opinions? P.S. With the above change, "make check-all" starts to run. Estimated run time: 40 hours on my 1.8GHz single-core Centrino laptop. (The same machine running Linux completed "make check-all" in 2min 30 sec!) Csaba -- GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++ Life is complex, with real and imaginary parts. "Ok, it boots. Which means it must be bug-free and perfect. " -- Linus Torvalds "People disagree with me. I just ignore them." -- Linus Torvalds
Good evening, Csaba! I think rather, Cygwin does not need to know what PATHEXT would be. A patch(0001) is attached. Another patch is for unittests. Lit does not find *Tests.exe in unittests on ToT. 2010/12/24 Csaba Raduly <rcsaba at gmail.com>:> P.S. > With the above change, "make check-all" starts to run. Estimated run > time: 40 hours on my 1.8GHz single-core Centrino laptop. (The same > machine running Linux completed "make check-all" in 2min 30 sec!)me2. I don't know why too slow. It seems executable files would not hit in disk cache. FYI, try ;) (to warm cache) $ (cd Release+Asserts; mkdir xxx; mv -v *.exe *.dll xxx; cp -v xxx/* .; rm -rfv xxx) ...Takumi -------------- next part --------------
On Fri, Dec 24, 2010 at 10:32 AM, NAKAMURA Takumi wrote:> Good evening, Csaba! > > I think rather, Cygwin does not need to know what PATHEXT would be.Yes, that does make sense. Cygwin doesn't need PATHEXT. With this patch, "make check-all" started to run on Cygwin. Only 24h to go... Csaba -- GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++ Life is complex, with real and imaginary parts. "Ok, it boots. Which means it must be bug-free and perfect. " -- Linus Torvalds "People disagree with me. I just ignore them." -- Linus Torvalds
On Fri, Dec 24, 2010 at 10:32 AM, NAKAMURA Takumi wrote:> me2. I don't know why too slow.I know now. It was a debug build (enable-optimized=no) created only for trying out your patch on Util.py. Doh! -- GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++ Life is complex, with real and imaginary parts. "Ok, it boots. Which means it must be bug-free and perfect. " -- Linus Torvalds "People disagree with me. I just ignore them." -- Linus Torvalds