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] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 22 Apr 2015 08:57:10 -0300
From:	Arnaldo Carvalho de Melo <acme@...nel.org>
To:	Namhyung Kim <namhyung@...nel.org>
Cc:	Ingo Molnar <mingo@...nel.org>,
	Peter Zijlstra <a.p.zijlstra@...llo.nl>,
	Jiri Olsa <jolsa@...hat.com>,
	LKML <linux-kernel@...r.kernel.org>,
	David Ahern <dsahern@...il.com>
Subject: Re: [PATCH 01/10] perf tools: Move TUI-specific fields into unnamed
 union

Em Wed, Apr 22, 2015 at 04:18:12PM +0900, Namhyung Kim escreveu:
> +++ b/tools/perf/util/sort.h
> @@ -93,18 +93,24 @@ struct hist_entry {
>  	u8			cpumode;
> -	struct hist_entry_diff	diff;
> -
> -	/* XXX These two should move to some tree widget lib */
> -	u16			row_offset;
> -	u16			nr_rows;
> +	union {
> +		/*
> +		 * Since perf diff only supports the stdio output, TUI
> +		 * fields are only accessed from perf report (or perf
> +		 * top).  So make it an union to reduce memory usage.
> +		 */
> +		struct hist_entry_diff	diff;
> +		struct /* for TUI */ {
> +			u16	row_offset;
> +			u16	nr_rows;
> +		};
> +	};

Thanks, this way we don't have to touch the diff code, reducing this
patch size.

At some later date, we can shorten the accesses to diff.<fields>, if
struct hist_entry_diff isn't passed as a parameter, etc. But this
certainly is something for later, if at all.

Applying.

- Arnaldo
--
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