DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas@monjalon.net>
To: Bruce Richardson <bruce.richardson@intel.com>
Cc: "Tyler Retzlaff" <roretzla@linux.microsoft.com>,
	dev@dpdk.org, "Morten Brørup" <mb@smartsharesystems.com>,
	david.marchand@redhat.com
Subject: Re: [RFC PATCH 2/7] telemetry: add uint type as alias for u64
Date: Mon, 19 Dec 2022 11:37:19 +0100	[thread overview]
Message-ID: <1914029.PYKUYFuaPT@thomas> (raw)
In-Reply-To: <Y5sn6YG7LRBN6yVA@bricha3-MOBL.ger.corp.intel.com>

15/12/2022 14:58, Bruce Richardson:
> On Thu, Dec 15, 2022 at 02:36:51PM +0100, Thomas Monjalon wrote:
> > 15/12/2022 10:44, Bruce Richardson:
> > > On Wed, Dec 14, 2022 at 09:38:45AM -0800, Tyler Retzlaff wrote:
> > > > On Tue, Dec 13, 2022 at 06:27:25PM +0000, Bruce Richardson wrote:
> > > > > For future standardization on the "uint" name for unsigned values rather
> > > > > than the existing "u64" one, we can for now:
> > > > > * rename all internal values to use uint rather than u64
> > > > > * add new function names to alias the existing u64 ones
> > > > > 
> > > > > Suggested-by: Morten Brørup <mb@smartsharesystems.com>
> > > > > Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
> > > > 
> > > > when adding __rte_experimental api i have been asked to add the
> > > > following boilerplate documentation block. i'm not pushing it, just
> > > > recalling it is what i get asked for, so in case it's something we do?
> > > > see lib/eal/include/rte_thread.h as an example
> > > > 
> > > > 
> > > > ```
> > > >  * @warning
> > > >  * @b EXPERIMENTAL: this API may change without prior notice.
> > > > ```
> > > >
> > > 
> > > Ok, thanks for the notice.
> > > 
> > > Actually, related to this, since we are adding these functions as aliases
> > > for existing stable functions, I would like to see these being added not as
> > > experimental. The reason for that, is that while they are experimental, we
> > > cannot feasibly mark the old function names as deprecated. :-(
> > > 
> > > Adding Thomas and David on CC for their thoughts.
> > 
> > Is it related to telemetry?
> > 
> > In general, yes we cannot deprecate something if there is no stable replacement.
> > The recommended step is to introduce a new experimental API
> > and deprecate the old one when the new API is stable.
> > 
> Yes, understood.
> What we are really trying to do here is to rename an API, by process of
> adding the new API and then marking the old one as deprecated. The small
> issue is that adding the new one it is by default experimental, meaning we
> need to wait for deprecating old one. Ideally, as soon as the new API is
> added, we would like to point people to use that, but can't really do so
> while it is experimental.
> 
> ---
> 
> By way of explicit detail, Morten pointed out the inconsistency in the
> telemetry APIs and types:
> 
> * we have add_*_int, which takes a 32-bit signed value
> * we have add_*_u64 which takes 64-bit unsigned (as name suggests).
> 
> The ideal end-state is to always use 64-bit values (since there is no space
> saving from 32-bit as a union is used), and just name everything as "int"
> or "uint" for signed/unsigned. The two big steps here are:
> 
> * expanding type of the "int" functions to take 64-bit parameters - this is
>   ABI change but not API one, since existing code will happily promote
>   values on compile. Therefore, we just use ABI versioning to have a 32-bit
>   version for older linked binaries.
> * the rename of the rte_tel_data_add_array_u64 and
>   rte_tel_data_add_dict_u64 to *_uint variants. Though keeping
>   compatibility is easier, as we can just add new functions, the overall
>   process is slower since the new functions technically should be added as
>   experimental - hence the email. For the case of function renaming, do we
>   still need to have the "renamed" versions as experimental initially?

If a function is simply renamed, I think there is no need for the experimental step.
Would we keep an alias with the old name for some time?



  reply	other threads:[~2022-12-19 10:37 UTC|newest]

Thread overview: 51+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-13 18:27 [RFC PATCH 0/7] Standardize telemetry int types Bruce Richardson
2022-12-13 18:27 ` [RFC PATCH 1/7] telemetry: rename unsigned 64-bit enum value to uint Bruce Richardson
2022-12-14 17:30   ` Tyler Retzlaff
2022-12-15  9:41     ` Bruce Richardson
2022-12-15 17:53       ` Tyler Retzlaff
2022-12-13 18:27 ` [RFC PATCH 2/7] telemetry: add uint type as alias for u64 Bruce Richardson
2022-12-14 17:38   ` Tyler Retzlaff
2022-12-15  9:44     ` Bruce Richardson
2022-12-15 13:36       ` Thomas Monjalon
2022-12-15 13:58         ` Bruce Richardson
2022-12-19 10:37           ` Thomas Monjalon [this message]
2022-12-19 13:22             ` Bruce Richardson
2022-12-15 17:58       ` Tyler Retzlaff
2022-12-15  1:49   ` lihuisong (C)
2022-12-15  9:42     ` Bruce Richardson
2022-12-15 18:02       ` Tyler Retzlaff
2022-12-13 18:27 ` [RFC PATCH 3/7] telemetry: remove RTE prefix from internal enum values Bruce Richardson
2022-12-13 18:27 ` [RFC PATCH 4/7] telemetry: make array initialization more robust Bruce Richardson
2022-12-14 17:50   ` Tyler Retzlaff
2023-01-09 12:16     ` Bruce Richardson
2023-01-09 17:49       ` Tyler Retzlaff
2023-01-10  9:11         ` Ferruh Yigit
2022-12-13 18:27 ` [RFC PATCH 5/7] telemetry: update json functions to use int/uint in names Bruce Richardson
2022-12-13 18:27 ` [RFC PATCH 6/7] telemetry: make internal int representation 64-bits Bruce Richardson
2022-12-13 18:27 ` [RFC PATCH 7/7] telemetry: change public API to use 64-bit signed values Bruce Richardson
2022-12-13 20:19   ` Morten Brørup
2022-12-14 17:53     ` Tyler Retzlaff
2022-12-15  2:39       ` lihuisong (C)
2023-01-12 10:58 ` [PATCH v2 0/9] Standardize telemetry int types Bruce Richardson
2023-01-12 10:58   ` [PATCH v2 1/9] telemetry: remove RTE prefix from internal enum values Bruce Richardson
2023-01-12 10:58   ` [PATCH v2 2/9] telemetry: make array initialization more robust Bruce Richardson
2023-01-12 10:58   ` [PATCH v2 3/9] telemetry: rename unsigned 64-bit enum value to uint Bruce Richardson
2023-01-12 10:58   ` [PATCH v2 4/9] telemetry: add uint type as alias for u64 Bruce Richardson
2023-01-12 10:58   ` [PATCH v2 5/9] global: rename telemetry functions to newer versions Bruce Richardson
2023-01-12 10:59   ` [PATCH v2 6/9] telemetry: mark old names of renamed fns as deprecated Bruce Richardson
2023-01-12 10:59   ` [PATCH v2 7/9] telemetry: update json functions to use int/uint in names Bruce Richardson
2023-01-12 10:59   ` [PATCH v2 8/9] telemetry: make internal int representation 64-bits Bruce Richardson
2023-01-12 10:59   ` [PATCH v2 9/9] telemetry: change public API to use 64-bit signed values Bruce Richardson
2023-01-12 17:41 ` [PATCH v3 0/9] Standardize telemetry int types Bruce Richardson
2023-01-12 17:41   ` [PATCH v3 1/9] telemetry: remove RTE prefix from internal enum values Bruce Richardson
2023-01-12 17:41   ` [PATCH v3 2/9] telemetry: make array initialization more robust Bruce Richardson
2023-01-12 17:41   ` [PATCH v3 3/9] telemetry: rename unsigned 64-bit enum value to uint Bruce Richardson
2023-01-12 17:41   ` [PATCH v3 4/9] telemetry: add uint type as alias for u64 Bruce Richardson
2023-01-12 17:41   ` [PATCH v3 5/9] global: rename telemetry functions to newer versions Bruce Richardson
2023-01-12 17:41   ` [PATCH v3 6/9] telemetry: mark old names of renamed fns as deprecated Bruce Richardson
2023-01-12 17:41   ` [PATCH v3 7/9] telemetry: update json functions to use int/uint in names Bruce Richardson
2023-01-12 17:41   ` [PATCH v3 8/9] telemetry: make internal int representation 64-bits Bruce Richardson
2023-01-12 17:41   ` [PATCH v3 9/9] telemetry: change public API to use 64-bit signed values Bruce Richardson
2023-02-05 22:55     ` Thomas Monjalon
2023-01-13 16:39   ` [PATCH v3 0/9] Standardize telemetry int types Power, Ciara
2023-02-05 23:15     ` Thomas Monjalon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1914029.PYKUYFuaPT@thomas \
    --to=thomas@monjalon.net \
    --cc=bruce.richardson@intel.com \
    --cc=david.marchand@redhat.com \
    --cc=dev@dpdk.org \
    --cc=mb@smartsharesystems.com \
    --cc=roretzla@linux.microsoft.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).