This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[gimple-classes, committed 38/92] tree-cfg.c: Make verify_gimple_call require a gimple_call


This corresponds to:
  [PATCH 40/89] tree-cfg.c: Make verify_gimple_call require a gimple_call
  https://gcc.gnu.org/ml/gcc-patches/2014-04/msg01232.html
from the original 89-patch kit

That earlier patch was approved by Jeff:
> OK when prerequisites have gone in.
in https://gcc.gnu.org/ml/gcc-patches/2014-05/msg00805.html

gcc/
	* tree-cfg.c (verify_gimple_call): Require a gimple_call rather
	than a plain gimple.
	(verify_gimple_stmt): Add checked cast to gimple_call within
	GIMPLE_CALL case of switch statement.
---
 gcc/ChangeLog.gimple-classes | 9 +++++++++
 gcc/tree-cfg.c               | 4 ++--
 2 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/gcc/ChangeLog.gimple-classes b/gcc/ChangeLog.gimple-classes
index b0ddcd3..b030d20 100644
--- a/gcc/ChangeLog.gimple-classes
+++ b/gcc/ChangeLog.gimple-classes
@@ -1,5 +1,14 @@
 2014-10-24  David Malcolm  <dmalcolm@redhat.com>
 
+	tree-cfg.c: Make verify_gimple_call require a gimple_call
+
+	* tree-cfg.c (verify_gimple_call): Require a gimple_call rather
+	than a plain gimple.
+	(verify_gimple_stmt): Add checked cast to gimple_call within
+	GIMPLE_CALL case of switch statement.
+
+2014-10-24  David Malcolm  <dmalcolm@redhat.com>
+
 	Introduce gimple_omp_parallel
 
 	* coretypes.h (gimple_omp_parallel): New typedef.
diff --git a/gcc/tree-cfg.c b/gcc/tree-cfg.c
index feeefea..9db1ffd 100644
--- a/gcc/tree-cfg.c
+++ b/gcc/tree-cfg.c
@@ -3208,7 +3208,7 @@ valid_fixed_convert_types_p (tree type1, tree type2)
    is a problem, otherwise false.  */
 
 static bool
-verify_gimple_call (gimple stmt)
+verify_gimple_call (gimple_call stmt)
 {
   tree fn = gimple_call_fn (stmt);
   tree fntype, fndecl;
@@ -4486,7 +4486,7 @@ verify_gimple_stmt (gimple stmt)
       return verify_gimple_label (as_a <gimple_label> (stmt));
 
     case GIMPLE_CALL:
-      return verify_gimple_call (stmt);
+      return verify_gimple_call (as_a <gimple_call> (stmt));
 
     case GIMPLE_COND:
       if (TREE_CODE_CLASS (gimple_cond_code (stmt)) != tcc_comparison)
-- 
1.8.5.3


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]