diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index 6fd6e4f8063..ac726851ace 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,3 +1,10 @@
+2016-01-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	* gdb.multi/goodbye.c: Fix compilation warnings by adding return types
+	and reordering the functions.
+	* gdb.multi/hangout.c: Likewise.
+	* gdb.multi/hello.c: Likewise.
+
 2016-01-08  Simon Marchi  <simon.marchi@ericsson.com>
 
 	* gdb.perf/lib/perftest/perftest.py: Change relative imports to
diff --git a/gdb/testsuite/gdb.multi/goodbye.c b/gdb/testsuite/gdb.multi/goodbye.c
index 701e504a3b7..bf7759a794c 100644
--- a/gdb/testsuite/gdb.multi/goodbye.c
+++ b/gdb/testsuite/gdb.multi/goodbye.c
@@ -39,6 +39,23 @@ int verylongfun()
   glob *= 9;
 }
 
+void
+mailand()
+{
+  glob = 46;
+}
+
+int
+foo(int x) {
+  return x + 92;
+}
+
+void
+goodbye() {
+  ++glob;
+}
+
+int
 main() {
   mailand();
   foo(glob);
@@ -46,17 +63,4 @@ main() {
   goodbye();
 }
 
-foo(int x) {
-  return x + 92;
-}
-
-mailand()
-{
-  glob = 46;
-}
-
 void commonfun() { mailand(); } /* from goodbye */
-
-goodbye() {
-  ++glob;
-}
diff --git a/gdb/testsuite/gdb.multi/hangout.c b/gdb/testsuite/gdb.multi/hangout.c
index e2c41b8c949..37015128739 100644
--- a/gdb/testsuite/gdb.multi/hangout.c
+++ b/gdb/testsuite/gdb.multi/hangout.c
@@ -17,6 +17,7 @@
 
 #include <stdio.h>
 
+int
 main(int argc, char *argv[])
 {
   int i;
diff --git a/gdb/testsuite/gdb.multi/hello.c b/gdb/testsuite/gdb.multi/hello.c
index efff59d0fa4..93d921f68a1 100644
--- a/gdb/testsuite/gdb.multi/hello.c
+++ b/gdb/testsuite/gdb.multi/hello.c
@@ -21,20 +21,23 @@ short hglob = 1;
 
 short glob = 92;
 
-int commonfun() { bar(); } /* from hello */
-
+void
 bar()
 {
   if (glob == 0)
     exit(1);
 }
 
+int commonfun() { bar(); } /* from hello */
+
+int
 hello(int x)
 {
   x *= 2;
   return x + 45;
 }
 
+int
 main()
 {
   int tmpx;