diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/bfd/version.h ./bfd/version.h
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/bfd/version.h	2018-01-04 01:49:16.000000000 +0000
+++ ./bfd/version.h	2018-01-05 01:49:12.000000000 +0000
@@ -16,7 +16,7 @@
 
    In releases, the date is not included in either version strings or
    sonames.  */
-#define BFD_VERSION_DATE 20180104
+#define BFD_VERSION_DATE 20180105
 #define BFD_VERSION @bfd_version@
 #define BFD_VERSION_STRING  @bfd_version_package@ @bfd_version_string@
 #define REPORT_BUGS_TO @report_bugs_to@
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/djunpack.bat ./djunpack.bat
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/djunpack.bat	2018-01-04 01:53:04.000000000 +0000
+++ ./djunpack.bat	2018-01-05 01:52:59.000000000 +0000
@@ -17,8 +17,8 @@ Rem
 Rem The following 2 lines need to be changed with each new GDB release, to
 Rem be identical to the name of the top-level directory where the GDB
 Rem distribution unpacks itself.
-set GDBVER=$package-8.0.50.20180104
-if "%GDBVER%"=="$package-8.0.50.20180104" GoTo EnvOk
+set GDBVER=$package-8.0.50.20180105
+if "%GDBVER%"=="$package-8.0.50.20180105" GoTo EnvOk
 Rem If their environment space is too small, re-exec with a larger one
 command.com /e:4096 /c %0 %1
 GoTo End
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gcore.1 ./gdb/doc/gcore.1
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gcore.1	2018-01-04 01:52:58.000000000 +0000
+++ ./gdb/doc/gcore.1	2018-01-05 01:52:54.000000000 +0000
@@ -124,7 +124,7 @@
 .\" ========================================================================
 .\"
 .IX Title "GCORE 1"
-.TH GCORE 1 "2018-01-04" "gdb-8.0.50.20180104-git" "GNU Development Tools"
+.TH GCORE 1 "2018-01-05" "gdb-8.0.50.20180105-git" "GNU Development Tools"
 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
 .\" way too many mistakes in technical documents.
 .if n .ad l
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.1 ./gdb/doc/gdb.1
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.1	2018-01-04 01:52:58.000000000 +0000
+++ ./gdb/doc/gdb.1	2018-01-05 01:52:53.000000000 +0000
@@ -124,7 +124,7 @@
 .\" ========================================================================
 .\"
 .IX Title "GDB 1"
-.TH GDB 1 "2018-01-04" "gdb-8.0.50.20180104-git" "GNU Development Tools"
+.TH GDB 1 "2018-01-05" "gdb-8.0.50.20180105-git" "GNU Development Tools"
 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
 .\" way too many mistakes in technical documents.
 .if n .ad l
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info ./gdb/doc/gdb.info
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info	2018-01-04 01:52:55.000000000 +0000
+++ ./gdb/doc/gdb.info	2018-01-05 01:52:50.000000000 +0000
@@ -21,7 +21,7 @@ END-INFO-DIR-ENTRY
    This file documents the GNU debugger GDB.
 
    This is the Tenth Edition, of 'Debugging with GDB: the GNU
-Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180104-git.
+Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180105-git.
 
    Copyright (C) 1988-2018 Free Software Foundation, Inc.
 
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-1 ./gdb/doc/gdb.info-1
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-1	2018-01-04 01:52:43.000000000 +0000
+++ ./gdb/doc/gdb.info-1	2018-01-05 01:52:38.000000000 +0000
@@ -21,7 +21,7 @@ END-INFO-DIR-ENTRY
    This file documents the GNU debugger GDB.
 
    This is the Tenth Edition, of 'Debugging with GDB: the GNU
-Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180104-git.
+Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180105-git.
 
    Copyright (C) 1988-2018 Free Software Foundation, Inc.
 
@@ -44,7 +44,7 @@ Debugging with GDB
 
 This file describes GDB, the GNU symbolic debugger.
 
-   This is the Tenth Edition, for GDB (GDB) Version 8.0.50.20180104-git.
+   This is the Tenth Edition, for GDB (GDB) Version 8.0.50.20180105-git.
 
    Copyright (C) 1988-2018 Free Software Foundation, Inc.
 
@@ -501,7 +501,7 @@ Let us use GDB to try to see what is goi
      There is absolutely no warranty for GDB; type "show warranty"
       for details.
 
-     GDB 8.0.50.20180104-git, Copyright 1999 Free Software Foundation, Inc...
+     GDB 8.0.50.20180105-git, Copyright 1999 Free Software Foundation, Inc...
      (gdb)
 
 GDB reads only enough symbol data to know where to find the rest when
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-2 ./gdb/doc/gdb.info-2
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-2	2018-01-04 01:52:45.000000000 +0000
+++ ./gdb/doc/gdb.info-2	2018-01-05 01:52:40.000000000 +0000
@@ -21,7 +21,7 @@ END-INFO-DIR-ENTRY
    This file documents the GNU debugger GDB.
 
    This is the Tenth Edition, of 'Debugging with GDB: the GNU
-Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180104-git.
+Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180105-git.
 
    Copyright (C) 1988-2018 Free Software Foundation, Inc.
 
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-3 ./gdb/doc/gdb.info-3
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-3	2018-01-04 01:52:47.000000000 +0000
+++ ./gdb/doc/gdb.info-3	2018-01-05 01:52:42.000000000 +0000
@@ -21,7 +21,7 @@ END-INFO-DIR-ENTRY
    This file documents the GNU debugger GDB.
 
    This is the Tenth Edition, of 'Debugging with GDB: the GNU
-Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180104-git.
+Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180105-git.
 
    Copyright (C) 1988-2018 Free Software Foundation, Inc.
 
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-4 ./gdb/doc/gdb.info-4
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-4	2018-01-04 01:52:49.000000000 +0000
+++ ./gdb/doc/gdb.info-4	2018-01-05 01:52:45.000000000 +0000
@@ -21,7 +21,7 @@ END-INFO-DIR-ENTRY
    This file documents the GNU debugger GDB.
 
    This is the Tenth Edition, of 'Debugging with GDB: the GNU
-Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180104-git.
+Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180105-git.
 
    Copyright (C) 1988-2018 Free Software Foundation, Inc.
 
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-5 ./gdb/doc/gdb.info-5
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-5	2018-01-04 01:52:51.000000000 +0000
+++ ./gdb/doc/gdb.info-5	2018-01-05 01:52:46.000000000 +0000
@@ -21,7 +21,7 @@ END-INFO-DIR-ENTRY
    This file documents the GNU debugger GDB.
 
    This is the Tenth Edition, of 'Debugging with GDB: the GNU
-Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180104-git.
+Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180105-git.
 
    Copyright (C) 1988-2018 Free Software Foundation, Inc.
 
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-6 ./gdb/doc/gdb.info-6
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-6	2018-01-04 01:52:53.000000000 +0000
+++ ./gdb/doc/gdb.info-6	2018-01-05 01:52:48.000000000 +0000
@@ -21,7 +21,7 @@ END-INFO-DIR-ENTRY
    This file documents the GNU debugger GDB.
 
    This is the Tenth Edition, of 'Debugging with GDB: the GNU
-Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180104-git.
+Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180105-git.
 
    Copyright (C) 1988-2018 Free Software Foundation, Inc.
 
@@ -1500,7 +1500,7 @@ and TeX (or 'texi2roff') to typeset the 
 
    GDB includes an already formatted copy of the on-line Info version of
 this manual in the 'gdb' subdirectory.  The main Info file is
-'gdb-8.0.50.20180104-git/gdb/gdb.info', and it refers to subordinate
+'gdb-8.0.50.20180105-git/gdb/gdb.info', and it refers to subordinate
 files matching 'gdb.info*' in the same directory.  If necessary, you can
 print out these files, or read them with any editor; but they are easier
 to read using the 'info' subsystem in GNU Emacs or the standalone 'info'
@@ -1510,8 +1510,8 @@ program, available as part of the GNU Te
 Info formatting programs, such as 'texinfo-format-buffer' or 'makeinfo'.
 
    If you have 'makeinfo' installed, and are in the top level GDB source
-directory ('gdb-8.0.50.20180104-git', in the case of version
-8.0.50.20180104-git), you can make the Info file by typing:
+directory ('gdb-8.0.50.20180105-git', in the case of version
+8.0.50.20180105-git), you can make the Info file by typing:
 
      cd gdb
      make gdb.info
@@ -1536,7 +1536,7 @@ On its own, TeX cannot either read or ty
 
    If you have TeX and a DVI printer program installed, you can typeset
 and print this manual.  First switch to the 'gdb' subdirectory of the
-main source directory (for example, to 'gdb-8.0.50.20180104-git/gdb')
+main source directory (for example, to 'gdb-8.0.50.20180105-git/gdb')
 and type:
 
      make gdb.dvi
@@ -1545,8 +1545,8 @@ and type:
 
    ---------- Footnotes ----------
 
-   (1) In 'gdb-8.0.50.20180104-git/gdb/refcard.ps' of the version
-8.0.50.20180104-git release.
+   (1) In 'gdb-8.0.50.20180105-git/gdb/refcard.ps' of the version
+8.0.50.20180105-git release.
 
 
 File: gdb.info,  Node: Installing GDB,  Next: Maintenance Commands,  Prev: Formatting Documentation,  Up: Top
@@ -1664,39 +1664,39 @@ preparing GDB for installation; you can 
 a single directory, whose name is usually composed by appending the
 version number to 'gdb'.
 
-   For example, the GDB version 8.0.50.20180104-git distribution is in
-the 'gdb-8.0.50.20180104-git' directory.  That directory contains:
+   For example, the GDB version 8.0.50.20180105-git distribution is in
+the 'gdb-8.0.50.20180105-git' directory.  That directory contains:
 
-'gdb-8.0.50.20180104-git/configure (and supporting files)'
+'gdb-8.0.50.20180105-git/configure (and supporting files)'
      script for configuring GDB and all its supporting libraries
 
-'gdb-8.0.50.20180104-git/gdb'
+'gdb-8.0.50.20180105-git/gdb'
      the source specific to GDB itself
 
-'gdb-8.0.50.20180104-git/bfd'
+'gdb-8.0.50.20180105-git/bfd'
      source for the Binary File Descriptor library
 
-'gdb-8.0.50.20180104-git/include'
+'gdb-8.0.50.20180105-git/include'
      GNU include files
 
-'gdb-8.0.50.20180104-git/libiberty'
+'gdb-8.0.50.20180105-git/libiberty'
      source for the '-liberty' free software library
 
-'gdb-8.0.50.20180104-git/opcodes'
+'gdb-8.0.50.20180105-git/opcodes'
      source for the library of opcode tables and disassemblers
 
-'gdb-8.0.50.20180104-git/readline'
+'gdb-8.0.50.20180105-git/readline'
      source for the GNU command-line interface
 
-'gdb-8.0.50.20180104-git/glob'
+'gdb-8.0.50.20180105-git/glob'
      source for the GNU filename pattern-matching subroutine
 
-'gdb-8.0.50.20180104-git/mmalloc'
+'gdb-8.0.50.20180105-git/mmalloc'
      source for the GNU memory-mapped malloc package
 
    The simplest way to configure and build GDB is to run 'configure'
 from the 'gdb-VERSION-NUMBER' source directory, which in this example is
-the 'gdb-8.0.50.20180104-git' directory.
+the 'gdb-8.0.50.20180105-git' directory.
 
    First switch to the 'gdb-VERSION-NUMBER' source directory if you are
 not already in it; then run 'configure'.  Pass the identifier for the
@@ -1704,7 +1704,7 @@ platform on which GDB will run as an arg
 
    For example:
 
-     cd gdb-8.0.50.20180104-git
+     cd gdb-8.0.50.20180105-git
      ./configure HOST
      make
 
@@ -1726,8 +1726,8 @@ need to run 'sh' on it explicitly:
 
    If you run 'configure' from a directory that contains source
 directories for multiple libraries or programs, such as the
-'gdb-8.0.50.20180104-git' source directory for version
-8.0.50.20180104-git, 'configure' creates configuration files for every
+'gdb-8.0.50.20180105-git' source directory for version
+8.0.50.20180105-git, 'configure' creates configuration files for every
 directory level underneath (unless you tell it not to, with the
 '--norecursion' option).
 
@@ -1767,13 +1767,13 @@ to specify a path to find 'configure' it
 directory.  If the path to 'configure' would be the same as the argument
 to '--srcdir', you can leave out the '--srcdir' option; it is assumed.)
 
-   For example, with version 8.0.50.20180104-git, you can build GDB in a
+   For example, with version 8.0.50.20180105-git, you can build GDB in a
 separate directory for a Sun 4 like this:
 
-     cd gdb-8.0.50.20180104-git
+     cd gdb-8.0.50.20180105-git
      mkdir ../gdb-sun4
      cd ../gdb-sun4
-     ../gdb-8.0.50.20180104-git/configure sun4
+     ../gdb-8.0.50.20180105-git/configure sun4
      make
 
    When 'configure' builds a configuration using a remote source
@@ -1784,7 +1784,7 @@ the example, you'd find the Sun 4 librar
 
    Make sure that your path to the 'configure' script has just one
 instance of 'gdb' in it.  If your path to 'configure' looks like
-'../gdb-8.0.50.20180104-git/gdb/configure', you are configuring only one
+'../gdb-8.0.50.20180105-git/gdb/configure', you are configuring only one
 subdirectory of GDB, not the whole package.  This leads to build errors
 about missing include files such as 'bfd/bfd.h'.
 
@@ -1800,8 +1800,8 @@ a configured directory--whatever directo
 
    The 'Makefile' that 'configure' generates in each source directory
 also runs recursively.  If you type 'make' in a source directory such as
-'gdb-8.0.50.20180104-git' (or in a separate configured directory
-configured with '--srcdir=DIRNAME/gdb-8.0.50.20180104-git'), you will
+'gdb-8.0.50.20180105-git' (or in a separate configured directory
+configured with '--srcdir=DIRNAME/gdb-8.0.50.20180105-git'), you will
 build all the required libraries, and then build GDB.
 
    When you have multiple hosts or targets configured in separate
@@ -1846,7 +1846,7 @@ you can use it to test your guesses on a
      Invalid configuration `i986v': machine `i986v' not recognized
 
 'config.sub' is also distributed in the GDB source directory
-('gdb-8.0.50.20180104-git', for version 8.0.50.20180104-git).
+('gdb-8.0.50.20180105-git', for version 8.0.50.20180105-git).
 
 
 File: gdb.info,  Node: Configure Options,  Next: System-wide configuration,  Prev: Config Names,  Up: Installing GDB
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-7 ./gdb/doc/gdb.info-7
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdb.info-7	2018-01-04 01:52:55.000000000 +0000
+++ ./gdb/doc/gdb.info-7	2018-01-05 01:52:50.000000000 +0000
@@ -21,7 +21,7 @@ END-INFO-DIR-ENTRY
    This file documents the GNU debugger GDB.
 
    This is the Tenth Edition, of 'Debugging with GDB: the GNU
-Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180104-git.
+Source-Level Debugger' for GDB (GDB) Version 8.0.50.20180105-git.
 
    Copyright (C) 1988-2018 Free Software Foundation, Inc.
 
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdbinit.5 ./gdb/doc/gdbinit.5
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdbinit.5	2018-01-04 01:52:58.000000000 +0000
+++ ./gdb/doc/gdbinit.5	2018-01-05 01:52:54.000000000 +0000
@@ -124,7 +124,7 @@
 .\" ========================================================================
 .\"
 .IX Title "GDBINIT 5"
-.TH GDBINIT 5 "2018-01-04" "gdb-8.0.50.20180104-git" "GNU Development Tools"
+.TH GDBINIT 5 "2018-01-05" "gdb-8.0.50.20180105-git" "GNU Development Tools"
 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
 .\" way too many mistakes in technical documents.
 .if n .ad l
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdbserver.1 ./gdb/doc/gdbserver.1
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/doc/gdbserver.1	2018-01-04 01:52:58.000000000 +0000
+++ ./gdb/doc/gdbserver.1	2018-01-05 01:52:53.000000000 +0000
@@ -124,7 +124,7 @@
 .\" ========================================================================
 .\"
 .IX Title "GDBSERVER 1"
-.TH GDBSERVER 1 "2018-01-04" "gdb-8.0.50.20180104-git" "GNU Development Tools"
+.TH GDBSERVER 1 "2018-01-05" "gdb-8.0.50.20180105-git" "GNU Development Tools"
 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
 .\" way too many mistakes in technical documents.
 .if n .ad l
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/po/gdb.pot ./gdb/po/gdb.pot
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/po/gdb.pot	2018-01-04 01:52:32.000000000 +0000
+++ ./gdb/po/gdb.pot	2018-01-05 01:52:28.000000000 +0000
@@ -8,7 +8,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2018-01-04 01:52+0000\n"
+"POT-Creation-Date: 2018-01-05 01:52+0000\n"
 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/ChangeLog ./gdb/testsuite/ChangeLog
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/ChangeLog	2018-01-04 01:49:17.000000000 +0000
+++ ./gdb/testsuite/ChangeLog	2018-01-05 01:49:14.000000000 +0000
@@ -1,3 +1,23 @@
+2018-01-04  Joel Brobecker  <brobecker@adacore.com>
+
+	PR gdb/22670
+	* gdb.ada/maint_with_ada: New testcase.
+
+2018-01-04  Joel Brobecker  <brobecker@adacore.com>
+
+	PR gdb/22670
+	* gdb.ada/bp_c_mixed_case: New testcase.
+
+2018-01-04  Joel Brobecker  <brobecker@adacore.com>
+
+	PR gdb/22670
+	* gdb.ada/complete.exp: Add "complete break ada" test.
+
+2018-01-04  Joel Brobecker  <brobecker@adacore.com>
+
+	PR gdb/22670
+	* gdb.ada/info_addr_mixed_case: New testcase.
+
 2018-01-03  Xavier Roirand  <roirand@adacore.com>
 
 	* gdb.ada/excep_handle.exp: New testcase.
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/bp_c_mixed_case/bar.c ./gdb/testsuite/gdb.ada/bp_c_mixed_case/bar.c
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/bp_c_mixed_case/bar.c	1970-01-01 00:00:00.000000000 +0000
+++ ./gdb/testsuite/gdb.ada/bp_c_mixed_case/bar.c	2018-01-05 01:49:14.000000000 +0000
@@ -0,0 +1,21 @@
+/* Copyright 2018 Free Software Foundation, Inc.
+
+   This file is part of GDB.
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 3 of the License, or
+   (at your option) any later version.
+
+   This program is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
+
+void
+MixedCaseFunc (void)
+{
+}
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/bp_c_mixed_case/foo_h731_021.adb ./gdb/testsuite/gdb.ada/bp_c_mixed_case/foo_h731_021.adb
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/bp_c_mixed_case/foo_h731_021.adb	1970-01-01 00:00:00.000000000 +0000
+++ ./gdb/testsuite/gdb.ada/bp_c_mixed_case/foo_h731_021.adb	2018-01-05 01:49:14.000000000 +0000
@@ -0,0 +1,21 @@
+--  Copyright 2018 Free Software Foundation, Inc.
+--
+--  This program is free software; you can redistribute it and/or modify
+--  it under the terms of the GNU General Public License as published by
+--  the Free Software Foundation; either version 3 of the License, or
+--  (at your option) any later version.
+--
+--  This program is distributed in the hope that it will be useful,
+--  but WITHOUT ANY WARRANTY; without even the implied warranty of
+--  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+--  GNU General Public License for more details.
+--
+--  You should have received a copy of the GNU General Public License
+--  along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+procedure Foo_H731_021 is
+   Procedure C_Func;
+   pragma Import (C, C_Func, "MixedCaseFunc");
+begin
+   C_Func;
+end Foo_H731_021;
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/bp_c_mixed_case.exp ./gdb/testsuite/gdb.ada/bp_c_mixed_case.exp
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/bp_c_mixed_case.exp	1970-01-01 00:00:00.000000000 +0000
+++ ./gdb/testsuite/gdb.ada/bp_c_mixed_case.exp	2018-01-05 01:49:14.000000000 +0000
@@ -0,0 +1,52 @@
+# Copyright 2018 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+load_lib "ada.exp"
+
+standard_ada_testfile foo_h731_021
+
+set cfile "bar"
+set csrcfile ${srcdir}/${subdir}/${testdir}/${cfile}.c
+set cobject [standard_output_file ${cfile}.o]
+
+gdb_compile "${csrcfile}" "${cobject}" object [list debug]
+if {[gdb_compile_ada "${srcfile}" "${binfile}" executable [list debug additional_flags=-largs additional_flags=${cobject} additional_flags=-margs]] != "" } {
+  return -1
+}
+
+clean_restart ${testfile}
+
+if ![runto "foo_h731_021"] then {
+  perror "Couldn't run ${testfile}"
+  return
+}
+
+# Verify that the current language is Ada.
+gdb_test "show lang" \
+         "\"auto; currently ada\"\\."
+
+# Try inserting a breakpoint inside a C function. Because the function's
+# name has some uppercase letters, we need to use the "<...>" notation.
+# The purpose of this testcase is to verify that we can in fact do so
+# and that it inserts the breakpoint at the expected location.
+setup_kfail gdb/22670 "*-*-*"
+gdb_test "break <MixedCaseFunc>" \
+         "Breakpoint $decimal at $hex: file .*bar.c, line $decimal\\."
+
+# Resume the program's execution, verifying that it lands at the expected
+# location.
+setup_kfail gdb/22670 "*-*-*"
+gdb_test "continue" \
+         "Breakpoint $decimal, MixedCaseFunc \\(\\) at .*bar\\.c:$decimal.*"
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/complete.exp ./gdb/testsuite/gdb.ada/complete.exp
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/complete.exp	2018-01-04 01:49:17.000000000 +0000
+++ ./gdb/testsuite/gdb.ada/complete.exp	2018-01-05 01:49:14.000000000 +0000
@@ -204,3 +204,24 @@ test_gdb_complete "ambiguous_f" \
                   "p ambiguous_func"
 test_gdb_complete "ambiguous_func" \
                   "p ambiguous_func"
+
+# Perform a test intented to verify the behavior where the number
+# of possible completions is very large.  The goal is not to verify
+# precisely the list returned by the complete command (this depends
+# on too many parameters -- targets, compiler version, runtime, etc).
+# However, we want to sanity-check each one of them, knowing that
+# each result should start with "break ada" and that the proposed
+# completion should look like a valid symbol name (in particular,
+# no uppercase letters...).
+
+gdb_test_no_output "set max-completions unlimited"
+
+set test "complete break ada"
+gdb_test_multiple "$test" $test {
+    -re "^$test$eol\(break ada(\[a-z0-9._\])*$eol\)+$gdb_prompt $" {
+        pass $test
+    }
+    -re "\[A-Z\].*$gdb_prompt $" {
+        kfail gdb/22670 $test
+    }
+}
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/info_addr_mixed_case/foo.adb ./gdb/testsuite/gdb.ada/info_addr_mixed_case/foo.adb
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/info_addr_mixed_case/foo.adb	1970-01-01 00:00:00.000000000 +0000
+++ ./gdb/testsuite/gdb.ada/info_addr_mixed_case/foo.adb	2018-01-05 01:49:14.000000000 +0000
@@ -0,0 +1,21 @@
+--  Copyright 2018 Free Software Foundation, Inc.
+--
+--  This program is free software; you can redistribute it and/or modify
+--  it under the terms of the GNU General Public License as published by
+--  the Free Software Foundation; either version 3 of the License, or
+--  (at your option) any later version.
+--
+--  This program is distributed in the hope that it will be useful,
+--  but WITHOUT ANY WARRANTY; without even the implied warranty of
+--  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+--  GNU General Public License for more details.
+--
+--  You should have received a copy of the GNU General Public License
+--  along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+with Pck; use Pck;
+
+procedure Foo is
+begin
+   Do_Nothing (My_Table'Address); --  START
+end Foo;
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/info_addr_mixed_case/pck.adb ./gdb/testsuite/gdb.ada/info_addr_mixed_case/pck.adb
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/info_addr_mixed_case/pck.adb	1970-01-01 00:00:00.000000000 +0000
+++ ./gdb/testsuite/gdb.ada/info_addr_mixed_case/pck.adb	2018-01-05 01:49:14.000000000 +0000
@@ -0,0 +1,24 @@
+--  Copyright 2018 Free Software Foundation, Inc.
+--
+--  This program is free software; you can redistribute it and/or modify
+--  it under the terms of the GNU General Public License as published by
+--  the Free Software Foundation; either version 3 of the License, or
+--  (at your option) any later version.
+--
+--  This program is distributed in the hope that it will be useful,
+--  but WITHOUT ANY WARRANTY; without even the implied warranty of
+--  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+--  GNU General Public License for more details.
+--
+--  You should have received a copy of the GNU General Public License
+--  along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+package body Pck is
+
+   procedure Do_Nothing (A : System.Address) is
+   begin
+      null;
+   end Do_Nothing;
+
+end Pck;
+
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/info_addr_mixed_case/pck.ads ./gdb/testsuite/gdb.ada/info_addr_mixed_case/pck.ads
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/info_addr_mixed_case/pck.ads	1970-01-01 00:00:00.000000000 +0000
+++ ./gdb/testsuite/gdb.ada/info_addr_mixed_case/pck.ads	2018-01-05 01:49:14.000000000 +0000
@@ -0,0 +1,35 @@
+--  Copyright 2018 Free Software Foundation, Inc.
+--
+--  This program is free software; you can redistribute it and/or modify
+--  it under the terms of the GNU General Public License as published by
+--  the Free Software Foundation; either version 3 of the License, or
+--  (at your option) any later version.
+--
+--  This program is distributed in the hope that it will be useful,
+--  but WITHOUT ANY WARRANTY; without even the implied warranty of
+--  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+--  GNU General Public License for more details.
+--
+--  You should have received a copy of the GNU General Public License
+--  along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+with System;
+
+package Pck is
+
+   type Float_Array is array (Integer range <>) of Integer;
+   type Float_Ptr   is access Float_Array;
+
+   type Table_Type is (One, Two, Three, Four, Five);
+   type New_Table_Array is array (Table_Type) of Float_Ptr;
+
+   My_Table : New_Table_Array := (others => new Float_Array'((4 => 16#DE#,
+                                                              5 => 16#AD#)));
+
+   My_F : Float_Ptr := new Float_Array'(4 => 16#BE#,
+                                        5 => 16#EF#);
+
+   procedure Do_Nothing (A : System.Address);
+
+end Pck;
+
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/info_addr_mixed_case.exp ./gdb/testsuite/gdb.ada/info_addr_mixed_case.exp
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/info_addr_mixed_case.exp	1970-01-01 00:00:00.000000000 +0000
+++ ./gdb/testsuite/gdb.ada/info_addr_mixed_case.exp	2018-01-05 01:49:14.000000000 +0000
@@ -0,0 +1,42 @@
+# Copyright 2018 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+load_lib "ada.exp"
+
+standard_ada_testfile foo
+
+if {[gdb_compile_ada "${srcfile}" "${binfile}" executable [list debug ]] != "" } {
+  return -1
+}
+
+clean_restart ${testfile}
+
+set bp_location [gdb_get_line_number "START" ${testdir}/foo.adb]
+if ![runto "foo.adb:$bp_location" ] then {
+  perror "Couldn't run ${testfile}"
+  return
+}
+
+# The following test exercises the situation when uppercase letters
+# are used in the name of the symbol passed to the "info address"
+# command.  This should not make a difference, as the language is
+# Ada, and Ada is case-insensitive.
+
+# commit b5ec771e60c1a0863e51eb491c85c674097e9e13 (Introduce
+# lookup_name_info and generalize Ada's FULL/WILD name matching)
+# caused the following test to fail. KFAIL it while investigating...
+setup_kfail gdb/22670 "*-*-*"
+gdb_test "info address My_Table" \
+         "Symbol \"pck\\.my_table\" is static storage at address $hex\\."
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/maint_with_ada/pack.adb ./gdb/testsuite/gdb.ada/maint_with_ada/pack.adb
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/maint_with_ada/pack.adb	1970-01-01 00:00:00.000000000 +0000
+++ ./gdb/testsuite/gdb.ada/maint_with_ada/pack.adb	2018-01-05 01:49:14.000000000 +0000
@@ -0,0 +1,25 @@
+--  Copyright 2015-2017 Free Software Foundation, Inc.
+--
+--  This program is free software; you can redistribute it and/or modify
+--  it under the terms of the GNU General Public License as published by
+--  the Free Software Foundation; either version 3 of the License, or
+--  (at your option) any later version.
+--
+--  This program is distributed in the hope that it will be useful,
+--  but WITHOUT ANY WARRANTY; without even the implied warranty of
+--  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+--  GNU General Public License for more details.
+--
+--  You should have received a copy of the GNU General Public License
+--  along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+package body Pack is
+
+   function Identity (I : Integer) return Integer is
+   begin
+      return I;
+   end Identity;
+
+   procedure Do_Nothing (A : Array_Type) is null;
+
+end Pack;
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/maint_with_ada/pack.ads ./gdb/testsuite/gdb.ada/maint_with_ada/pack.ads
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/maint_with_ada/pack.ads	1970-01-01 00:00:00.000000000 +0000
+++ ./gdb/testsuite/gdb.ada/maint_with_ada/pack.ads	2018-01-05 01:49:14.000000000 +0000
@@ -0,0 +1,29 @@
+--  Copyright 2015-2017 Free Software Foundation, Inc.
+--
+--  This program is free software; you can redistribute it and/or modify
+--  it under the terms of the GNU General Public License as published by
+--  the Free Software Foundation; either version 3 of the License, or
+--  (at your option) any later version.
+--
+--  This program is distributed in the hope that it will be useful,
+--  but WITHOUT ANY WARRANTY; without even the implied warranty of
+--  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+--  GNU General Public License for more details.
+--
+--  You should have received a copy of the GNU General Public License
+--  along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+package Pack is
+   type Rec_Type is record
+      I : Integer;
+      B : Boolean;
+   end record;
+
+   type Vec_Type is array (1 .. 4) of Rec_Type;
+
+   type Array_Type is array (Positive range <>) of Vec_Type;
+
+   procedure Do_Nothing (A : Array_Type);
+   function Identity (I : Integer) return Integer;
+
+end Pack;
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/maint_with_ada/var_arr_typedef.adb ./gdb/testsuite/gdb.ada/maint_with_ada/var_arr_typedef.adb
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/maint_with_ada/var_arr_typedef.adb	1970-01-01 00:00:00.000000000 +0000
+++ ./gdb/testsuite/gdb.ada/maint_with_ada/var_arr_typedef.adb	2018-01-05 01:49:14.000000000 +0000
@@ -0,0 +1,28 @@
+--  Copyright 2015-2017 Free Software Foundation, Inc.
+--
+--  This program is free software; you can redistribute it and/or modify
+--  it under the terms of the GNU General Public License as published by
+--  the Free Software Foundation; either version 3 of the License, or
+--  (at your option) any later version.
+--
+--  This program is distributed in the hope that it will be useful,
+--  but WITHOUT ANY WARRANTY; without even the implied warranty of
+--  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+--  GNU General Public License for more details.
+--
+--  You should have received a copy of the GNU General Public License
+--  along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+with Pack; use Pack;
+
+procedure Var_Arr_Typedef is
+   RA : constant Rec_Type := (3, False);
+   RB : constant Rec_Type := (2, True);
+
+   VA : constant Vec_Type := (RA, RA, RB, RB);
+   VB : constant Vec_Type := (RB, RB, RA, RA);
+
+   A : constant Array_Type (1 .. Identity (4)) := (VA, VA, VB, VB);
+begin
+   Do_Nothing (A); --  BREAK
+end Var_Arr_Typedef;
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/maint_with_ada.exp ./gdb/testsuite/gdb.ada/maint_with_ada.exp
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/gdb/testsuite/gdb.ada/maint_with_ada.exp	1970-01-01 00:00:00.000000000 +0000
+++ ./gdb/testsuite/gdb.ada/maint_with_ada.exp	2018-01-05 01:49:14.000000000 +0000
@@ -0,0 +1,38 @@
+# Copyright 2015-2017 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+load_lib "ada.exp"
+
+standard_ada_testfile var_arr_typedef
+
+if {[gdb_compile_ada "${srcfile}" "${binfile}" executable [list debug ]] != "" } {
+  return -1
+}
+
+clean_restart ${testfile}
+
+# Insert a breakpoint in each compilation unit, to force their psymtab's
+# expansion to a full symtab.  This will allow the check-psymtabs command
+# to perform a more extensive check regarding those units which are in
+# Ada.
+
+gdb_breakpoint "adainit"
+gdb_breakpoint "Var_Arr_Typedef"
+gdb_breakpoint "Do_Nothing"
+
+setup_kfail gdb/22670 "*-*-*"
+gdb_test_no_output "maintenance check-psymtabs"
+
+gdb_test_no_output "maintenance check-symtabs"
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/include/ChangeLog ./include/ChangeLog
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/include/ChangeLog	2018-01-04 01:49:18.000000000 +0000
+++ ./include/ChangeLog	2018-01-05 01:49:14.000000000 +0000
@@ -1,3 +1,10 @@
+2018-01-04  Jim Wilson  <jimw@sifive.com>
+
+	* opcode/riscv-opc.h (CSR_SBADADDR): Rename to CSR_STVAL.  Rename
+	DECLARE_CSR entry.  Add alias to map sbadaddr to CSR_STVAL.
+	(CSR_MBADADDR): Rename to CSR_MTVAL.  Rename DECLARE_CSR entry.
+	Add alias to map mbadaddr to CSR_MTVAL.
+
 2018-01-03  Alan Modra  <amodra@gmail.com>
 
 	Update year range in copyright notice of all files.
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/include/opcode/riscv-opc.h ./include/opcode/riscv-opc.h
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/include/opcode/riscv-opc.h	2018-01-04 01:49:18.000000000 +0000
+++ ./include/opcode/riscv-opc.h	2018-01-05 01:49:14.000000000 +0000
@@ -651,7 +651,7 @@
 #define CSR_SSCRATCH 0x140
 #define CSR_SEPC 0x141
 #define CSR_SCAUSE 0x142
-#define CSR_SBADADDR 0x143
+#define CSR_STVAL 0x143
 #define CSR_SIP 0x144
 #define CSR_SATP 0x180
 #define CSR_MVENDORID 0xf11
@@ -668,7 +668,7 @@
 #define CSR_MSCRATCH 0x340
 #define CSR_MEPC 0x341
 #define CSR_MCAUSE 0x342
-#define CSR_MBADADDR 0x343
+#define CSR_MTVAL 0x343
 #define CSR_MIP 0x344
 #define CSR_PMPCFG0 0x3a0
 #define CSR_PMPCFG1 0x3a1
@@ -1192,7 +1192,7 @@ DECLARE_CSR(scounteren, CSR_SCOUNTEREN)
 DECLARE_CSR(sscratch, CSR_SSCRATCH)
 DECLARE_CSR(sepc, CSR_SEPC)
 DECLARE_CSR(scause, CSR_SCAUSE)
-DECLARE_CSR(sbadaddr, CSR_SBADADDR)
+DECLARE_CSR(stval, CSR_STVAL)
 DECLARE_CSR(sip, CSR_SIP)
 DECLARE_CSR(satp, CSR_SATP)
 DECLARE_CSR(mvendorid, CSR_MVENDORID)
@@ -1209,7 +1209,7 @@ DECLARE_CSR(mcounteren, CSR_MCOUNTEREN)
 DECLARE_CSR(mscratch, CSR_MSCRATCH)
 DECLARE_CSR(mepc, CSR_MEPC)
 DECLARE_CSR(mcause, CSR_MCAUSE)
-DECLARE_CSR(mbadaddr, CSR_MBADADDR)
+DECLARE_CSR(mtval, CSR_MTVAL)
 DECLARE_CSR(mip, CSR_MIP)
 DECLARE_CSR(pmpcfg0, CSR_PMPCFG0)
 DECLARE_CSR(pmpcfg1, CSR_PMPCFG1)
@@ -1353,8 +1353,12 @@ DECLARE_CSR(mhcounteren, CSR_MHCOUNTEREN
 #ifdef DECLARE_CSR_ALIAS
 /* Ubadaddr is 0x043 in 1.9.1, but 0x043 is utval in 1.10.  */
 DECLARE_CSR_ALIAS(ubadaddr, CSR_UTVAL)
+/* Sbadaddr is 0x143 in 1.9.1, but 0x143 is stval in 1.10.  */
+DECLARE_CSR_ALIAS(sbadaddr, CSR_STVAL)
 /* Sptbr is 0x180 in 1.9.1, but 0x180 is satp in 1.10.  */
 DECLARE_CSR_ALIAS(sptbr, CSR_SATP)
+/* Mbadaddr is 0x343 in 1.9.1, but 0x343 is mtval in 1.10.  */
+DECLARE_CSR_ALIAS(mbadaddr, CSR_MTVAL)
 #endif
 #ifdef DECLARE_CAUSE
 DECLARE_CAUSE("misaligned fetch", CAUSE_MISALIGNED_FETCH)
diff -a -u -r --new-file --show-function-line='^[A-Za-z_]' /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/md5.sum ./md5.sum
--- /sourceware/snapshot-tmp/gdb/snapshot/current-gdb/update-snapshot/old/gdb-8.0.50.20180104/md5.sum	2018-01-04 01:53:04.000000000 +0000
+++ ./md5.sum	2018-01-05 01:52:59.000000000 +0000
@@ -40,7 +40,7 @@ bb45f17458fbd361569bfb2067575c7f  bfd/cp
 f15e31835a8d7272e1acd59dc86ebc2a  bfd/wasm-module.c
 2f1d48da02b5ed6e94cb3beb7dae5d9c  bfd/elf64-mips.c
 32c1c2c183f56bd2b5af2fb9c3ca94af  bfd/cpu-m9s12x.c
-3dc6658c64690375a6a4f0851e188064  bfd/version.h
+2e9fb3afd45454b4bc6384605faf1b1f  bfd/version.h
 25cd4c1378787d5bb9fa74b13a55098a  bfd/cpu-tilegx.c
 15946361c2ae68e8133d7e10485f7ed4  bfd/coff-mcore.c
 836b9de6d0ea1914f82c0ec0fa0341ef  bfd/cpu-avr.c
@@ -4283,7 +4283,7 @@ d44d1fe2176806ee76348b558b3a67ab  gdb/te
 de055987af9fd672f5e6aa5280e504cf  gdb/testsuite/gdb.go/integers.exp
 68d17058fa82304a192749f0eadc138d  gdb/testsuite/gdb.go/strings.go
 81b7ed6cb92c627d245bd2efc4b953b9  gdb/testsuite/gdb.go/methods.go
-110bd764a402ea8d6e02148bb76790cc  gdb/testsuite/ChangeLog
+fe5f1dd7e00ad1a211555c7ca14d152f  gdb/testsuite/ChangeLog
 b3f11b21e5921c419a43f93720dedf85  gdb/testsuite/gdb.asm/empty.inc
 14f9e33160bd01242a862c5c90513000  gdb/testsuite/gdb.asm/asm-source.exp
 f1621bbbb2acbec5adef86d7d9549975  gdb/testsuite/gdb.asm/bfin.inc
@@ -4411,6 +4411,7 @@ c76200a5728a615af1cbdf56a030beef  gdb/te
 99ef03df1cd3c21f1e2432279dbcec79  gdb/testsuite/gdb.ada/formatted_ref/defs.adb
 04f5d611e6d1577ff044960cbdb24cb8  gdb/testsuite/gdb.ada/formatted_ref/defs.ads
 2e768cd6ea9073b607bbe056e825017d  gdb/testsuite/gdb.ada/formatted_ref/formatted_ref.adb
+ec056d17be7fcda0cc88933c8f2c4832  gdb/testsuite/gdb.ada/bp_c_mixed_case.exp
 4174cf52f38a0029798a5fa05adc3e3a  gdb/testsuite/gdb.ada/rec_comp/pck.ads
 bb10df3ae5a8e0c9445a6e4ab0aca307  gdb/testsuite/gdb.ada/rec_comp/bar_o203_012.adb
 5b6576ba90d145426975fe53c434319d  gdb/testsuite/gdb.ada/rec_comp/pck.adb
@@ -4433,6 +4434,8 @@ f82e58ac962ae2882163c49269d510b8  gdb/te
 cc93f5caa464eb7f5a79ea7b072afc64  gdb/testsuite/gdb.ada/bp_on_var/foo.adb
 d82bb537b0a4a9da2c119d2cb98236c0  gdb/testsuite/gdb.ada/bp_on_var/pck.ads
 25abbb967f927a36a07aa903b1512d49  gdb/testsuite/gdb.ada/bp_on_var/pck.adb
+6ebd2e607faa227c74be38da524013fb  gdb/testsuite/gdb.ada/bp_c_mixed_case/bar.c
+12e5efd6b3bf7efe8484c95169e09036  gdb/testsuite/gdb.ada/bp_c_mixed_case/foo_h731_021.adb
 23c12d92f0686d38ab3590044d7a0e34  gdb/testsuite/gdb.ada/bp_reset.exp
 fcefbc970a18796bfea7eaf89db0d593  gdb/testsuite/gdb.ada/frame_args/foo.adb
 3a9528181425a46e5ff2dec937013a63  gdb/testsuite/gdb.ada/frame_args/pck.ads
@@ -4471,7 +4474,7 @@ f3c5580cd867710062c933cd4f2b070c  gdb/te
 cf1677be9634f80b5681883a27897aaa  gdb/testsuite/gdb.ada/arraydim/pck.ads
 aec7f7e44549c26c7853286026a5f0f8  gdb/testsuite/gdb.ada/arraydim/inc.c
 ea96a429277fa23c07de5b2a07794ff5  gdb/testsuite/gdb.ada/arraydim/pck.adb
-b31ddea995ae525654e37c0a09236c8d  gdb/testsuite/gdb.ada/complete.exp
+bafc110046561cef212dab053d8014b0  gdb/testsuite/gdb.ada/complete.exp
 6b06618af3e7de938e216ceb0ad4ce1e  gdb/testsuite/gdb.ada/funcall_param.exp
 17803008cf0a50b6469371101afd9800  gdb/testsuite/gdb.ada/same_component_name/foo.adb
 d2b021c17e6a193b4b24dacaef6184e4  gdb/testsuite/gdb.ada/same_component_name/pck.ads
@@ -4601,6 +4604,9 @@ b68c269875a7d973a12d62ca635fd663  gdb/te
 c310b7636a49286678e0f4dc7f92ad00  gdb/testsuite/gdb.ada/py_range/pck.ads
 7f28ea3c41161d92e9668191fcf3f1fb  gdb/testsuite/gdb.ada/py_range/pck.adb
 ce737918d14d2555e8b452837940d822  gdb/testsuite/gdb.ada/tagged_access.exp
+6484894ba8ac1a6061090caa32178459  gdb/testsuite/gdb.ada/info_addr_mixed_case/foo.adb
+e9f1afba307735a568d1656e98d7ac93  gdb/testsuite/gdb.ada/info_addr_mixed_case/pck.ads
+ea7eebe9248785fbec0ae8de23886f71  gdb/testsuite/gdb.ada/info_addr_mixed_case/pck.adb
 6ddc197af50e18928be64c942b275670  gdb/testsuite/gdb.ada/dyn_stride/foo.adb
 2a030ec3e781993b8ed3844ae725a8fc  gdb/testsuite/gdb.ada/tasks/foo.adb
 888d78ea31193cd1fc63a6df19b8cf99  gdb/testsuite/gdb.ada/char_param/foo.adb
@@ -4673,6 +4679,9 @@ d4a25ee06668db421b64f12cb6698200  gdb/te
 91df874f04e71692fab25fa937c019a3  gdb/testsuite/gdb.ada/tagged_not_init.exp
 47a77ebf525a025705af3ceff79b1eb7  gdb/testsuite/gdb.ada/minsyms.exp
 424d309c53df21da4197c8d0214aad2c  gdb/testsuite/gdb.ada/tick_last_segv.exp
+622c79fb99b3e76e0272f6bc1321ae15  gdb/testsuite/gdb.ada/maint_with_ada/var_arr_typedef.adb
+932d29bac381dc131d2eaab05114155c  gdb/testsuite/gdb.ada/maint_with_ada/pack.ads
+e3ec6efa731b5fef8b3cbc4d49d1603c  gdb/testsuite/gdb.ada/maint_with_ada/pack.adb
 3c04d26b59788d20a2e94f7e9f3e7bc5  gdb/testsuite/gdb.ada/atomic_enum/foo.adb
 53947ba4341d47f8e1c20ffa9feddacc  gdb/testsuite/gdb.ada/atomic_enum/pck.ads
 7f7dc3ca39e88e60c1a0cbc9cc0859f3  gdb/testsuite/gdb.ada/atomic_enum/pck.adb
@@ -4700,6 +4709,7 @@ df46439ed3c1dd75c85d686ddc9fa31f  gdb/te
 3934dbd6758849902e62ecafe0bcf33a  gdb/testsuite/gdb.ada/widewide/foo.adb
 4174cf52f38a0029798a5fa05adc3e3a  gdb/testsuite/gdb.ada/widewide/pck.ads
 5b6576ba90d145426975fe53c434319d  gdb/testsuite/gdb.ada/widewide/pck.adb
+c5882f8e96ec355d2e4b8857b1c4966f  gdb/testsuite/gdb.ada/maint_with_ada.exp
 e72bf8ed9a1d5e31852424dbf42534c9  gdb/testsuite/gdb.ada/char_enum/foo.adb
 b4f6272d76b88a55fa816ce652374874  gdb/testsuite/gdb.ada/char_enum/pck.ads
 71fc8b4707e792fbfa04393a8c03c2fc  gdb/testsuite/gdb.ada/char_enum/pck.adb
@@ -4717,6 +4727,7 @@ e49e11e3d4e30b46e00839faac1e10d9  gdb/te
 0fd9d9bf2ae27a99387cdb3f847208a7  gdb/testsuite/gdb.ada/access_to_packed_array/pack.ads
 dd4f24d80006c3f91ee4521e7a8df1aa  gdb/testsuite/gdb.ada/access_to_packed_array/pack.adb
 d2c5316c90d08194a35eef468139f2a3  gdb/testsuite/gdb.ada/mi_exc_info.exp
+ba605aa5671d8a9062b64d4d20f3dde3  gdb/testsuite/gdb.ada/info_addr_mixed_case.exp
 fe796b1a72b8208f61abdae09f7c8e0d  gdb/testsuite/gdb.ada/catch_ex/foo.adb
 bffb96710cc121e21427f1a0a8f0c958  gdb/testsuite/gdb.ada/mi_var_array.exp
 973908792f39bc4b62c21f3c26a893d3  gdb/testsuite/gdb.ada/mi_interface.exp
@@ -4976,43 +4987,43 @@ d987581b55cf2107a9b92b7a0fd61e18  gdb/sy
 29209f0a84f981d84f100e8fc4c3a84b  gdb/f-valprint.c
 b6bbbfc248f90052ce30fda420c5916f  gdb/gdb_curses.h
 8108dd8f906f2654fecc74958cf383db  gdb/doc/psrc.sed
-eb99ffb2633745733581333f729cc411  gdb/doc/gdb.info-3
-9dca642d748a2d969bdc0ac3e15df55e  gdb/doc/gdb.info-4
+929a150795bd0fa2b027871363c44ccc  gdb/doc/gdb.info-3
+04ef8da27b08a014efff01e00c4735fc  gdb/doc/gdb.info-4
 ab0fe311032294b952da80585b8b90e7  gdb/doc/fdl.texi
 667bef4de7567c069421a0aa4b2b42ce  gdb/doc/Makefile.in
-d472c5d9b839dea56382750401bdee1a  gdb/doc/gdb.info-7
+371fa824f55c1966aae724ae25f46037  gdb/doc/gdb.info-7
 ce238ebd8ad1da77806acf2ccd2a592e  gdb/doc/observer.texi
-0a4dbad7f4e8926c621d88630b908c17  gdb/doc/gdbserver.1
+88f713fc08293783808126c19f6f3acc  gdb/doc/gdbserver.1
 8a3211e1c1b6c1a9ae823c3c469675e8  gdb/doc/guile.texi
 f81a0e00e0cb9e41b078069fb9bedb07  gdb/doc/stack_frame.txt
 319d74c658533df2b0bedcca97af4d94  gdb/doc/stabs.info
-0347866ac20a2d10098a0fbd49ebc89e  gdb/doc/gdb.info-5
+861cd7bce7e9b3f4217bd7981f0adf70  gdb/doc/gdb.info-5
 19abe6cc6d5cc545f19b7c7703223589  gdb/doc/agentexpr.texi
 66674dc351ba95941f422dc18cae24bb  gdb/doc/.gitignore
-710696855793a2d8fba8535f386b8d7d  gdb/doc/gdb.info-1
+fdcde95949e5e61953fc2d523af6e629  gdb/doc/gdb.info-1
 d5d06eaf9b4d44aa442a4a281aa9aea4  gdb/doc/a4rc.sed
-818cfd8cb6088814a64d78874819bfc9  gdb/doc/gdb.info-6
+763a9594a4e03db42a1a924d18b9e24f  gdb/doc/gdb.info-6
 31cbdd8332ee2f91513670303f5c73d0  gdb/doc/gdb.texinfo
 553b7fe1bf4b5d8b96fdb8cd83503de1  gdb/doc/stack_frame.svg
 04c82b1da7e894a6555868e4f86225af  gdb/doc/filter-for-doxygen
 6eef6173ced7b929f5142c1577f2189a  gdb/doc/Doxyfile-gdb-api.in
 26a572acbe3a2b351c0d3c0a2790b07d  gdb/doc/annotate.info
-2c61449c5054808ba840dbd49273a759  gdb/doc/gdb.info-2
+5131ec8fdf7d29d67ebdf421f7a40e64  gdb/doc/gdb.info-2
 0e44f6ffe6996c2827630e31909c3e1e  gdb/doc/refcard.tex
 6076d300a46651562d4ecd0604442414  gdb/doc/stack_frame.png
-60a45c9a42ba314aa65d9d50aa1935bd  gdb/doc/gdb.info
+1e450b2897f639ebfb80920a59478692  gdb/doc/gdb.info
 792ace4c71224d2dab899da2b265c147  gdb/doc/python.texi
 c3feb7ddebdf77fd82e65fc406bc2f23  gdb/doc/stabs.texinfo
 59b9502ecb343b50bcf56cbe20865eb6  gdb/doc/ChangeLog
-eeca6b36959b79435cc591c9590c823c  gdb/doc/gdb.1
-1cb257c0efe43158a502f4ed3a415795  gdb/doc/gcore.1
+3e502937fb7c538bce343f1b880f7d08  gdb/doc/gdb.1
+a8f6903de4da7f6e7034bfade8c4d7b1  gdb/doc/gcore.1
 d39233c86ed6a6dc9e853ae6a11fe03e  gdb/doc/stack_frame.pdf
 2ad37190a4e38a8186d90bc76fc4e551  gdb/doc/Doxyfile-base.in
 3e12b16a85438bdf1fd7355cd397282a  gdb/doc/all-cfg.texi
 bf96494e6e4d346175babd5ef9781882  gdb/doc/gpl.texi
 cd5e3faa9bd1b684a73c7d527cdb4988  gdb/doc/filter-params.pl
 7bfdb0765c5d050d204fbb30aeeba0d8  gdb/doc/stack_frame.eps
-986f0fe9c57d31466afbd7a0d2982f90  gdb/doc/gdbinit.5
+6afb9c04264ae2261a5d3f7aa07f21a7  gdb/doc/gdbinit.5
 78d7bd07699d6e1b53e552cc3a1c16ef  gdb/doc/Doxyfile-gdb-xref.in
 d398b8cec3d96f0f3267dac6b8fe64bb  gdb/doc/annotate.texinfo
 5863a78c1571978dc97dccb25e481134  gdb/doc/doxy-index.in
@@ -5506,7 +5517,7 @@ a9395d09415322faea2304f9a1d7d9e2  gdb/co
 c8ad35fbed9ae9f7955517bb9dfddaf3  gdb/std-regs.c
 94939358229d338905f052768534159b  gdb/go-lang.h
 08acbfe7a6b5373b372b4cbe252da59c  gdb/i386-windows-nat.c
-6613dddd4ecf4d908723272dc3f1281b  gdb/po/gdb.pot
+d0694f3517329bf6de368d4d607d5fd7  gdb/po/gdb.pot
 1851bff0653201a488dcae18dde7efad  gdb/po/gdbtext
 e8b91e30ff3b4173fc9a5cfa9eda097f  gdb/break-catch-syscall.c
 3067d957647d4c86486f09361b8e8c47  gdb/ada-lang.c
@@ -6428,7 +6439,7 @@ c7401f79eefa287ce888db7c98e84ad3  includ
 2ff90293241e370129bbe97280eef380  include/opcode/mn10300.h
 b78c069157e52028d07ad55b609ff169  include/opcode/m68k.h
 caf421fa76c94c3a01d16089e9a21d66  include/opcode/pru.h
-1c16e8f21e8293a11c51b391758c92dd  include/opcode/riscv-opc.h
+4c6415c49557b29fcea2c489673991f4  include/opcode/riscv-opc.h
 b0a660620a5b1650aa550e4d49dc0c3e  include/opcode/pyr.h
 3620013fa41b36a2ca991f51d7ebe191  include/opcode/i860.h
 74ddc1dfb6e5cd3da27b4b03abdd66a0  include/opcode/arc.h
@@ -6546,7 +6557,7 @@ ffcfe0cb01c0a38af7417bc9aa775e94  includ
 fe6a4b88c4a84f68a1549bd2b64963e9  include/ieee.h
 810af656d62bf4d126e8ac209c33fb19  include/hashtab.h
 e8bf8dd17f26a9cf31a3a56106772180  include/gcc-interface.h
-09675a28f434da8fefedf4cc4ad5f272  include/ChangeLog
+80ede8216d8ce73cc66bda2c415df12e  include/ChangeLog
 32675f876bdd16bed6ee1af989641429  include/dis-asm.h
 4aeeb52aa52171b54dd3cd19dc28770d  include/splay-tree.h
 1cc64c7ec7b7065e8ae4a879369655e4  include/filenames.h
