From owner-freebsd-bugs@freebsd.org Fri Jul 17 22:33:57 2015 Return-Path: Delivered-To: freebsd-bugs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 210279A3EF7 for ; Fri, 17 Jul 2015 22:33:57 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E7E1E1E39 for ; Fri, 17 Jul 2015 22:33:56 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id t6HMXufS080423 for ; Fri, 17 Jul 2015 22:33:56 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-bugs@FreeBSD.org Subject: [Bug 201664] [build] cannot build 'sort' using WITH_SORT_THREADS=yes Date: Fri, 17 Jul 2015 22:33:56 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: bin X-Bugzilla-Version: 11.0-CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: accornehl@fastmail.fm X-Bugzilla-Status: New X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: freebsd-bugs@FreeBSD.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter cc Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 Jul 2015 22:33:57 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=201664 Bug ID: 201664 Summary: [build] cannot build 'sort' using WITH_SORT_THREADS=yes Product: Base System Version: 11.0-CURRENT Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: bin Assignee: freebsd-bugs@FreeBSD.org Reporter: accornehl@fastmail.fm CC: gcooper@FreeBSD.org, markj@FreeBSD.org I hit this error using a -CURRENT checkout from today. All that's needed to reproduce this is building usr.bin/sort with "WITH_SORT_THREADS=yes" in the environment or /etc/src.conf # clang -v FreeBSD clang version 3.6.0 (tags/RELEASE_360/final 230434) 20150225 Target: x86_64-unknown-freebsd11.0 Thread model: posix --- radixsort.o --- cc -O2 -pipe -DSORT_THREADS -g -std=gnu99 -fstack-protector -Wsystem-headers -Werror -Wall -Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual -Wwrite-strings -Wswitch -Wshadow -Wunused-parameter -Wcast-align -Wchar-subscripts -Winline -Wnested-externs -Wredundant-decls -Wold-style-definition -Wno-pointer-sign -Wmissing-variable-declarations -Wthread-safety -Wno-empty-body -Wno-string-plus-int -Wno-unused-const-variable -Qunused-arguments -c /usr/home/acornehl/git/freebsd/usr.bin/sort/radixsort.c -o radixsort.o /usr/home/acornehl/git/freebsd/usr.bin/sort/radixsort.c:144:17: error: mutex 'g_ls_mutex' is not held on every path through here [-Werror,-Wthread-safety-analysis] new_ls->next = g_ls; ^ /usr/home/acornehl/git/freebsd/usr.bin/sort/radixsort.c:141:3: note: mutex acquired here pthread_mutex_lock(&g_ls_mutex); ^ /usr/home/acornehl/git/freebsd/usr.bin/sort/radixsort.c:149:3: error: releasing mutex 'g_ls_mutex' that was not held [-Werror,-Wthread-safety-analysis] pthread_mutex_unlock(&g_ls_mutex); ^ 2 errors generated. *** [radixsort.o] Error code 1 make[4]: stopped in /usr/home/acornehl/git/freebsd/usr.bin/sort 1 error -- You are receiving this mail because: You are the assignee for the bug.