diff mbox series

[COMMITTED] Tweak ranger-debug flags

Message ID 87f696fa-ed4a-30e9-6076-9a202876854f@redhat.com
State New
Headers show
Series [COMMITTED] Tweak ranger-debug flags | expand

Commit Message

Andrew MacLeod Oct. 25, 2021, 2:45 p.m. UTC
When I split out the ranger debug flags from the evrp-mode flag, I 
should have also made the 3 separate debug flags their own unique flag 
value, and combined them for the various options.  As it is, when you 
ask for a trace, you also gets cache output, which is unintended.  This 
patch resolves that situation.

Bootstraps onx86_64-pc-linux-gnu with no regressions.  Pushed.

Andrew
diff mbox series

Patch

From 2bfb21bb8ce16698926576870e4b1f2609e0c909 Mon Sep 17 00:00:00 2001
From: Andrew MacLeod <amacleod@redhat.com>
Date: Thu, 21 Oct 2021 10:58:16 -0400
Subject: [PATCH 1/3] Tweak ranger-debug flags.

Set the 3 possible flags as all individual bits and group for options.

	* flag-types.h (enum ranger_debug): Adjust values.
	* params.opt (ranger_debug): Ditto.
---
 gcc/flag-types.h | 3 ++-
 gcc/params.opt   | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/gcc/flag-types.h b/gcc/flag-types.h
index a5a637160d7..7cf8c28933b 100644
--- a/gcc/flag-types.h
+++ b/gcc/flag-types.h
@@ -454,9 +454,10 @@  enum ranger_debug
 {
   RANGER_DEBUG_NONE = 0,
   RANGER_DEBUG_TRACE = 1,
-  RANGER_DEBUG_CACHE = (2 | RANGER_DEBUG_TRACE),
+  RANGER_DEBUG_CACHE = 2,
   RANGER_DEBUG_GORI = 4,
   RANGER_DEBUG_TRACE_GORI = (RANGER_DEBUG_TRACE | RANGER_DEBUG_GORI),
+  RANGER_DEBUG_TRACE_CACHE = (RANGER_DEBUG_TRACE | RANGER_DEBUG_CACHE),
   RANGER_DEBUG_ALL = (RANGER_DEBUG_GORI | RANGER_DEBUG_CACHE)
 };
 
diff --git a/gcc/params.opt b/gcc/params.opt
index 393d52bc660..6eb3e15a9e6 100644
--- a/gcc/params.opt
+++ b/gcc/params.opt
@@ -887,7 +887,7 @@  EnumValue
 Enum(ranger_debug) String(trace) Value(RANGER_DEBUG_TRACE)
 
 EnumValue
-Enum(ranger_debug) String(cache) Value(RANGER_DEBUG_CACHE)
+Enum(ranger_debug) String(cache) Value(RANGER_DEBUG_TRACE_CACHE)
 
 EnumValue
 Enum(ranger_debug) String(gori) Value(RANGER_DEBUG_GORI)
-- 
2.17.2