[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] build: centralize / unify asm-offsets generation


  • To: Jan Beulich <jbeulich@xxxxxxxx>
  • From: Roger Pau Monné <roger.pau@xxxxxxxxxx>
  • Date: Tue, 27 Apr 2021 11:05:13 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=0NuqRjCniaUA8Mei4lmYCrH2yhGuw8nFaNF5XuwRRCo=; b=U5z6hVADurrvj63ErNLwzZ5OlgukfqvT5LVoZPJUs/PIltmTepzCnfG8jGPO9E4fcbVzJ4VRFeV/U/kSjNXA61QniMm960myZXqLZtSQ41QsH3F0XK+Q/4Qvf+WjDtu2rYCa2HuP6jEhC61iUm3k4hGrYcB2+g1wlz52evrdxHScqzQyfUTRXu8W4JWQtK/eo8i5h3P1L5o1sBwN+BVqoLVLgWRps43n31uEEHCQLfQXW8XUtK0Pp8AOiIDW+9wI2fwRH2nfthCGR//axdxs5EG4BKVPNHB72C4qQ8VsFr1uWIAU6ZrsyqQnMfJW25+o1P5RATV5xMaLinwjFowT+w==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JzMrzk+h6/822B/PQ47BQ5oKG0+8sMeylw3Vy6Zy41Oi3mnPiCWR9VXEpxfjQJBRy+blw5ITMoQ+RIBFpNPwalvZD0wbDtY0PYTzHV6a2EEMiLJYYYFztKRYe0RxxEWvbFv61wU3sFE+N0sTq/fVr1j/XCQiSHFozobcteIsRU/sqG8K4t3/ZDrmTLht6liDkTh9+0qs1aSEr4Aav0lmivIyy7FxA/MrhVz4dMZWW2Evievk5vaqyYqvaATDejypOX5dGZuFubfqcaFS/Lmj27H0KIbmHTZuR/ss5yeLAsiGx5aqiBI7wuS95+NIXJ8/I+I3OlfHGF1VBR+C6BNMbg==
  • Authentication-results: esa2.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
  • Cc: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Ian Jackson <iwj@xxxxxxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
  • Delivery-date: Tue, 27 Apr 2021 09:05:32 +0000
  • Ironport-hdrordr: A9a23:K7k2P6HuxHx4P0SppLqFWJTXdLJzesId70hD6mlYcjYQWtCEls yogfQQ3QL1jjFUY307hdWcIsC7Lk/03aVepa0cJ62rUgWjgmunK4l+8ZDvqgeNJwTXzcQY76 tpdsFFZeHYJURmjMr8/QmzG8shxt7Cy6yzmeLC1R5WLD1CQYsI1XYfNi+wFEpqSA5aQbc4Do Ob/MpbpzymEE5nFPiTLH8DQuTFupn3j5rgexELHFoK7wOJgDOu5tfBYmWl9z0ZVC5CxqpnzH jdn2XCl96emtyY6juZ7W/c6JxKhMDso+EsOOWggtUYQw+c6DqAS59mX9S5zVUIicGprG0nid zd5yonVv4Dl0/5WkGQjV/T1xL70DAogkWSuWOwpXf4u8T2SHYbJqN69PtkWyDU4UYho91wuZ gjtwny1+s1fGH9tR/w6NTSWxZhmlDcmwtbrccpg2FCSoxbUbdNrOUkjTJoOa0dFyH34p1PKp gJMOjg4p9tADenRkGclGxuzNuwZ280DxeLT2MT0/blrQR+rTRXyVAVy9cYmWpF3JUhS4Nc7+ CBCahwkqpSJ/VmIZ5VNaMke4+aG2bNSRXDPCa7JknmLrgOPzbop4Ts6Ls4yem2cPUzvdQPsa WEdGkdmX85ekroB8HL9oZM6ArxTGK0Wimo4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VDWLEjFq3nY3gTNtpetW8FmzLA9nNI9Z fOooXuY+0VZytPfIpaNYUSTr6PaoCb8X2f8TtIjr4+zj9bO0OSMWqOQt+ncCgq2wLtN45hyuPf j2JE7bZx6aE8i6OU397awyiw9b4MWzRLbCMgpr6TktHd50GhVY8x777JcBPF/5+e//nkiG9HZ1 78vvYrdEeM+j7PzfDU3yKYgzuR8/8E9/Kpjjr6y3htJf7XZ081Ert87HiDrO8APiOU7W6vnSD9 vxA=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On Wed, Apr 21, 2021 at 04:09:03PM +0200, Jan Beulich wrote:
> On 20.04.2021 18:20, Roger Pau Monné wrote:
> > On Tue, Apr 20, 2021 at 05:47:49PM +0200, Jan Beulich wrote:
> >> On 20.04.2021 17:29, Roger Pau Monné wrote:
> >>> On Thu, Apr 01, 2021 at 10:33:47AM +0200, Jan Beulich wrote:
> >>>> @@ -399,7 +399,11 @@ include/xen/compile.h: include/xen/compi
> >>>>          @sed -rf tools/process-banner.sed < .banner >> $@.new
> >>>>          @mv -f $@.new $@
> >>>>  
> >>>> -include/asm-$(TARGET_ARCH)/asm-offsets.h: 
> >>>> arch/$(TARGET_ARCH)/asm-offsets.s
> >>>> +asm-offsets.s: arch/$(TARGET_ARCH)/$(TARGET_SUBARCH)/asm-offsets.c
> >>>> +        $(CC) $(filter-out -Wa$(comma)% -flto,$(c_flags)) -S -g0 -o 
> >>>> $@.new -MQ $@ $<
> >>>> +        $(call move-if-changed,$@.new,$@)
> >>>
> >>> Won't it be more natural to keep the .s file in arch/$(TARGET_ARCH)?
> >>
> >> Yes and no: Yes as far as the actual file location is concerned.
> >> No when considering where it gets generated: I generally consider
> >> it risky to generate files outside of the directory where make
> >> currently runs. There may be good reasons for certain exceptions,
> >> but personally I don't see this case as good enough a reason.
> >>
> >> Somewhat related - if doing as you suggest, which Makefile's
> >> clean: rule should clean up that file in your opinion?
> > 
> > The clean rule should be in the makefile where it's generated IMO,
> > same as asm-offsets.h clean rule currently in xen/Makefile.
> > 
> >> Nevertheless, if there's general agreement that keeping the file
> >> there is better, I'd make the change and simply ignore my unhappy
> >> feelings about it.
> > 
> > I don't have a strong opinion, it just feels weird to have this IMO
> > stray asm-offsets.s outside of it's arch directory, taking into
> > account that we have asm-offsets.h generated from xen/Makefile into an
> > arch specific directory already as a precedent in that makefile.
> 
> Well, asm-offsets.h generation doesn't involve the compiler, hence
> no .*.d files get generated and want including later. For
> asm-offsets.s to have dependencies properly honored, if we
> generated it in xen/arch/<arch>, .asm-offsets.d would also end up
> there, and hence including of it would need separately taking care
> of.

I'm not sure I understand what do you mean with inclusion need taking
care of separately. Isn't it expected for .d file to reside in the
same directory as the output, and hence picked up automatically?

Thanks, Roger.



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.