Received: by 2002:a05:7412:bb8d:b0:d7:7d3a:4fe2 with SMTP id js13csp1002013rdb; Tue, 15 Aug 2023 20:49:56 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHCop1t4/obIFmpwBxObxTm/rDUbvwZ2sY4yR3+nm3zkWn/22Th91Y7ku7Bxd2LIjO+PO+T X-Received: by 2002:a05:6402:1a53:b0:522:38cb:d8cb with SMTP id bf19-20020a0564021a5300b0052238cbd8cbmr546303edb.20.1692157796630; Tue, 15 Aug 2023 20:49:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1692157796; cv=none; d=google.com; s=arc-20160816; b=uMpz5ZJyQILGHvGi3Vpw4pPfD+v2fc8sH5An2QbgFdOpIHrBA8pzwfFJPcJa2GQyx1 egeKnlZvxmKsglgDUIGV0SaE9OtdPQR3zCT8U9qFcslVLAVHZfSVHIOzM/UfEdoMSBFA JjwM/ifNT2nHluZXv4SfaT1FxI7xcXodJv9Eu7y/jpAvUZRmzTdflpLUObF9Olr3rpFy 1JK1TZUhWzs3xtG/xxpRyP6ve7QBcEHEM4KVtXFsAsuLHLUzU7Qa4vZOWXZcbxPKfdwS iY35MfJnR538Xws59ninAP/kHroBBl/fNI7Oo+VSSEE1kBm4vVcn/rfIzhyQiNQ0c82a KS6g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:reply-to:message-id :subject:cc:to:from:date:dkim-signature; bh=327jyIMpFiuYii4eX7InBUj39/z08ToTDrLWVWitnkk=; fh=iOR1gCVcMrZxiv6CFCdfifMQ5JE0YatM7CrtOF1tdxA=; b=1B/SyZ7iO/lo4OTCekPkkRm/J6Ls3K7tA/aZKCh7QxbpN5N5cDo+Hy0iL/uHP1pUHE IIURhDsbiRbd6PU4WuxK/jmJ4wbErK2cNCX04dn8oeZOEGBNoijXlCl5BXs3am7eizi2 2geifCDDuumOmBncGoOj/VZ6z2Hc/86CafvfhvWXgxWudXIwsQXZ9HwdLzO/DfBFZHwk vutkIU9pTDKBIyLIwjejAL9jfywKVQ2ImG/R5FSPECwucxsOaxL8zr5pT7C6IprolP6g 3ij+SbuducrY1G+3B7G6dXs//cTz30d6fIcnMvPuCGy7dQ7s1fE7o17tQYfUtiy7ze+3 YW8g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=TdJPB2wO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u12-20020aa7d88c000000b005233ff6dfc3si8144021edq.642.2023.08.15.20.49.32; Tue, 15 Aug 2023 20:49:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=TdJPB2wO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238515AbjHOQfr (ORCPT + 99 others); Tue, 15 Aug 2023 12:35:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33860 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238533AbjHOQfZ (ORCPT ); Tue, 15 Aug 2023 12:35:25 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5419810E3 for ; Tue, 15 Aug 2023 09:35:24 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id DBD7064C61 for ; Tue, 15 Aug 2023 16:35:23 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 3C819C433C7; Tue, 15 Aug 2023 16:35:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1692117323; bh=WAfPmP4DH1mwde7Ao/JTrW1ILoChZSppc9ArGa2ECe8=; h=Date:From:To:Cc:Subject:Reply-To:References:In-Reply-To:From; b=TdJPB2wOSm09Oktdk0iQI4l1bd5K+tTwtmzKQWTVRl842KYqdNYAdeyC55zcdKE4/ bYqbG9yhmMOYqgK434oVCXpSJUhijLOD/NzQ17r7rD9QHTApYOT9a+XaFt20W5sdls RlbQdK9bYWwPCbVenXWEZQv+eYTK9ewAnkklIyE2mBxuH+tNGbtZNMCqdllm/AdA8N JPk5BMGGx2GaWJISPg0wSUcv7ez0Jh8UEBAITj6CIG4Y02kKhdT8jzkfYI/tYyfxfU 8DqLgXooKyjvUWFgeyC8mn+g/giaWM3ZFraeAcKZtSCwpJmOJsuUg2RNyjNBtJTU6f q6BJCz/BBOuxA== Received: by paulmck-ThinkPad-P17-Gen-1.home (Postfix, from userid 1000) id CB0F9CE09C4; Tue, 15 Aug 2023 09:35:22 -0700 (PDT) Date: Tue, 15 Aug 2023 09:35:22 -0700 From: "Paul E. McKenney" To: "Liu, Yujie" Cc: "linux-kernel@vger.kernel.org" , lkp , "oe-kbuild-all@lists.linux.dev" , Vineet Gupta , linux-snps-arc@lists.infradead.org Subject: Re: {standard input}:1727: Error: operand out of range (-132 is not between -128 and 127) Message-ID: <574cfd03-c279-4cf7-872f-cbe0b8788a50@paulmck-laptop> Reply-To: paulmck@kernel.org References: <202308111233.rbf5C0JD-lkp@intel.com> <416679c9-96b3-4114-bba3-473e647c4c2d@paulmck-laptop> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Aug 15, 2023 at 07:34:04AM +0000, Liu, Yujie wrote: > Hi Paul, > > On Fri, 2023-08-11 at 08:41 -0700, Paul E. McKenney wrote: > > On Fri, Aug 11, 2023 at 01:02:12PM +0800, kernel test robot wrote: > > > tree:?? https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git?master > > > head:?? 25aa0bebba72b318e71fe205bfd1236550cc9534 > > > commit: a6889becb05394255c80b62103677e3b095726a9 refscale: Add tests using SLAB_TYPESAFE_BY_RCU > > > date:?? 7 months ago > > > config: arc-randconfig-r006-20230811 (https://download.01.org/0day-ci/archive/20230811/202308111233.rbf5C0JD-lkp@intel.com/config) > > > compiler: arceb-elf-gcc (GCC) 12.3.0 > > > reproduce: (https://download.01.org/0day-ci/archive/20230811/202308111233.rbf5C0JD-lkp@intel.com/reproduce) > > > > > > If you fix the issue in a separate patch/commit (i.e. not just a new version of > > > the same patch/commit), kindly add following tags > > > > Reported-by: kernel test robot > > > > Closes: https://lore.kernel.org/oe-kbuild-all/202308111233.rbf5C0JD-lkp@intel.com/ > > > > > > All errors (new ones prefixed by >>): > > > > > > ?? {standard input}: Assembler messages: > > > > > {standard input}:1727: Error: operand out of range (-132 is not between -128 and 127) > > > > I am not seeing any inline assembly in that patch, so I have to suspect > > a bug in arch code or the compiler backend for arc. > > > > Or is there something that I am missing here? > > We looked into this case a little bit. The assembler error popped up > when building kernel/rcu/refscale.o > > $make W=1 --keep-going CROSS_COMPILE=arceb-elf- ARCH=arc kernel/rcu/refscale.o > ... > CC [M] kernel/rcu/refscale.o > {standard input}: Assembler messages: > {standard input}:1727: Error: operand out of range (-132 is not between -128 and 127) > make[3]: *** [scripts/Makefile.build:252: kernel/rcu/refscale.o] Error 1 > make[2]: *** [scripts/Makefile.build:504: kernel/rcu] Error 2 > make[2]: Target 'kernel/rcu/refscale.o' not remade because of errors. > make[1]: *** [scripts/Makefile.build:504: kernel] Error 2 > make[1]: Target 'kernel/rcu/refscale.o' not remade because of errors. > make: *** [Makefile:2008: .] Error 2 > make: Target 'kernel/rcu/refscale.o' not remade because of errors. > > We did some assembly and disassembly tricks: > > 1721 .L334: > 1722 ld_s r0,[r14,52] ;15 > 1723 brgt r0, r19, @.L335 > 1724 ld_s r0,[r13,120] ;15 > 1725 breq_s r0, 0, @.L337 > 1726 jl [r17] > 1727 brne_s r0, 0, @.L337 <--- > 1728 mov_s r2,20 ;3 > 1729 mov_s r1,0 ;3 > 1730 mov_s r0,sp ;4 > 1731 jl [r20] > 1732 mov_s r1,0 ;3 > 1733 mov_s r0,sp ;4 > 1734 jl @init_wait_entry > 1735 .align 2 > > This assembly instruction at line 1727 points to the code in main_func, > but main_func is not touched by commit a6889becb053. > > d6e: 860d ld_s r0,[r14,0x34] > d70: 0b59 a002 brlt.nt r19,r0,-168 ;cc8 > return arch_atomic_read(v); > d74: 851e ld_s r0,[r13,0x78] > wait_event(main_wq, > d76: e842 breq_s r0,0,-124 ;cf8 > d78: 2022 0440 jl [r17] > d7c: e8be brne_s r0,0,124 ;df8 <-- > d7e: da14 mov_s r2,0x14 > d80: 702c mov_s r1,0 > d82: 4083 mov_s r0,sp > d84: 2022 0500 jl [r20] > d88: 702c mov_s r1,0 > d8a: 4083 mov_s r0,sp > d8c: 2022 0f80 0000 0000 jl 0 > > We also tried on the parent commit 3c6496c86e48. It builds fine without > that assembler error, and corresponding disassembly is: > > afe: 860d ld_s r0,[r14,0x34] > b00: 0b5d a002 brlt.nt r19,r0,-164 ;a5c > return arch_atomic_read(v); > b04: 8518 ld_s r0,[r13,0x60] > wait_event(main_wq, > b06: e844 breq_s r0,0,-120 ;a8c > b08: 2022 0440 jl [r17] > b0c: e8c0 brne_s r0,0,-128 ;a8c <-- > b0e: da14 mov_s r2,0x14 > b10: 702c mov_s r1,0 > b12: 4083 mov_s r0,sp > b14: 2022 0500 jl [r20] > b18: 702c mov_s r1,0 > b1a: 4083 mov_s r0,sp > b1c: 2022 0f80 0000 0000 jl 0 > b24: 724c mov_s r2,2 > b26: 4183 mov_s r1,sp > b28: 40c3 0000 0000 mov_s r0,0 > b2e: 2022 0f80 0000 0000 jl 0 > > > We are also not sure if this is a bug in arch code or compiler side. > Here we provide above info for your reference. Thank you for looking into this and getting back to me. I added the ARC maintainer and list on CC. Thanx, Paul