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

Re: [RFC PATCH 3/5] [WIP]xen/scripts: add codestyle.py script


  • To: Jan Beulich <jbeulich@xxxxxxxx>
  • From: Luca Fancellu <Luca.Fancellu@xxxxxxx>
  • Date: Wed, 9 Aug 2023 15:48:30 +0000
  • Accept-language: en-GB, en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=zanEG82qDmobUBI5W3jSbksF1KslhpUDpD/Iplyhyls=; b=VLBUSYQpmGeHg1uQT7YRk73izw3qUxbB9klhtmP05gGpwmlklzYwuDf7saB4CDnCDxqtPp62VaZjC78Ta8gu9/WbsuEI6NKkpvjoL2ZayDrv3w1hXkTWyYjAw9UZqZzUw9vn/F4zRn6okTrhRH6dizIAb7rb87tpVTZBkmNxRKPaIPj+Jsg7n6Qa9fSUK/88GOd7q4lmdobxvnGaJZc+3pseSjcU8gdHWbWi6NLsyDk6BusjxjOeE2jSp0u5/KzJ2ejElmlasz5VF2mTCK3Di86DnbYtzswH2RiRDg9vM2xWFeq5MysTNzQLuQs+qw40flM/3k5KvrGC9JIKIIjaJw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=AUVH0J6Cb+dFrQTsQ2Z16ZJLiGbQjVSKcPrIUVfPH39fVHNHdM5YLtRv6pBsnxHXvFqW6eomoRQnYKTuDAFDuVTEnNqAl3yzbL8f6diczyW/hVa7gL+fQ2QTOQ6SRi/apifz7xmvQvyG0dXcpJrRee565A3QAlbQu0gZrLoBApiOn7tqUagqk1+16ym7LbG2TpEpDxGstaofw8X5oap7VTWI0rNpkrjl4SfQi7VnN7KfASmk+TCS/bFRotABlZ/s2yYYzMwWw92Go7QERPVc+pinJPbvcTBTTfyB3huyq8xa6u/qUZac6Dfi0nwsPk3b4jd9rYMobllpqn/ef1bV0A==
  • Authentication-results-original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Cc: Bertrand Marquis <Bertrand.Marquis@xxxxxxx>, Wei Chen <Wei.Chen@xxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • Delivery-date: Wed, 09 Aug 2023 15:49:15 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Nodisclaimer: true
  • Original-authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Thread-index: AQHZwStACZga8Y9XdUKITC8YuHP7fa/iLbiAgAABx4A=
  • Thread-topic: [RFC PATCH 3/5] [WIP]xen/scripts: add codestyle.py script


> On 9 Aug 2023, at 16:41, Jan Beulich <jbeulich@xxxxxxxx> wrote:
> 
> On 28.07.2023 10:11, Luca Fancellu wrote:
>> This script finds every .c and .h file in the xen hypervisor
>> codebase, takes the exclusion list from docs/misra, removes the
>> file excluded from the list and for the remaining files is
>> calling clang-format on them.
> 
> I was going to ask what the intended purpose is, but looking at the
> script itself I think I see the script can also be passed a set of
> file names, so it won't necessarily scan the entire code base.
> That'll make it more suitable to also be used in an incremental
> fashion (whether that's also useful to scan patches isn't really
> clear to me, but I guess that'll require yet more work).

Yes, when we will do some automation, it would be useful to just run the script
against the touched files from a patch.
Indeed running it against the patch file is very difficult, since we are doing 
some
pre-process and post-process that requires some context that might be missing
from the code inside the patch.

Cheers,
Luca




 


Rackspace

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