[PATCH 14/18] testsuite, fortran: Add type info of formal parameter for Intel compilers.

Nils-Christian Kempke nils-christian.kempke@intel.com
Tue May 10 14:24:33 GMT 2022


The type info emitted by ifx and ifort is different for
some_module::get_number and some_module::set_number.  A new case is
added for the Intel compilers to remove false FAILs in the test.
---
 gdb/testsuite/gdb.fortran/ptype-on-functions.exp | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/gdb/testsuite/gdb.fortran/ptype-on-functions.exp b/gdb/testsuite/gdb.fortran/ptype-on-functions.exp
index 021ad83ff1..f97bff957b 100644
--- a/gdb/testsuite/gdb.fortran/ptype-on-functions.exp
+++ b/gdb/testsuite/gdb.fortran/ptype-on-functions.exp
@@ -43,6 +43,12 @@ set stringlen ($integer8|$integer4)
 if { [test_compiler_info {flang-*} f90] } {
     set some_module_class_type "Type number"
     set some_module_aux_info ", $integer8 \\(10\\)"
+} elseif { [test_compiler_info {ifx-*} f90]
+	   || [test_compiler_info {ifort-*} f90] } {
+    # Ifx/ifort debug info reveals the implicit Fortran pass by reference for
+    # function arguments.
+    set some_module_class_type "PTR TO -> \\( Type number \\)"
+    set some_module_aux_info ""
 } else {
     set some_module_class_type "Type __class_some_module_Number(_t)?"
     set some_module_aux_info ""
-- 
2.25.1

Intel Deutschland GmbH
Registered Address: Am Campeon 10, 85579 Neubiberg, Germany
Tel: +49 89 99 8853-0, www.intel.de <http://www.intel.de>
Managing Directors: Christin Eisenschmid, Sharon Heck, Tiffany Doon Silva  
Chairperson of the Supervisory Board: Nicole Lau
Registered Office: Munich
Commercial Register: Amtsgericht Muenchen HRB 186928



More information about the Gdb-patches mailing list