lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20150624233922.47b9ecbb@grimm.local.home>
Date:	Wed, 24 Jun 2015 23:39:22 -0400
From:	Steven Rostedt <rostedt@...dmis.org>
To:	Josef Bacik <jbacik@...com>
Cc:	<linux-kernel@...r.kernel.org>, <kernel-team@...com>
Subject: Re: [PATCH V2] trace-cmd: add option to group like comms for
 profile

On Thu, 21 May 2015 13:30:08 -0400
Josef Bacik <jbacik@...com> wrote:


> +static void merge_tasks(struct handle_data *h)
> +{
> +	struct trace_hash_item **bucket;
> +	struct trace_hash_item *item;
> +
> +	if (!merge_like_comms)
> +		return;
> +
> +	trace_hash_for_each_bucket(bucket, &h->task_hash) {
> +		trace_hash_for_each_item(item, bucket)
> +			add_group(h, task_from_item(item));
> +	}
> +}
> +
>  int trace_profile(void)
>  {
>  	struct handle_data *h;
>  
>  	for (h = handles; h; h = h->next) {
> +		if (merge_like_comms)
> +			merge_tasks(h);

I don't think we need the double check. Here you only call
merge_tasks() if merge_like_comms is set, but then the first thing you
do in merge_tasks() is to return if merge_like_comms is not set. One
check is enough.

-- Steve


>  		output_handle(h);
>  		trace_hash_free(&h->task_hash);
>  	}

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ