[PATCH] D92902: [llvm-elfabi] Add flag to keep timestamp when output is the same

Dominik Montada via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 28 00:18:54 PST 2021


gargaroff added a comment.

In D92902#2527273 <https://reviews.llvm.org/D92902#2527273>, @haowei wrote:

> Do you mean this patch failed on windows pre-merge checks? It didn't happen when I commit my change though.  Do you have a link for that?
>
> I also cannot reproduce the same error on my personal windows desktop using gnuwin32:
>
>   C:\Users\Zero\Downloads\GnuBin\GetGnuWin32\bin>touch.exe --help
>   Usage: touch.exe [OPTION]... FILE...
>   Update the access and modification times of each FILE to the current time.
>   
>   Mandatory arguments to long options are mandatory for short options too.
>     -a                     change only the access time
>     -c, --no-create        do not create any files
>     -d, --date=STRING      parse STRING and use it instead of current time
>     -f                     (ignored)
>     -m                     change only the modification time
>     -r, --reference=FILE   use this file's times instead of current time
>     -t STAMP               use [[CC]YY]MMDDhhmm[.ss] instead of current time
>     --time=WORD            change the specified time:
>                              WORD is access, atime, or use: equivalent to -a
>                              WORD is modify or mtime: equivalent to -m
>         --help     display this help and exit
>         --version  output version information and exit
>   
>   Note that the -d and -t options accept different time-date formats.
>   
>   Report bugs to <bug-coreutils at gnu.org>.
>   
>   C:\Users\Zero\Downloads\GnuBin\GetGnuWin32\bin>touch.exe -m -t 197001010000 wget.ini
>   
>   C:\Users\Zero\Downloads\GnuBin\GetGnuWin32\bin>dir wget.ini
>    Volume in drive C has no label.
>   
>    Directory of C:\Users\Zero\Downloads\GnuBin\GetGnuWin32\bin
>   
>   01/01/1970  00:00             4,021 wget.ini
>                  1 File(s)          4,021 bytes
>                  0 Dir(s)  1,046,724,939,776 bytes free
>   
>   C:\Users\Zero\Downloads\GnuBin\GetGnuWin32\bin>
>
> On my machine the touch.exe has no trouble to parse the timestamp used in the unit test.

Hm, that's interesting. I don't mean the pre-merge-checks that are run here in Phabricator. I didn't see any x86-64 Windows build bot that runs the `check-all` target, so I assumed that those tests simply weren't run on Windows and this problem never got noticed.
I'm currently setting up a Windows pipeline for our downstream repository and I used the Dockerfile from the pre-merge-checks as base, only commented-out the `pip install` command and the `activeperl` install (because they were failing for some reason). Running the tests inside that container makes these two tests fail with the error message I described. Could it be that GnuWin32 was updated recently and broke that behavior? Or could it be somehow related to the installed language pack of the host system? Running Windows Server 2019 btw.

In any case, if it's working on your side, then there must be something wrong with my setup for some reason. I'll try to figure it out or just update the tests in our downstream repo. The Windows container does seem quite brittle after all. Sorry for bothering and thanks for checking anyway!


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D92902/new/

https://reviews.llvm.org/D92902



More information about the llvm-commits mailing list