From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 8D680378B for ; Thu, 28 Feb 2019 12:53:24 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 28 Feb 2019 03:53:23 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.58,423,1544515200"; d="scan'208";a="150740843" Received: from rhorton-mobl1.ger.corp.intel.com (HELO [163.33.178.163]) ([163.33.178.163]) by fmsmga001.fm.intel.com with ESMTP; 28 Feb 2019 03:53:23 -0800 To: Junjie Wan References: <1550849955-15101-1-git-send-email-wan.junjie@foxmail.com> <1551287944-27314-1-git-send-email-wan.junjie@foxmail.com> Cc: dev@dpdk.org From: Remy Horton Organization: Intel Shannon Limited Message-ID: Date: Thu, 28 Feb 2019 11:53:19 +0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.7.1 MIME-Version: 1.0 In-Reply-To: <1551287944-27314-1-git-send-email-wan.junjie@foxmail.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH v5] lib/metrics: add unregister api for metrics X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Feb 2019 11:53:25 -0000 The tests for metrics themselves now all pass, but there is failure with bitrate statistics (bitrate stats uses metrics underneath). Latency statistics, which also uses metrics, seems ok though. RTE>>bitratestats_autotest + ------------------------------------------------------- + + Test Suite : BitRate Stats Unit Test Suite port in ring setup : 0 + ------------------------------------------------------- + + TestCase [ 0] : test_stats_bitrate_create succeeded + TestCase [ 1] : test_stats_bitrate_reg failed + TestCase [ 2] : test_stats_bitrate_reg_invalidpointer succeeded + TestCase [ 3] : test_stats_bitrate_calc_invalid_bitrate_data succeeded Invalid port_id=33 + TestCase [ 4] : test_stats_bitrate_calc_invalid_portid_1 succeeded Invalid port_id=65535 + TestCase [ 5] : test_stats_bitrate_calc_invalid_portid_2 succeeded Invalid port_id=31 + TestCase [ 6] : test_stats_bitrate_calc_non_existing_portid succeeded + TestCase [ 7] : test_stats_bitrate_calc succeeded + ------------------------------------------------------- + + Test Suite Summary + Tests Total : 8 + Tests Skipped : 0 + Tests Executed : 8 + Tests Unsupported: 0 + Tests Passed : 7 + Tests Failed : 1 + ------------------------------------------------------- + Test Failed Personally if I was reimplementing metrics I would be inclined to replace the single fixed-size metadata[] array that is carved up with something more dynamic, perhaps a 2d linked-list. Doing so would probably negate the need for a bitmap. On 27/02/2019 17:19, Junjie Wan wrote: > From: junka > > The bitmap will help maintain the metrics. We can dynamically > add and remove metrics data. For example, after uninit latency lib, > it could remove itself from the metrics. This could make the result > from rte_metrics_get_names much more simple to display the wanted > metrics data only. > > Signed-off-by: Junjie Wan