This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH v2] Support structure offsets that are 512K bytes or larger.
- From: Yao Qi <qiyaoltc at gmail dot com>
- To: David Taylor <dtaylor at emc dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Fri, 10 Jun 2016 09:54:35 +0100
- Subject: Re: [PATCH v2] Support structure offsets that are 512K bytes or larger.
- Authentication-results: sourceware.org; auth=none
- References: <1419 dot 1464988584 at usendtaylorx2l>
David Taylor <dtaylor@emc.com> writes:
Hi David,
> No regressions on x86-64 GNU/Linux.
I rebuild native i686-w64-mingw32 gdb with your patch, the build is
OK. The patch is good to me, some nits below. You can push it in if no
other comments in 3~4 days.
> * c-typeprint.c (c_type_print_base): When printing offset, use plongest, not %d.
This line is too long.
> @@ -723,11 +723,12 @@ pascal_object_print_value (struct type *type, const gdb_byte *valaddr,
>
> for (i = 0; i < n_baseclasses; i++)
> {
> - int boffset = 0;
> + LONGEST boffset = 0;
> struct type *baseclass = check_typedef (TYPE_BASECLASS (type, i));
> const char *basename = type_name_no_tag (baseclass);
> const gdb_byte *base_valaddr = NULL;
> - int thisoffset;
> + LONGEST thisoffset;
> + volatile struct gdb_exception ex; /* XXX */
'ex' is not used at all.
> diff --git a/gdb/testsuite/gdb.base/offsets.c b/gdb/testsuite/gdb.base/offsets.c
> new file mode 100644
> index 0000000..4923d33
> --- /dev/null
> +++ b/gdb/testsuite/gdb.base/offsets.c
> @@ -0,0 +1,28 @@
> +/* This testcase is part of GDB, the GNU debugger.
> +
> + Copyright 2015 Free Software Foundation, Inc.
2014 - 2016 [we start from 2014 because the test was posted in 2014]
> diff --git a/gdb/testsuite/gdb.base/offsets.exp b/gdb/testsuite/gdb.base/offsets.exp
> new file mode 100644
> index 0000000..42c0c5d
> --- /dev/null
> +++ b/gdb/testsuite/gdb.base/offsets.exp
> @@ -0,0 +1,45 @@
> +# Test big offsets
> +
> +# Copyright (c) 2015 Free Software Foundation, Inc.
2014 - 2016
--
Yao (éå)