From owner-svn-src-head@freebsd.org Fri May 11 07:52:24 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 66D86FC74B0; Fri, 11 May 2018 07:52:24 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: from smtp.freebsd.org (unknown [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "smtp.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 1928E762DB; Fri, 11 May 2018 07:52:24 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: from mail-it0-f53.google.com (mail-it0-f53.google.com [209.85.214.53]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) (Authenticated sender: mmacy) by smtp.freebsd.org (Postfix) with ESMTPSA id C9A3019CE1; Fri, 11 May 2018 07:52:23 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: by mail-it0-f53.google.com with SMTP id n202-v6so1082230ita.1; Fri, 11 May 2018 00:52:23 -0700 (PDT) X-Gm-Message-State: ALKqPwfYH/oxZmKu2j8gTwp6uWMAhMjAUASr1I88NU/Px2sKsqI1hse2 kmf0XsIUyppCLeMsiMCatxt2+znnpnkDds1Mnho= X-Google-Smtp-Source: AB8JxZpLo02RoNVlTj1KFIDVC8lAR8XXVv0kkdU2fDOYb/QWm5BquFypsbgs4EdocqQvRQuSCEzhJ44vMWgpt77+8s4= X-Received: by 2002:a24:f9cc:: with SMTP id l195-v6mr2103955ith.132.1526025143265; Fri, 11 May 2018 00:52:23 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a02:3e4a:0:0:0:0:0 with HTTP; Fri, 11 May 2018 00:52:22 -0700 (PDT) In-Reply-To: <20180511074923.GA36228@x2.osted.lan> References: <201805110454.w4B4sDpx067946@repo.freebsd.org> <20180511071854.GA35451@x2.osted.lan> <20180511074923.GA36228@x2.osted.lan> From: Matthew Macy Date: Fri, 11 May 2018 00:52:22 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: svn commit: r333480 - head/sys/kern To: Peter Holm Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset="UTF-8" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 May 2018 07:52:24 -0000 Weird. Try tha. @@ -172,6 +174,7 @@ epoch_init_numa(epoch_t epoch) for (int i = 0; i < domcount[domain]; i++, eps++) { epoch->e_pcpu[cpu_offset + i] = eps; er = &eps->eps_record; + STAILQ_INIT(&eps->eps_cblist); ck_epoch_register(&epoch->e_epoch, &er->er_record, NULL); TAILQ_INIT((struct threadlist *)(uintptr_t)&er->er_tdlist); er->er_cpuid = cpu_offset + i; On Fri, May 11, 2018 at 12:49 AM, Peter Holm wrote: > On Fri, May 11, 2018 at 12:36:40AM -0700, Matthew Macy wrote: >> - How many cores? How many sockets? >> - Any special config options other than DIAGNOSTIC? >> > > CPU: Intel(R) Xeon(R) CPU E5-2620 0 @ 2.00GHz (1995.24-MHz K8-class CPU) > Origin="GenuineIntel" Id=0x206d7 Family=0x6 Model=0x2d Stepping=7 > Features=0xbfebfbff > Features2=0x1fbee3ff > AMD Features=0x2c100800 > AMD Features2=0x1 > XSAVE Features=0x1 > VT-x: PAT,HLT,MTF,PAUSE,EPT,UG,VPID > TSC: P-state invariant, performance statistics > real memory = 68719476736 (65536 MB) > avail memory = 66740162560 (63648 MB) > Event timer "LAPIC" quality 600 > ACPI APIC Table: > FreeBSD/SMP: Multiprocessor System Detected: 24 CPUs > FreeBSD/SMP: 2 package(s) x 6 core(s) x 2 hardware threads > > $ sed '/^#/d; /^$/d' < /usr/src/sys/amd64/conf/PHO > include GENERIC > ident PHO-GENERIC > options ALT_BREAK_TO_DEBUGGER > options SW_WATCHDOG > options DEBUG_LOCKS > options DEBUG_VFS_LOCKS > options DIAGNOSTIC > nooptions DEADLKRES # watchdogd handles this > options UFS_EXTATTR > options UFS_EXTATTR_AUTOSTART > $ > > - Peter > >> On Fri, May 11, 2018 at 12:29 AM, Matthew Macy wrote: >> > Yes. Can you give me the line number for epoch_call_task+0x7b >> > >> > >> > On Fri, May 11, 2018 at 12:18 AM, Peter Holm wrote: >> >> On Fri, May 11, 2018 at 04:54:13AM +0000, Matt Macy wrote: >> >>> Author: mmacy >> >>> Date: Fri May 11 04:54:12 2018 >> >>> New Revision: 333480 >> >>> URL: https://svnweb.freebsd.org/changeset/base/333480 >> >>> >> >>> Log: >> >>> epoch(9): fix priority handling, make callback lists pcpu, and other fixes >> >>> >> >>> - Lend priority to preempted threads in epoch_wait to handle the case >> >>> in which we've had priority lent to us. Previously we borrowed the >> >>> priority of the lowest priority preempted thread. (pointed out by mjg@) >> >>> >> >>> - Don't attempt allocate memory per-domain on powerpc, we don't currently >> >>> handle empty sockets (as is the case on jhibbits Talos' board). >> >>> >> >>> - Handle deferred callbacks as pcpu lists and poll the lists periodically. >> >>> Currently the interval is 1/hz. >> >>> >> >>> - Drop the thread lock when adaptive spinning. Holding the lock starves >> >>> other threads and can even lead to lockups. >> >>> >> >>> - Keep a generation count pcpu so that we don't keep spining if a thread >> >>> has left and re-entered an epoch section. >> >>> >> >>> - Actually removed the callback from the callback list so that we don't >> >>> double free. Sigh ... >> >>> >> >>> Approved by: sbruno@ >> >>> >> >>> Modified: >> >>> head/sys/kern/subr_epoch.c >> >>> >> >>> Modified: head/sys/kern/subr_epoch.c >> >>> ============================================================================== >> >>> --- head/sys/kern/subr_epoch.c Fri May 11 04:47:05 2018 (r333479) >> >> >> >> Could this be yours? >> >> >> >> cd0: Attempt to query device size failed: NOT READY, Medium not present - tray closed >> >> WARNING: WITNESS option enabled, expect reduced performance. >> >> WARNING: DIAGNOSTIC option enabled, expect reduced performance. >> >> Trying to mount root from ufs:/dev/da0p2 [rw]... >> >> Expensive timeout(9) function: 0xffffffff809f20d0(0xffffffff81af5140) 0.006730830 s >> >> uhub1: 4 ports with 4 removable, self powered >> >> kernel trap 12 with interrupts disabled >> >> >> >> >> >> Fatal trap 12: page fault while in kernel mode >> >> cpuid = 12; apic id = 20 >> >> fault virtual address = 0x100 >> >> fault code = supervisor read data, page not present >> >> instruction pointer = 0x20:0xffffffff80bb68db >> >> stack pointer = 0x0:0xfffffe00004e19b0 >> >> frame pointer = 0x0:0xfffffe00004e19f0 >> >> code segment = base 0x0, limit 0xfffff, type 0x1b >> >> = DPL 0, pres 1, long 1, def32 0, gran 1 >> >> processor eflags = resume, IOPL = 0 >> >> current process = 0 (config_0) >> >> [ thread pid 0 tid 100081 ] >> >> Stopped at epoch_call_task+0x7b: movq ll+0xdf(%rax),%rcx >> >> db> show registers >> >> cs 0x20 >> >> ds 0x3b ll+0x1a >> >> es 0x3b ll+0x1a >> >> fs 0x13 >> >> gs 0x1b >> >> ss 0 >> >> rax 0 >> >> rcx 0x858 ll+0x837 >> >> rdx 0xffffffff812f6968 >> >> rbx 0xc >> >> rsp 0xfffffe00004e19b0 >> >> rbp 0xfffffe00004e19f0 >> >> rsi 0x14 >> >> rdi 0 >> >> r8 0xfffff800038f3000 >> >> r9 0xffffffff81ff1620 vmspace0+0x130 >> >> r10 0xfffff800038f3000 >> >> r11 0x40 ll+0x1f >> >> r12 0xfffffe00004e19b8 >> >> r13 0xc >> >> r14 0xfffff8001f0ed400 >> >> r15 0xfffff800038f3000 >> >> rip 0xffffffff80bb68db epoch_call_task+0x7b >> >> rflags 0x10086 >> >> epoch_call_task+0x7b: movq ll+0xdf(%rax),%rcx >> >> db> bt >> >> Tracing pid 0 tid 100081 td 0xfffff800038f3000 >> >> epoch_call_task() at epoch_call_task+0x7b/frame 0xfffffe00004e19f0 >> >> gtaskqueue_run_locked() at gtaskqueue_run_locked+0x139/frame 0xfffffe00004e1a40 >> >> gtaskqueue_thread_loop() at gtaskqueue_thread_loop+0x88/frame 0xfffffe00004e1a70 >> >> fork_exit() at fork_exit+0x84/frame 0xfffffe00004e1ab0 >> >> fork_trampoline() at fork_trampoline+0xe/frame 0xfffffe00004e1ab0 >> >> --- trap 0, rip = 0, rsp = 0, rbp = 0 --- >> >> db> x/s version >> >> version: FreeBSD 12.0-CURRENT #0 r333481: Fri May 11 09:08:40 CEST 2018\012 pho@t2.osted.lan:/usr/obj/usr/src/amd64.amd64/sys/PHO\012 >> >> db> >> >> >> >> - Peter