Skip to contentSkip to conversation

perf config: Rename 'colors.code' to 'colors.jump_arrows'

PATCH RESEND Superseded Taeung Song 2 participants 3 messages Jan 7, 2016 – Jan 8, 2016 perf events

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH RESEND 1/1 perf config: Rename 'colors.code' to 'colors.jump_arrows'

Suggest 'jump_arrows' config name instead of 'code' on 'colors' section. 'colors.code' config is only for jump arrows on assembly code listings i.e.

    │     ┌──jmp    1333
    │     │  xchg   %ax,%ax
    │     │  mov    %r15,%r10
    │     └─→cmp    %r15,%r14

But this config name seems unfit.
Maybe 'jump_arrows' would be better than 'code'.

Cc Namhyung Kim <[email protected]>
Cc Jiri Olsa <[email protected]>
---
 tools/perf/Documentation/perfconfig.example | 2 +-
 tools/perf/ui/browser.c                     | 4 ++--
 tools/perf/ui/browser.h                     | 2 +-
 tools/perf/ui/browsers/annotate.c           | 2 +-
 4 files changed, 5 insertions(+), 5 deletions(-)
tools/perf/Documentation/perfconfig.example +1 -1
index 767ea24..1d8d5bc 100644
@@ -5,7 +5,7 @@
 	medium = green, lightgray
 	normal = black, lightgray
 	selected = lightgray, magenta
-	code = blue, lightgray
+	jump_arrows = blue, lightgray
 	addr = magenta, lightgray
 
 [tui]
tools/perf/ui/browser.c +2 -2
index d372021..af68a9d 100644
@@ -531,8 +531,8 @@ static struct ui_browser_colorset {
 		.bg	  = "yellow",
 	},
 	{
-		.colorset = HE_COLORSET_CODE,
-		.name	  = "code",
+		.colorset = HE_COLORSET_JUMP_ARROWS,
+		.name	  = "jump_arrows",
 		.fg	  = "blue",
 		.bg	  = "default",
 	},
tools/perf/ui/browser.h +1 -1
index 01781de..be3b70e 100644
@@ -7,7 +7,7 @@
 #define HE_COLORSET_MEDIUM	51
 #define HE_COLORSET_NORMAL	52
 #define HE_COLORSET_SELECTED	53
-#define HE_COLORSET_CODE	54
+#define HE_COLORSET_JUMP_ARROWS	54
 #define HE_COLORSET_ADDR	55
 #define HE_COLORSET_ROOT	56
 
tools/perf/ui/browsers/annotate.c +1 -1
index d4d7cc2..d2d2599 100644
@@ -284,7 +284,7 @@ static void annotate_browser__draw_current_jump(struct ui_browser *browser)
 		to = (u64)btarget->idx;
 	}
 
-	ui_browser__set_color(browser, HE_COLORSET_CODE);
+	ui_browser__set_color(browser, HE_COLORSET_JUMP_ARROWS);
 	__ui_browser__line_arrow(browser, pcnt_width + 2 + ab->addr_width,
 				 from, to);
 }
Signature · 1 line
2.5.0
maintainer Acked-by on v1 1/1
#1 lore raw
Quoted 9 lines · Taeung Song

Suggest 'jump_arrows' config name instead of 'code' on 'colors' section. 'colors.code' config is only for jump arrows on assembly code listings i.e.

    │     ┌──jmp    1333
    │     │  xchg   %ax,%ax
    │     │  mov    %r15,%r10
    │     └─→cmp    %r15,%r14
Quoted 5 lines

But this config name seems unfit.
Maybe 'jump_arrows' would be better than 'code'.

Thanks,
Namhyung

Quoted 64 lines
---
 tools/perf/Documentation/perfconfig.example | 2 +-
 tools/perf/ui/browser.c                     | 4 ++--
 tools/perf/ui/browser.h                     | 2 +-
 tools/perf/ui/browsers/annotate.c           | 2 +-
 4 files changed, 5 insertions(+), 5 deletions(-)
tools/perf/Documentation/perfconfig.example +1 -1
index 767ea24..1d8d5bc 100644
@@ -5,7 +5,7 @@
 	medium = green, lightgray
 	normal = black, lightgray
 	selected = lightgray, magenta
-	code = blue, lightgray
+	jump_arrows = blue, lightgray
 	addr = magenta, lightgray
 
 [tui]
tools/perf/ui/browser.c +2 -2
index d372021..af68a9d 100644
@@ -531,8 +531,8 @@ static struct ui_browser_colorset {
 		.bg	  = "yellow",
 	},
 	{
-		.colorset = HE_COLORSET_CODE,
-		.name	  = "code",
+		.colorset = HE_COLORSET_JUMP_ARROWS,
+		.name	  = "jump_arrows",
 		.fg	  = "blue",
 		.bg	  = "default",
 	},
tools/perf/ui/browser.h +1 -1
index 01781de..be3b70e 100644
@@ -7,7 +7,7 @@
 #define HE_COLORSET_MEDIUM	51
 #define HE_COLORSET_NORMAL	52
 #define HE_COLORSET_SELECTED	53
-#define HE_COLORSET_CODE	54
+#define HE_COLORSET_JUMP_ARROWS	54
 #define HE_COLORSET_ADDR	55
 #define HE_COLORSET_ROOT	56
 
tools/perf/ui/browsers/annotate.c +1 -1
index d4d7cc2..d2d2599 100644
@@ -284,7 +284,7 @@ static void annotate_browser__draw_current_jump(struct ui_browser *browser)
 		to = (u64)btarget->idx;
 	}
 
-	ui_browser__set_color(browser, HE_COLORSET_CODE);
+	ui_browser__set_color(browser, HE_COLORSET_JUMP_ARROWS);
 	__ui_browser__line_arrow(browser, pcnt_width + 2 + ab->addr_width,
 				 from, to);
 }
Signature · 1 line
2.5.0
author
#2 lore raw

Hi, Namhyung

Thanks for your review.
I rechecked this patch and then I found missed part that is contained on Documentation/perf-config.txt. So, I'll resend modified patch.

Thanks,
Taeung

Quoted 86 lines · Namhyung Kim
Quoted 9 lines · Taeung Song

Suggest 'jump_arrows' config name instead of 'code' on 'colors' section. 'colors.code' config is only for jump arrows on assembly code listings i.e.

     │     ┌──jmp    1333
     │     │  xchg   %ax,%ax
     │     │  mov    %r15,%r10
     │     └─→cmp    %r15,%r14
Quoted 5 lines

But this config name seems unfit.
Maybe 'jump_arrows' would be better than 'code'.

Thanks,
Namhyung

Quoted 64 lines
---
  tools/perf/Documentation/perfconfig.example | 2 +-
  tools/perf/ui/browser.c                     | 4 ++--
  tools/perf/ui/browser.h                     | 2 +-
  tools/perf/ui/browsers/annotate.c           | 2 +-
  4 files changed, 5 insertions(+), 5 deletions(-)
tools/perf/Documentation/perfconfig.example +1 -1
index 767ea24..1d8d5bc 100644
@@ -5,7 +5,7 @@
  	medium = green, lightgray
  	normal = black, lightgray
  	selected = lightgray, magenta
-	code = blue, lightgray
+	jump_arrows = blue, lightgray
  	addr = magenta, lightgray
 
  [tui]
tools/perf/ui/browser.c +2 -2
index d372021..af68a9d 100644
@@ -531,8 +531,8 @@ static struct ui_browser_colorset {
  		.bg	  = "yellow",
  	},
  	{
-		.colorset = HE_COLORSET_CODE,
-		.name	  = "code",
+		.colorset = HE_COLORSET_JUMP_ARROWS,
+		.name	  = "jump_arrows",
  		.fg	  = "blue",
  		.bg	  = "default",
  	},
tools/perf/ui/browser.h +1 -1
index 01781de..be3b70e 100644
@@ -7,7 +7,7 @@
  #define HE_COLORSET_MEDIUM	51
  #define HE_COLORSET_NORMAL	52
  #define HE_COLORSET_SELECTED	53
-#define HE_COLORSET_CODE	54
+#define HE_COLORSET_JUMP_ARROWS	54
  #define HE_COLORSET_ADDR	55
  #define HE_COLORSET_ROOT	56
 
tools/perf/ui/browsers/annotate.c +1 -2
index d4d7cc2..d2d2599 100644
@@ -284,7 +284,7 @@ static void annotate_browser__draw_current_jump(struct ui_browser *browser)
  		to = (u64)btarget->idx;
  	}
 
-	ui_browser__set_color(browser, HE_COLORSET_CODE);
+	ui_browser__set_color(browser, HE_COLORSET_JUMP_ARROWS);
  	__ui_browser__line_arrow(browser, pcnt_width + 2 + ab->addr_width,
  				 from, to);
  }
--

2.5.0