From owner-svn-src-head@FreeBSD.ORG Tue Jul 2 17:59:44 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 161E7163; Tue, 2 Jul 2013 17:59:44 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-qc0-x22f.google.com (mail-qc0-x22f.google.com [IPv6:2607:f8b0:400d:c01::22f]) by mx1.freebsd.org (Postfix) with ESMTP id 8B3DB1D47; Tue, 2 Jul 2013 17:59:43 +0000 (UTC) Received: by mail-qc0-f175.google.com with SMTP id k14so3873609qcv.20 for ; Tue, 02 Jul 2013 10:59:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=ot8eoHa7Okd5NVdSvynTd3++9Nr9m+LysBuFyv8y5E8=; b=fABWGI1SRs8Io+mDsPqlz13U3HT8kOK15urId0R6O6vrxMA2lvA36p1pWA1wHzckgC d2l290AUw1oA8pKoZzEI/vOYwRrzp9UYCNvjIDxwZcaLTBq8UgZk4O1/0NpypuQHqc3T JaMe6+SYKqLJgwquiEI09V5SLzzI3XY/sCyltz9Ezc8oqlBKFsWdZRV9jMWA1VIUsupP ir2Elk7T/4K4teCWZtK8XyEV9TuqlGxvvO2Wk7bHXvG3ipdYCrJRWI6NdRDk73XqB1lk IW/zcZXmFZul5nC3xZwGND/en4CB9MQ+kbuyf61rUP81D3hPjk9n9BEFNe/7tYvHc/tN zyCw== MIME-Version: 1.0 X-Received: by 10.49.105.97 with SMTP id gl1mr39996822qeb.76.1372787983166; Tue, 02 Jul 2013 10:59:43 -0700 (PDT) Sender: carpeddiem@gmail.com Received: by 10.224.209.6 with HTTP; Tue, 2 Jul 2013 10:59:43 -0700 (PDT) In-Reply-To: <51D30463.50608@FreeBSD.org> References: <201306031736.r53Hain5093431@svn.freebsd.org> <51D30463.50608@FreeBSD.org> Date: Tue, 2 Jul 2013 13:59:43 -0400 X-Google-Sender-Auth: Aw-grtIPFEotE5D8fjMQYlIJVHE Message-ID: Subject: Re: should_yield problem [Was: svn commit: r251322 - head/sys/kern] From: Ed Maste To: Andriy Gapon Content-Type: text/plain; charset=ISO-8859-1 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Konstantin Belousov X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 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: Tue, 02 Jul 2013 17:59:44 -0000 On 2 July 2013 12:48, Andriy Gapon wrote: > I am not sure if the originally reported problem was also caused by > should_yield() or if it was something else. But in either case I think that we > should fix should_yield. Perhaps (ticks - curthread->td_swvoltick) should be > cast to unsigned before comparison? What about just initializing td_swvoltick to ticks at td creation?