* [RFA] Add "long long" tests to whatis.exp
@ 2001-09-20 14:36 Michael Snyder
[not found] ` <7458-Fri21Sep2001101238+0300-eliz@is.elta.co.il>
0 siblings, 1 reply; 2+ messages in thread
From: Michael Snyder @ 2001-09-20 14:36 UTC (permalink / raw)
To: gdb-patches; +Cc: fnasser
2001-09-20 Michael Snyder <msnyder@redhat.com>
* gdb.base/whatis.exp: Add tests for long long.
Index: whatis.c
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.base/whatis.c,v
retrieving revision 1.1.1.2
diff -c -3 -p -r1.1.1.2 whatis.c
*** whatis.c 1999/06/28 16:04:24 1.1.1.2
--- whatis.c 2001/09/20 21:34:04
*************** long v_long;
*** 27,32 ****
--- 27,36 ----
signed long v_signed_long;
unsigned long v_unsigned_long;
+ long long v_long_long;
+ signed long long v_signed_long_long;
+ unsigned long long v_unsigned_long_long;
+
float v_float;
double v_double;
*************** long v_long_array[2];
*** 53,58 ****
--- 57,66 ----
signed long v_signed_long_array[2];
unsigned long v_unsigned_long_array[2];
+ long long v_long_long_array[2];
+ signed long long v_signed_long_long_array[2];
+ unsigned long long v_unsigned_long_long_array[2];
+
float v_float_array[2];
double v_double_array[2];
*************** long *v_long_pointer;
*** 82,87 ****
--- 90,99 ----
signed long *v_signed_long_pointer;
unsigned long *v_unsigned_long_pointer;
+ long long *v_long_long_pointer;
+ signed long long *v_signed_long_long_pointer;
+ unsigned long long *v_unsigned_long_long_pointer;
+
float *v_float_pointer;
double *v_double_pointer;
*************** struct t_struct {
*** 92,97 ****
--- 104,110 ----
short v_short_member;
int v_int_member;
long v_long_member;
+ long long v_long_long_member;
float v_float_member;
double v_double_member;
} v_struct1;
*************** struct {
*** 101,106 ****
--- 114,120 ----
short v_short_member;
int v_int_member;
long v_long_member;
+ long long v_long_long_member;
float v_float_member;
double v_double_member;
} v_struct2;
*************** union t_union {
*** 112,117 ****
--- 126,132 ----
short v_short_member;
int v_int_member;
long v_long_member;
+ long long v_long_long_member;
float v_float_member;
double v_double_member;
} v_union;
*************** union {
*** 121,126 ****
--- 136,142 ----
short v_short_member;
int v_int_member;
long v_long_member;
+ long long v_long_long_member;
float v_float_member;
double v_double_member;
} v_union2;
*************** long v_long_func () { return (0); }
*** 143,148 ****
--- 159,168 ----
signed long v_signed_long_func () { return (0); }
unsigned long v_unsigned_long_func () { return (0); }
+ long long v_long_long_func () { return (0); }
+ signed long long v_signed_long_long_func () { return (0); }
+ unsigned long long v_unsigned_long_long_func () { return (0); }
+
float v_float_func () { return (0.0); }
double v_double_func () { return (0.0); }
*************** int main ()
*** 212,217 ****
--- 232,241 ----
v_signed_long = 10;
v_unsigned_long = 11;
+ v_long_long = 12;
+ v_signed_long_long = 13;
+ v_unsigned_long_long = 14;
+
v_float = 100.0;
v_double = 200.0;
*************** int main ()
*** 232,237 ****
--- 256,265 ----
v_signed_long_array[0] = v_signed_long;
v_unsigned_long_array[0] = v_unsigned_long;
+ v_long_long_array[0] = v_long_long;
+ v_signed_long_long_array[0] = v_signed_long_long;
+ v_unsigned_long_long_array[0] = v_unsigned_long_long;
+
v_float_array[0] = v_float;
v_double_array[0] = v_double;
*************** int main ()
*** 250,255 ****
--- 278,287 ----
v_long_pointer = &v_long;
v_signed_long_pointer = &v_signed_long;
v_unsigned_long_pointer = &v_unsigned_long;
+
+ v_long_long_pointer = &v_long_long;
+ v_signed_long_long_pointer = &v_signed_long_long;
+ v_unsigned_long_long_pointer = &v_unsigned_long_long;
v_float_pointer = &v_float;
v_double_pointer = &v_double;
Index: whatis.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.base/whatis.exp,v
retrieving revision 1.2
diff -c -3 -p -r1.2 whatis.exp
*** whatis.exp 2001/03/06 08:21:51 1.2
--- whatis.exp 2001/09/20 21:34:04
*************** gdb_test "whatis v_unsigned_long" \
*** 138,143 ****
--- 138,155 ----
"type = (unsigned long|long unsigned int)" \
"whatis unsigned long"
+ gdb_test "whatis v_long_long" \
+ "type = (long long|long long int)" \
+ "whatis long long"
+
+ gdb_test "whatis v_signed_long_long" \
+ "type = (signed |)(long long|long long int)" \
+ "whatis signed long long"
+
+ gdb_test "whatis v_unsigned_long_long" \
+ "type = (unsigned long long|long long unsigned int)" \
+ "whatis unsigned long long"
+
gdb_test "whatis v_float" \
"type = float" \
"whatis float"
*************** gdb_test "whatis v_unsigned_long_array"
*** 202,207 ****
--- 214,231 ----
"type = (unsigned (int|long|long int)|long unsigned int) \\\[2\\\]" \
"whatis unsigned long array"
+ gdb_test "whatis v_long_long_array" \
+ "type = (long long|long long int) \\\[2\\\]" \
+ "whatis long long array"
+
+ gdb_test "whatis v_signed_long_long_array" \
+ "type = (signed |)(long long|long long int) \\\[2\\\]" \
+ "whatis signed long long array"
+
+ gdb_test "whatis v_unsigned_long_long_array" \
+ "type = (unsigned (long long|long long int)|long long unsigned int) \\\[2\\\]" \
+ "whatis unsigned long long array"
+
gdb_test "whatis v_float_array" \
"type = float \\\[2\\\]" \
"whatis float array"
*************** gdb_test "whatis v_unsigned_long_pointer
*** 265,270 ****
--- 289,306 ----
"type = (unsigned (int|long|long int)|long unsigned int) \\*" \
"whatis unsigned long pointer"
+ gdb_test "whatis v_long_long_pointer" \
+ "type = (long long|long long int) \\*" \
+ "whatis long long pointer"
+
+ gdb_test "whatis v_signed_long_long_pointer" \
+ "type = (signed |)(long long|long long int) \\*" \
+ "whatis signed long long pointer"
+
+ gdb_test "whatis v_unsigned_long_long_pointer" \
+ "type = (unsigned (long long|long long int)|long long unsigned int) \\*" \
+ "whatis unsigned long long pointer"
+
gdb_test "whatis v_float_pointer" \
"type = float \\*" \
"whatis float pointer"
*************** gdb_test "whatis v_signed_long_func" \
*** 360,365 ****
--- 396,413 ----
gdb_test "whatis v_unsigned_long_func" \
"type = (unsigned (int|long|long int)|long unsigned int) \\($void\\)" \
"whatis unsigned long function"
+
+ gdb_test "whatis v_long_long_func" \
+ "type = (long long|long long int) \\($void\\)" \
+ "whatis long long function"
+
+ gdb_test "whatis v_signed_long_long_func" \
+ "type = (signed |)(long long|long long int) \\($void\\)" \
+ "whatis signed long long function"
+
+ gdb_test "whatis v_unsigned_long_long_func" \
+ "type = (unsigned (long long|long long int)|long long unsigned int) \\($void\\)" \
+ "whatis unsigned long long function"
# Sun /bin/cc calls this a function returning double.
if {!$gcc_compiled} then {setup_xfail "*-sun-sunos4*"}
From msnyder@cygnus.com Thu Sep 20 14:55:00 2001
From: Michael Snyder <msnyder@cygnus.com>
To: gdb-patches@sources.redhat.com
Cc: fnasser@redhat.com
Subject: [RFA] Add long long tests to ptype.exp
Date: Thu, 20 Sep 2001 14:55:00 -0000
Message-id: <3BAA65B7.140DE2EA@cygnus.com>
X-SW-Source: 2001-09/msg00276.html
Content-length: 8306
2001-09-20 Michael Snyder <msnyder@redhat.com>
* gdb.base/ptype.exp: Add tests for long long.
Index: ptype.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.base/ptype.exp,v
retrieving revision 1.2
diff -c -3 -p -r1.2 ptype.exp
*** ptype.exp 2001/03/06 08:21:51 1.2
--- ptype.exp 2001/09/20 21:53:45
*************** gdb_expect {
*** 73,79 ****
# Here and elsewhere, we accept
# "long", "long int", or "int" for long variables (whatis.exp already
# has an XFAIL for "int" (Sun cc bug), so no need to fail it here).
! gdb_test "ptype struct t_struct" "type = struct t_struct \{.*\[\r\n\] (unsigned |)char v_char_member;.*\[\r\n\] (short|short int) v_short_member;.*\[\r\n\] int v_int_member;.*\[\r\n\] (long|long int|int) v_long_member;.*\[\r\n\] float v_float_member;.*\[\r\n\] double v_double_member;.*\[\r\n\]\}.*" "ptype structure"
# Test the equivalence between '.' and '->' for struct member references.
--- 73,79 ----
# Here and elsewhere, we accept
# "long", "long int", or "int" for long variables (whatis.exp already
# has an XFAIL for "int" (Sun cc bug), so no need to fail it here).
! gdb_test "ptype struct t_struct" "type = struct t_struct \{.*\[\r\n\] (unsigned |)char v_char_member;.*\[\r\n\] (short|short int) v_short_member;.*\[\r\n\] int v_int_member;.*\[\r\n\] (long|long int|int) v_long_member;.*\[\r\n\] (long long|long long int) v_long_long_member;.*\[\r\n\] float v_float_member;.*\[\r\n\] double v_double_member;.*\[\r\n\]\}.*" "ptype structure"
# Test the equivalence between '.' and '->' for struct member references.
*************** gdb_test "ptype struct link" "type = str
*** 100,106 ****
#
# test ptype command with unions
#
! gdb_test "ptype union t_union" "type = union t_union \{.*\[\r\n\] (unsigned |)char v_char_member;.*\[\r\n\] (short|short int) v_short_member;.*\[\r\n\] int v_int_member;.*\[\r\n\] (long|long int|int) v_long_member;.*\[\r\n\] float v_float_member;.*\[\r\n\] double v_double_member;.*\[\r\n\]\}.*" "ptype union"
# IBM's xlc puts out bogus stabs--the stuff field is type 42,
# which isn't defined.
--- 100,106 ----
#
# test ptype command with unions
#
! gdb_test "ptype union t_union" "type = union t_union \{.*\[\r\n\] (unsigned |)char v_char_member;.*\[\r\n\] (short|short int) v_short_member;.*\[\r\n\] int v_int_member;.*\[\r\n\] (long|long int|int) v_long_member;.*\[\r\n\] (long long|long long int) v_long_long_member;.*\[\r\n\] float v_float_member;.*\[\r\n\] double v_double_member;.*\[\r\n\]\}.*" "ptype union"
# IBM's xlc puts out bogus stabs--the stuff field is type 42,
# which isn't defined.
*************** gdb_test "ptype v_int" "type = int.*" "p
*** 236,241 ****
--- 236,242 ----
#
#send "ptype v_long\n"
#gdb_expect {
+ # -re "type = long long.*$gdb_prompt $" { fail "ptype long" }
# -re "type = long.*$gdb_prompt $" { pass "ptype long" }
# -re ".*$gdb_prompt $" { fail "ptype long" }
# timeout { fail "(timeout) ptype long" }
*************** gdb_test "ptype v_int" "type = int.*" "p
*** 244,249 ****
--- 245,251 ----
#
#send "ptype v_signed_long\n"
#gdb_expect {
+ # -re "type = long long.*$gdb_prompt $" { fail "ptype signed long" }
# -re "type = long.*$gdb_prompt $" { pass "ptype signed long" }
# -re ".*$gdb_prompt $" { fail "ptype signed long" }
# timeout { fail "(timeout) ptype signed long" }
*************** gdb_test "ptype v_int" "type = int.*" "p
*** 252,260 ****
--- 254,287 ----
#
#send "ptype v_unsigned_long\n"
#gdb_expect {
+ # -re "type = unsigned long long.*$gdb_prompt $" { fail "ptype unsigned long" }
# -re "type = unsigned long.*$gdb_prompt $" { pass "ptype unsigned long" }
# -re ".*$gdb_prompt $" { fail "ptype unsigned long" }
# timeout { fail "(timeout) ptype unsigned long" }
+ #}
+ #
+ #
+ #send "ptype v_long_long\n"
+ #gdb_expect {
+ # -re "type = long long.*$gdb_prompt $" { pass "ptype long long" }
+ # -re ".*$gdb_prompt $" { fail "ptype long long" }
+ # timeout { fail "(timeout) ptype long long" }
+ #}
+ #
+ #
+ #send "ptype v_signed_long_long\n"
+ #gdb_expect {
+ # -re "type = long long.*$gdb_prompt $" { pass "ptype signed long long" }
+ # -re ".*$gdb_prompt $" { fail "ptype signed long long" }
+ # timeout { fail "(timeout) ptype signed long long" }
+ #}
+ #
+ #
+ #send "ptype v_unsigned_long\n"
+ #gdb_expect {
+ # -re "type = unsigned long long.*$gdb_prompt $" { pass "ptype unsigned long long" }
+ # -re ".*$gdb_prompt $" { fail "ptype unsigned long long" }
+ # timeout { fail "(timeout) ptype unsigned long long" }
#}
#
#
Index: ptype.c
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.base/ptype.c,v
retrieving revision 1.1.1.3
diff -c -3 -p -r1.1.1.3 ptype.c
*** ptype.c 2000/01/06 03:06:51 1.1.1.3
--- ptype.c 2001/09/20 21:53:45
*************** long v_long;
*** 28,33 ****
--- 28,37 ----
signed long v_signed_long;
unsigned long v_unsigned_long;
+ long long v_long_long;
+ signed long long v_signed_long_long;
+ unsigned long long v_unsigned_long_long;
+
float v_float;
double v_double;
*************** long v_long_array[2];
*** 54,59 ****
--- 58,67 ----
signed long v_signed_long_array[2];
unsigned long v_unsigned_long_array[2];
+ long long v_long_long_array[2];
+ signed long long v_signed_long_long_array[2];
+ unsigned long long v_unsigned_long_long_array[2];
+
float v_float_array[2];
double v_double_array[2];
*************** long *v_long_pointer;
*** 78,83 ****
--- 86,95 ----
signed long *v_signed_long_pointer;
unsigned long *v_unsigned_long_pointer;
+ long long *v_long_long_pointer;
+ signed long long *v_signed_long_long_pointer;
+ unsigned long long *v_unsigned_long_long_pointer;
+
float *v_float_pointer;
double *v_double_pointer;
*************** struct t_struct {
*** 88,93 ****
--- 100,106 ----
short v_short_member;
int v_int_member;
long v_long_member;
+ long long v_long_long_member;
float v_float_member;
double v_double_member;
} v_struct1;
*************** struct {
*** 99,104 ****
--- 112,118 ----
short v_short_member;
int v_int_member;
long v_long_member;
+ long long v_long_long_member;
float v_float_member;
double v_double_member;
} v_struct2;
*************** union t_union {
*** 119,124 ****
--- 133,139 ----
short v_short_member;
int v_int_member;
long v_long_member;
+ long long v_long_long_member;
float v_float_member;
double v_double_member;
} v_union;
*************** union {
*** 128,133 ****
--- 143,149 ----
short v_short_member;
int v_int_member;
long v_long_member;
+ long long v_long_long_member;
float v_float_member;
double v_double_member;
} v_union2;
*************** long v_long_func () { return (0); }
*** 159,164 ****
--- 175,184 ----
signed long v_signed_long_func () { return (0); }
unsigned long v_unsigned_long_func () { return (0); }
+ long long v_long_long_func () { return (0); }
+ signed long long v_signed_long_long_func () { return (0); }
+ unsigned long long v_unsigned_long_long_func () { return (0); }
+
float v_float_func () { return (0.0); }
double v_double_func () { return (0.0); }
*************** int main ()
*** 268,273 ****
--- 288,297 ----
v_signed_long = 0;
v_unsigned_long = 0;
+ v_long_long = 0;
+ v_signed_long_long = 0;
+ v_unsigned_long_long = 0;
+
v_float = 0;
v_double = 0;
*************** int main ()
*** 287,292 ****
--- 311,320 ----
v_signed_long_array[0] = 0;
v_unsigned_long_array[0] = 0;
+ v_long_long_array[0] = 0;
+ v_signed_long_long_array[0] = 0;
+ v_unsigned_long_long_array[0] = 0;
+
v_float_array[0] = 0;
v_double_array[0] = 0;
*************** int main ()
*** 305,310 ****
--- 333,342 ----
v_long_pointer = 0;
v_signed_long_pointer = 0;
v_unsigned_long_pointer = 0;
+
+ v_long_long_pointer = 0;
+ v_signed_long_long_pointer = 0;
+ v_unsigned_long_long_pointer = 0;
v_float_pointer = 0;
v_double_pointer = 0;
From kettenis@science.uva.nl Thu Sep 20 15:06:00 2001
From: Mark Kettenis <kettenis@science.uva.nl>
To: Kevin Buettner <kevinb@cygnus.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [PATCH] solib-svr4.c: Fix set_solib_svr4_fetch_link_map_offsets
Date: Thu, 20 Sep 2001 15:06:00 -0000
Message-id: <s3ielp1ecwc.fsf@soliton.wins.uva.nl>
References: <1010920205607.ZM17368@ocotillo.lan>
X-SW-Source: 2001-09/msg00277.html
Content-length: 915
Kevin Buettner <kevinb@cygnus.com> writes:
> I mentioned above that I had run into a number of problems while
> creating a Linux/PPC specific link map offset fetcher. Fixes for the
> other problems I encountered will be addressed in other patches.
> As a heads up though, one of the problems is that solib-svr4.c
> actually contains (ifdef'd) shared library support for both SVR4 and
> SunOS. I will be disentangling these mechanisms and will place SunOS
> shared library support in its own file. That way we'll be able to do
> away with the SVR4_SHARED_LIBS macro and we won't accidentally attempt
> to ever include <link.h> from solib-svr4.c any longer.
I have been working on disentangling SVR4 (ELF) and SunOS (a.out)
shared library support a few weeks ago. It's not quite finished yet
(ELF is basically done, but I still need to finish the a.out stuff).
Perhaps we should coordinate our actions?
Mark
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2001-09-21 11:15 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-09-20 14:36 [RFA] Add "long long" tests to whatis.exp Michael Snyder
[not found] ` <7458-Fri21Sep2001101238+0300-eliz@is.elta.co.il>
2001-09-21 11:15 ` Michael Snyder
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox