r353729 - Attempt to pacify bots more after r353718 and r353725

Nico Weber via cfe-commits cfe-commits at lists.llvm.org
Tue Feb 12 04:41:06 PST 2019


Thanks for reporting that this depends on the host compiler.

I disabled the test again in r353836 and will look into why the output is
different depending on if host cc is gcc or clang.

On Tue, Feb 12, 2019 at 2:40 AM Mikael Holmén <mikael.holmen at ericsson.com>
wrote:

> Same thing for me with our downstream build bots.
>
> When we compile clang with gcc 7.4 and then run the testcase I get this
> output
>
> define dso_local i64 @test__shiftleft128(i64 %l, i64 %h, i8 %d)
> local_unnamed_addr #0 {
> entry:
>    %0 = zext i64 %l to i128
>    %1 = zext i64 %h to i128
>    %2 = shl nuw i128 %1, 64
>    %3 = or i128 %2, %0
>    %4 = and i8 %d, 63
>    %5 = zext i8 %4 to i128
>    %6 = shl i128 %3, %5
>    %7 = lshr i128 %6, 64
>    %8 = trunc i128 %7 to i64
>    ret i64 %8
> }
>
> and when I compile clang with clang 3.6 and run the test I get this:
>
> define dso_local i64 @test__shiftleft128(i64 %l, i64 %h, i8 %d)
> local_unnamed_addr #0 {
> entry:
>    %0 = zext i64 %h to i128
>    %1 = shl nuw i128 %0, 64
>    %2 = zext i64 %l to i128
>    %3 = or i128 %1, %2
>    %4 = and i8 %d, 63
>    %5 = zext i8 %4 to i128
>    %6 = shl i128 %3, %5
>    %7 = lshr i128 %6, 64
>    %8 = trunc i128 %7 to i64
>    ret i64 %8
> }
>
> /Mikael
>
> On 2/12/19 2:03 AM, Nico Weber via cfe-commits wrote:
> > Thank you for the .ll files!
> >
> > the -4.ll file you sent me contains:
> >
> > define dso_local i64 @"?test__shiftleft128@@YA_K_K0E at Z"(i64 %l, i64 %h,
> > i8 %d) local_unnamed_addr #0 {
> > entry:
> >    %0 = zext i64 %h to i128
> >    %1 = shl nuw i128 %0, 64
> >    %2 = zext i64 %l to i128
> >    %3 = or i128 %1, %2
> >    %4 = and i8 %d, 63
> >    %5 = zext i8 %4 to i128
> >    %6 = shl i128 %3, %5
> >    %7 = lshr i128 %6, 64
> >    %8 = trunc i128 %7 to i64
> >    ret i64 %8
> > }
> >
> > On my local system, I get
> >
> > ; Function Attrs: minsize norecurse nounwind optsize readnone
> > define dso_local i64 @test__shiftleft128(i64 %l, i64 %h, i8 %d)
> > local_unnamed_addr #0 {
> > entry:
> >    %0 = zext i64 %l to i128
> >    %1 = zext i64 %h to i128
> >    %2 = shl nuw i128 %1, 64
> >    %3 = or i128 %2, %0
> >    %4 = and i8 %d, 63
> >    %5 = zext i8 %4 to i128
> >    %6 = shl i128 %3, %5
> >    %7 = lshr i128 %6, 64
> >    %8 = trunc i128 %7 to i64
> >    ret i64 %8
> > }
> >
> > That's identical except for the order of the instructions (which in turn
> > changes some % numbers).
> >
> > That's surprising to me; I thought LLVM IR is deterministic (and if it
> > wasn't, many other tests wouldn't work either).
> >
> > On Mon, Feb 11, 2019 at 4:20 PM Galina Kistanova <gkistanova at gmail.com
> > <mailto:gkistanova at gmail.com>> wrote:
> >
> >     Hello Nico,
> >
> >     This builders fail on your test as well -
> >
> http://lab.llvm.org:8011/builders/llvm-clang-x86_64-expensive-checks-win/builds/15736
> ,
> >     http://lab.llvm.org:8011/builders/clang-x64-windows-msvc/builds/4242
> .
> >
> >     Please find attached the 2 temp files you can use to reliably run
> >     against your FileCheck patterns.
> >     Hope this would help debugging.
> >
> >     Please also notice the warnings each of the RUN command produces.
> >     The warnings should be quite easy to reproduce and address.
> >
> >     In the mean time, could you revert the change unless you expect the
> >     fix coming really soon, please?
> >     It is not a good idea to keep the bots red for long.
> >
> >     Here is the log:
> >
>  ----------------------------------------------------------------------
> >
> >
>  C:\>c:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.obj\bin\clang.exe
> >     -cc1 -internal-isystem
> >
>  c:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.obj\lib\clang\9.0.0\include
> >     -nostdsysteminc -ffreestanding -fms-extensions -fms-compatibility
> >     -fms-compatibility-version=17.00 -triple i686--windows -Oz
> >     -emit-llvm
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c
> >     -o - > \tmp-1\ms-x86-intrinsics-1.ll
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:10:10:
> >     warning: implicitly declaring library function '__readfsbyte' with
> >     type 'unsigned char (unsigned long)'
> >        return __readfsbyte(++Offset);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:10:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__readfsbyte'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:19:10:
> >     warning: implicitly declaring library function '__readfsword' with
> >     type 'unsigned short (unsigned long)'
> >        return __readfsword(++Offset);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:19:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__readfsword'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:28:10:
> >     warning: implicitly declaring library function '__readfsdword' with
> >     type 'unsigned long (unsigned long)'
> >        return __readfsdword(++Offset);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:28:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__readfsdword'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:37:10:
> >     warning: implicitly declaring library function '__readfsqword' with
> >     type 'unsigned long long (unsigned long)'
> >        return __readfsqword(++Offset);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:37:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__readfsqword'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:47:10:
> >     warning: implicitly declaring library function '__emul' with type
> >     'long long (int, int)'
> >        return __emul(a, b);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:47:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__emul'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:56:10:
> >     warning: implicitly declaring library function '__emulu' with type
> >     'unsigned long long (unsigned int, unsigned int)'
> >        return __emulu(a, b);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:56:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__emulu'
> >     6 warnings generated.
> >
> >
>  -----------------------------------------------------------------------
> >
> >
>  C:\>c:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.obj\bin\clang.exe
> >     -cc1 -internal-isystem
> >
>  c:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.obj\lib\clang\9.0.0\include
> >     -nostdsysteminc -ffreestanding -fms-extensions -fms-compatibility
> >     -fms-compatibility-version=17.00          -triple x86_64--windows
> >     -Oz -emit-llvm
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c
> >     -o - > \tmp-1\ms-x86-intrinsics-4.ll
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:47:10:
> >     warning: implicitly declaring library function '__emul' with type
> >     'long long (int, int)'
> >        return __emul(a, b);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:47:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__emul'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:56:10:
> >     warning: implicitly declaring library function '__emulu' with type
> >     'unsigned long long (unsigned int, unsigned int)'
> >        return __emulu(a, b);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:56:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__emulu'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:67:10:
> >     warning: implicitly declaring library function '__readgsbyte' with
> >     type 'unsigned char (unsigned long)'
> >        return __readgsbyte(++Offset);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:67:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__readgsbyte'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:77:10:
> >     warning: implicitly declaring library function '__readgsword' with
> >     type 'unsigned short (unsigned long)'
> >        return __readgsword(++Offset);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:77:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__readgsword'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:87:10:
> >     warning: implicitly declaring library function '__readgsdword' with
> >     type 'unsigned long (unsigned long)'
> >        return __readgsdword(++Offset);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:87:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__readgsdword'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:97:10:
> >     warning: implicitly declaring library function '__readgsqword' with
> >     type 'unsigned long long (unsigned long)'
> >        return __readgsqword(++Offset);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:97:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__readgsqword'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:107:10:
> >     warning: implicitly declaring library function '__mulh' with type
> >     'long long (long long, long long)'
> >        return __mulh(a, b);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:107:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__mulh'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:113:10:
> >     warning: implicitly declaring library function '__umulh' with type
> >     'unsigned long long (unsigned long long, unsigned long long)'
> >        return __umulh(a, b);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:113:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__umulh'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:121:10:
> >     warning: implicitly declaring library function '_mul128' with type
> >     'long long (long long, long long, long long *)'
> >        return _mul128(Multiplier, Multiplicand, HighProduct);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:121:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '_mul128'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:133:10:
> >     warning: implicitly declaring library function '_umul128' with type
> >     'unsigned long long (unsigned long long, unsigned long long,
> >     unsigned long long *)'
> >        return _umul128(Multiplier, Multiplicand, HighProduct);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:133:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '_umul128'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:144:10:
> >     warning: implicitly declaring library function '__shiftleft128' with
> >     type 'unsigned long long (unsigned long long, unsigned long long,
> >     unsigned char)'
> >        return __shiftleft128(l, h, d);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:144:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__shiftleft128'
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:159:10:
> >     warning: implicitly declaring library function '__shiftright128'
> >     with type 'unsigned long long (unsigned long long, unsigned long
> >     long, unsigned char)'
> >        return __shiftright128(l, h, d);
> >               ^
> >
>  C:\ps4-buildslave2\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\tools\clang\test\CodeGen\ms-x86-intrinsics.c:159:10:
> >     note: include the header <intrin.h> or explicitly provide a
> >     declaration for '__shiftright128'
> >     12 warnings generated.
> >
> >     Thanks
> >
> >     Galina
> >
> >
> >     On Mon, Feb 11, 2019 at 12:10 PM Nico Weber <thakis at chromium.org
> >     <mailto:thakis at chromium.org>> wrote:
> >
> >         This still didn't help.
> >
> >         I can't repro the failures
> >         onhttp://
> lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast
> >         <
> http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast
> >
> >         , I tried Rel+Asserts and Rel-Asserts builds. Can anyone else
> >         repro this?
> >
> >         On Mon, Feb 11, 2019 at 1:01 PM Nico Weber via cfe-commits
> >         <cfe-commits at lists.llvm.org <mailto:cfe-commits at lists.llvm.org>>
> >         wrote:
> >
> >             Author: nico
> >             Date: Mon Feb 11 10:01:27 2019
> >             New Revision: 353729
> >
> >             URL: http://llvm.org/viewvc/llvm-project?rev=353729&view=rev
> >             Log:
> >             Attempt to pacify bots more after r353718 and r353725
> >
> >             Modified:
> >                  cfe/trunk/test/CodeGen/ms-x86-intrinsics.c
> >
> >             Modified: cfe/trunk/test/CodeGen/ms-x86-intrinsics.c
> >             URL:
> >
> http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CodeGen/ms-x86-intrinsics.c?rev=353729&r1=353728&r2=353729&view=diff
> >
>  ==============================================================================
> >             --- cfe/trunk/test/CodeGen/ms-x86-intrinsics.c (original)
> >             +++ cfe/trunk/test/CodeGen/ms-x86-intrinsics.c Mon Feb 11
> >             10:01:27 2019
> >             @@ -145,9 +145,9 @@ unsigned __int64 test__shiftleft128(unsi
> >               }
> >               // CHECK-X64-LABEL: define dso_local i64
> >             @test__shiftleft128(i64 %l, i64 %h, i8 %d)
> >               // CHECK-X64:  = zext i64 %{{.*}} to i128
> >             -// CHECK-X64:  = shl nuw i128 %0, 64
> >             +// CHECK-X64:  = shl nuw i128 %{{.*}}, 64
> >               // CHECK-X64:  = zext i64 %{{.*}} to i128
> >             -// CHECK-X64:  = or i128 %{{.*}}, %{{.*}}
> >             +// CHECK-X64:  = or i128 %
> >               // CHECK-X64:  = and i8 %{{.*}}, 63
> >               // CHECK-X64:  = shl i128 %
> >               // CHECK-X64:  = lshr i128 %
> >             @@ -160,7 +160,7 @@ unsigned __int64 test__shiftright128(uns
> >               }
> >               // CHECK-X64-LABEL: define dso_local i64
> >             @test__shiftright128(i64 %l, i64 %h, i8 %d)
> >               // CHECK-X64:  = zext i64 %{{.*}} to i128
> >             -// CHECK-X64:  = shl nuw i128 %
> >             +// CHECK-X64:  = shl nuw i128 %{{.*}}, 64
> >               // CHECK-X64:  = zext i64 %{{.*}} to i128
> >               // CHECK-X64:  = or i128 %
> >               // CHECK-X64:  = and i8 %{{.*}}, 63
> >
> >
> >             _______________________________________________
> >             cfe-commits mailing list
> >             cfe-commits at lists.llvm.org <mailto:
> cfe-commits at lists.llvm.org>
> >             https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
> >
> >
> > _______________________________________________
> > cfe-commits mailing list
> > cfe-commits at lists.llvm.org
> > https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
> >
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190212/d874bc36/attachment-0001.html>


More information about the cfe-commits mailing list