New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 742432 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner:
Closed: Aug 2017
Cc:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug



Sign in to add a comment

Update llvm-next to current google3 stable r307457

Project Member Reported by manojgupta@chromium.org, Jul 13 2017

Issue description

llvm-next version being tested in ChromeOS should be updated. 
 
Summary: Update llvm-next to current google3 stable r307457 (was: Update llvm-next to current googlee3 stable r307457)
Project Member

Comment 2 by bugdroid1@chromium.org, Jul 14 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/f0303ea5176367c0cb837627b4e3086cc6692943

commit f0303ea5176367c0cb837627b4e3086cc6692943
Author: Manoj Gupta <manojgupta@google.com>
Date: Fri Jul 14 02:46:02 2017

LLVM: Update llvm-next to google3 stable r307457.

Move llvm-next to latest google3 stable version for testing.
Does not impact current llvm version in ChromeOS.

CQ-DEPEND=CL:556282

BUG= chromium:742432 
TEST=USE="llvm-next" sudo emerge llvm clang builds.

Change-Id: I4aa6297257cf2bbef9e856def386f3631fe570c6
Reviewed-on: https://chromium-review.googlesource.com/570672
Commit-Ready: Manoj Gupta <manojgupta@chromium.org>
Tested-by: Manoj Gupta <manojgupta@chromium.org>
Reviewed-by: Manoj Gupta <manojgupta@chromium.org>

[delete] https://crrev.com/d5a05612d839ee3ffdea6cc310e91260f2514e6c/sys-devel/llvm/files/cherry/5773fa6550fa9b33017d8d1e4ebdb96cf5eaf626.patch
[rename] https://crrev.com/f0303ea5176367c0cb837627b4e3086cc6692943/sys-devel/llvm/llvm-5.0_pre300080_p20170707-r1.ebuild
[rename] https://crrev.com/f0303ea5176367c0cb837627b4e3086cc6692943/sys-libs/llvm-libunwind/llvm-libunwind-5.0_pre300080-r4.ebuild
[rename] https://crrev.com/f0303ea5176367c0cb837627b4e3086cc6692943/sys-libs/compiler-rt/compiler-rt-5.0_pre300080-r6.ebuild

Labels: Build-Toolchain
Owner: g...@chromium.org
Status: Started (was: Untriaged)
Theere are build failures in llvm-next builders post the update.

The error seems related to some new overloadable checks introduced in clang.

lmbench-3.0_alpha9-r1: In file included from /build/veyron_jaq/usr/include/sys/un.h:37:
lmbench-3.0_alpha9-r1: /build/veyron_jaq/usr/include/string.h:464:13: error: redeclaration of 'bcopy'
lmbench-3.0_alpha9-r1:       must not have the 'overloadable' attribute
lmbench-3.0_alpha9-r1: extern void bcopy (const void *__src, void *__dest, size_t __n)
lmbench-3.0_alpha9-r1:             ^
lmbench-3.0_alpha9-r1: /build/veyron_jaq/usr/include/strings.h:43:13: note: previous unmarked overload
lmbench-3.0_alpha9-r1:       of function is here
lmbench-3.0_alpha9-r1: extern void bcopy (const void *__src, void *__dest, size_t __n) __THROW;
lmbench-3.0_alpha9-r1:             ^
lmbench-3.0_alpha9-r1: In file included from msleep.c:1:
lmbench-3.0_alpha9-r1: In file included from ./bench.h:36:
lmbench-3.0_alpha9-r1: In file included from /build/veyron_jaq/usr/include/sys/un.h:37:
lmbench-3.0_alpha9-r1: /build/veyron_jaq/usr/include/string.h:469:13: error: redeclaration of 'bzero'
lmbench-3.0_alpha9-r1:       must not have the 'overloadable' attribute
lmbench-3.0_alpha9-r1: extern void bzero (void *__s, size_t __n)
lmbench-3.0_alpha9-r1:             ^
lmbench-3.0_alpha9-r1: /build/veyron_jaq/usr/include/strings.h:46:13: note: previous unmarked overload
lmbench-3.0_alpha9-r1:       of function is here
lmbench-3.0_alpha9-r1: extern void bzero (void *__s, size_t __n) __THROW;

https://uberchromegw.corp.google.com/i/chromeos/builders/amd64-llvm-next-toolchain/builds/317
https://uberchromegw.corp.google.com/i/chromeos/builders/arm-llvm-next-toolchain/builds/315

Comment 5 by g...@chromium.org, Jul 14 2017

This was the breakage I referenced, though I didn't expect it to come from glibc itself. :)

Looks like these packages `#include <strings.h>` then later `#include <string.h>`. Since I didn't know we redeclared bzero/bcopy in strings.h, they don't have the proper `overloadable` incantations.

Funnily enough, there's a header guard in strings.h that makes the file a nop if string.h has already been included in some cases, so if string.h was included before strings.h, this wouldn't happen.

In any case, I'll add the right incantations to these strings.h redeclarations. Grepping the build logs, these two functions seem to be the only problematic ones (so far).
Project Member

Comment 6 by bugdroid1@chromium.org, Jul 14 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/2c422771f214e3fdb18d2fadc07a2a9efb0eb88f

commit 2c422771f214e3fdb18d2fadc07a2a9efb0eb88f
Author: Manoj Gupta <manojgupta@google.com>
Date: Fri Jul 14 19:41:54 2017

Fix compiler-rt ebuild install location.

svn was not correctly stripped from the llvm-version when built with current llvm
compiler. Because of this compiler-rt for arm is getting installed in
clang/5.0.0svn instead of 5.0.0.

BUG= chromium:742432 
TEST=USE="llvm-next" installs compiler-rt in correct location when using
llvm without "llvm-next".

Change-Id: I805c5f9f9c6e5e0bd0689e5bd83e76931638471b
Reviewed-on: https://chromium-review.googlesource.com/572081
Reviewed-by: Yunlian Jiang <yunlian@chromium.org>
Tested-by: Manoj Gupta <manojgupta@chromium.org>

[rename] https://crrev.com/2c422771f214e3fdb18d2fadc07a2a9efb0eb88f/sys-libs/compiler-rt/compiler-rt-5.0_pre300080-r7.ebuild

Project Member

Comment 7 by bugdroid1@chromium.org, Jul 15 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/e1950efa5b4849a9a8a2911dfce672beee15f567

commit e1950efa5b4849a9a8a2911dfce672beee15f567
Author: George Burgess IV <gbiv@google.com>
Date: Sat Jul 15 04:40:49 2017

Add FORTIFY markup to functions in strings.h.

This should've been added as a part of the initial FORTIFY commit, but
I didn't know strings.h existed. Since strings.h turns into nothing if
__USE_MISC is defined and string.h is included first, clang never had
an issue with the unmarked bzero/bcopy declarations.

BUG= chromium:742432 
TEST=cbuildbot on {veyron_jaq,elm,falco}. Tested both llvm-next and
current.

Change-Id: I00c6b93cf1cd8673f2f92d51bccd36821b5694d3
Reviewed-on: https://chromium-review.googlesource.com/572320
Commit-Ready: George Burgess <gbiv@chromium.org>
Tested-by: George Burgess <gbiv@chromium.org>
Reviewed-by: Manoj Gupta <manojgupta@chromium.org>

[modify] https://crrev.com/e1950efa5b4849a9a8a2911dfce672beee15f567/sys-libs/glibc/files/local/glibc-2.23-clang-fortify.patch
[rename] https://crrev.com/e1950efa5b4849a9a8a2911dfce672beee15f567/sys-libs/glibc/glibc-2.23-r9.ebuild

Comment 8 by g...@chromium.org, Jul 15 2017

Cc: g...@chromium.org
Owner: manojgupta@chromium.org
I can't see another FORTIFY-related failure, so I'm sending this back your way, Manoj.
Opened https://bugs.llvm.org//show_bug.cgi?id=33804 for clang crash.
The root cause is the upstream CL r305938.
I can revert it locally if necessary.

commit 52ebe03cb0a728134e66d04f85281bc5a60d7091
Author:     Michael Kruse <llvm@meinersbur.de>
AuthorDate: Wed Jun 21 18:25:37 2017 +0000
Commit:     Michael Kruse <llvm@meinersbur.de>
CommitDate: Wed Jun 21 18:25:37 2017 +0000

    [BasicAA] Use MayAlias instead of PartialAlias for fallback.
Project Member

Comment 10 by bugdroid1@chromium.org, Jul 16 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/9eaf911dcc9d14ba08e7c389dc2bdca0194888ad

commit 9eaf911dcc9d14ba08e7c389dc2bdca0194888ad
Author: Manoj Gupta <manojgupta@google.com>
Date: Sun Jul 16 05:14:12 2017

Fix llvm-next by reverting an upstream commit.

Temporarily revert commit 52ebe03cb0a728134e66d04f85281bc5a60d7091.
Clang crashes in LoopVectorizer while building OpenCV with this commit.
https://bugs.llvm.org/show_bug.cgi?id=33804

This CL does not affect current llvm.

BUG= chromium:742432 
TEST=OpenCV builds.

Change-Id: I0bc3c916d1d0e740ba2e56c4ea06165e4f5dd621
Reviewed-on: https://chromium-review.googlesource.com/572754
Reviewed-by: Manoj Gupta <manojgupta@chromium.org>
Commit-Queue: Manoj Gupta <manojgupta@chromium.org>
Tested-by: Manoj Gupta <manojgupta@chromium.org>

[add] https://crrev.com/9eaf911dcc9d14ba08e7c389dc2bdca0194888ad/sys-devel/llvm/files/cherry/revert-71dbb7838bd4a1b84c40da45d4b85353590875b7.patch
[rename] https://crrev.com/9eaf911dcc9d14ba08e7c389dc2bdca0194888ad/sys-devel/llvm/llvm-5.0_pre300080_p20170707-r2.ebuild

Project Member

Comment 11 by bugdroid1@chromium.org, Jul 22 2017

The following revision refers to this bug:
  https://chrome-internal.googlesource.com/chromeos/vendor/dlm/+/b154038a8bd854cd09ef9d3c380b898c994d9cc1

commit b154038a8bd854cd09ef9d3c380b898c994d9cc1
Author: Manoj Gupta <manojgupta@google.com>
Date: Sat Jul 22 01:45:23 2017

clang crashes were observed when building kernel with clang.

https://uberchromegw.corp.google.com/i/chromiumos.tryserver/builders/release/builds/13275/
The crash happens on the current clang as well when asserts are enabled. I have identified the root cause will try to send fix upstream. 
Cc: mka@chromium.org
Project Member

Comment 16 by bugdroid1@chromium.org, Jul 29 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/35086076881904452df11635dc24cfd6cded2f6f

commit 35086076881904452df11635dc24cfd6cded2f6f
Author: Manoj Gupta <manojgupta@google.com>
Date: Sat Jul 29 22:55:29 2017

llvm-next: Go back to previous r305632.

Two issues are found with current llvm-next version. The two
issues are still present on llvm ToT.
1. Crash in building OpenCV
2. Kevin fails HW test graphics_drm.

To fix this, go back to the previous llvm-next version while we can figure out
the root cause.

BUG= chromium:742432 
TEST=USE="llvm-next" sudo emerge llvm clang builds.
TEST=kevin graphics_drm test passed.
Logs: https://uberchromegw.corp.google.com/i/chromiumos.tryserver/builders/release/builds/13338

Change-Id: I0f5ac4d27200a81fc385ba92cbafabcabc52bfc3
Reviewed-on: https://chromium-review.googlesource.com/593087
Reviewed-by: Manoj Gupta <manojgupta@chromium.org>
Commit-Queue: Manoj Gupta <manojgupta@chromium.org>
Tested-by: Manoj Gupta <manojgupta@chromium.org>
Trybot-Ready: Manoj Gupta <manojgupta@chromium.org>

[add] https://crrev.com/35086076881904452df11635dc24cfd6cded2f6f/sys-devel/llvm/files/cherry/5773fa6550fa9b33017d8d1e4ebdb96cf5eaf626.patch
[rename] https://crrev.com/35086076881904452df11635dc24cfd6cded2f6f/sys-libs/compiler-rt/compiler-rt-5.0_pre300080-r9.ebuild
[rename] https://crrev.com/35086076881904452df11635dc24cfd6cded2f6f/sys-libs/llvm-libunwind/llvm-libunwind-5.0_pre300080-r5.ebuild
[add] https://crrev.com/35086076881904452df11635dc24cfd6cded2f6f/sys-devel/llvm/files/cherry/9330fda9a0ef108d03334f20319508e409bb356d.patch
[rename] https://crrev.com/35086076881904452df11635dc24cfd6cded2f6f/sys-devel/llvm/llvm-5.0_pre300080_p20170707-r3.ebuild

Status: WontFix (was: Started)
Decided to go back to r305632 for now.

Sign in to add a comment