diff --git a/testsuite/tests/concurrent/should_run/T5611.hs b/testsuite/tests/concurrent/should_run/T5611.hs
index 174da10e53f633cd3d8d6766b916f621d27f5da6..85efb23cf03b61f651a3379c9398e671a774f0d9 100644
--- a/testsuite/tests/concurrent/should_run/T5611.hs
+++ b/testsuite/tests/concurrent/should_run/T5611.hs
@@ -7,7 +7,7 @@ import System.IO
 
 #if defined(mingw32_HOST_OS)
 sleep n = sleepBlock (n*1000)
-foreign import stdcall safe "Sleep" sleepBlock :: Int -> IO ()
+foreign import ccall safe "Sleep" sleepBlock :: Int -> IO ()
 #else
 sleep n = void $ sleepBlock n
 foreign import ccall safe "sleep" sleepBlock :: Int -> IO Int
diff --git a/testsuite/tests/concurrent/should_run/T5611a.hs b/testsuite/tests/concurrent/should_run/T5611a.hs
index 6020c50a9d6419cd0aade73c8c523985c48f232f..1152d98209dbc5fab0b23eb8922ab7d637fc6375 100644
--- a/testsuite/tests/concurrent/should_run/T5611a.hs
+++ b/testsuite/tests/concurrent/should_run/T5611a.hs
@@ -9,7 +9,7 @@ import System.IO
 
 #if defined(mingw32_HOST_OS)
 sleep n = sleepBlock (n*1000)
-foreign import stdcall unsafe "Sleep" sleepBlock :: Int -> IO ()
+foreign import ccall unsafe "Sleep" sleepBlock :: Int -> IO ()
 #else
 sleep n = void $ sleepBlock n
 foreign import ccall unsafe "sleep" sleepBlock :: Int -> IO Int
diff --git a/testsuite/tests/concurrent/should_run/conc036.hs b/testsuite/tests/concurrent/should_run/conc036.hs
index 6bfee0336a8c8bc77db5552f6b94e7ad80348543..06381e8b4017951af6b97306563ad24484a83fd1 100644
--- a/testsuite/tests/concurrent/should_run/conc036.hs
+++ b/testsuite/tests/concurrent/should_run/conc036.hs
@@ -10,7 +10,7 @@ import System.IO
 
 #if defined(mingw32_HOST_OS)
 sleep n = sleepBlock (n*1000)
-foreign import stdcall unsafe "Sleep" sleepBlock :: Int -> IO ()
+foreign import ccall unsafe "Sleep" sleepBlock :: Int -> IO ()
 #else
 sleep n = sleepBlock n
 foreign import ccall unsafe "sleep" sleepBlock :: Int -> IO ()
diff --git a/testsuite/tests/concurrent/should_run/conc037.hs b/testsuite/tests/concurrent/should_run/conc037.hs
index 6f6d5e2d0af8eb1fbf6a8a01c15dcb8e22333410..6c0cd62f3342cb682f8993414dcfc341939f1cac 100644
--- a/testsuite/tests/concurrent/should_run/conc037.hs
+++ b/testsuite/tests/concurrent/should_run/conc037.hs
@@ -5,7 +5,7 @@ module Main where
 import Control.Concurrent
 
 #if defined(mingw32_HOST_OS)
-foreign import stdcall safe "Sleep" _sleepBlock :: Int -> IO ()
+foreign import ccall safe "Sleep" _sleepBlock :: Int -> IO ()
 sleepBlock n = _sleepBlock (n*1000)
 #else
 foreign import ccall safe "sleep" sleepBlock :: Int -> IO ()
@@ -24,4 +24,3 @@ main = do
   x <- takeMVar th
   putStrLn x
   putStrLn "\nshutting down"
-  
diff --git a/testsuite/tests/concurrent/should_run/conc038.hs b/testsuite/tests/concurrent/should_run/conc038.hs
index 5534646c76e3a232a4165cf4d5fba98571f0d987..38e5937d1bb8a72a533110679eaef7b71ccd3354 100644
--- a/testsuite/tests/concurrent/should_run/conc038.hs
+++ b/testsuite/tests/concurrent/should_run/conc038.hs
@@ -11,7 +11,7 @@ foreign export ccall "hFun"  haskellFun :: Int -> IO ()
 foreign import ccall safe "hFun"  hFun :: Int -> IO ()
 
 #if defined(mingw32_HOST_OS)
-foreign import stdcall safe "Sleep" _sleepBlock :: Int -> IO ()
+foreign import ccall safe "Sleep" _sleepBlock :: Int -> IO ()
 sleepBlock n = _sleepBlock (n*1000)
 #else
 foreign import ccall safe "sleep" sleepBlock :: Int -> IO ()
@@ -34,4 +34,3 @@ main = do
   x <- takeMVar th
   putStrLn x
   putStrLn "\nshutting down"
-
diff --git a/testsuite/tests/concurrent/should_run/foreignInterruptible.hs b/testsuite/tests/concurrent/should_run/foreignInterruptible.hs
index 6cd18388ed3d0afff9231e0184552e935a8fb46e..a41adfa9617c7836069b527f0afc1c6101b3b847 100644
--- a/testsuite/tests/concurrent/should_run/foreignInterruptible.hs
+++ b/testsuite/tests/concurrent/should_run/foreignInterruptible.hs
@@ -8,7 +8,7 @@ import System.IO
 
 #if defined(mingw32_HOST_OS)
 sleep n = sleepBlock (n*1000)
-foreign import stdcall interruptible "Sleep" sleepBlock :: Int -> IO ()
+foreign import ccall interruptible "Sleep" sleepBlock :: Int -> IO ()
 #else
 sleep n = sleepBlock n
 foreign import ccall interruptible "sleep" sleepBlock :: Int -> IO ()
diff --git a/testsuite/tests/diagnostic-codes/codes.stdout b/testsuite/tests/diagnostic-codes/codes.stdout
index ad93f29bac1b035571d91ac7737a66592ddc3020..ac3ae82fae904f943e20bc7e30fd28c1049510d4 100644
--- a/testsuite/tests/diagnostic-codes/codes.stdout
+++ b/testsuite/tests/diagnostic-codes/codes.stdout
@@ -56,7 +56,6 @@
 [GHC-63055] is untested (constructor = TcRnFieldUpdateInvalidType)
 [GHC-26133] is untested (constructor = TcRnForeignImportPrimSafeAnn)
 [GHC-03355] is untested (constructor = TcRnIllegalForeignDeclBackend)
-[GHC-01245] is untested (constructor = TcRnUnsupportedCallConv)
 [GHC-01570] is untested (constructor = TcRnExpectedValueId)
 [GHC-96665] is untested (constructor = TcRnMultipleInlinePragmas)
 [GHC-88293] is untested (constructor = TcRnUnexpectedPragmas)
@@ -119,5 +118,3 @@
 [GHC-75721] is untested (constructor = CannotRepresentType)
 [GHC-17599] is untested (constructor = AddTopDeclsUnexpectedDeclarationSplice)
 [GHC-86934] is untested (constructor = ClassPE)
-
-
diff --git a/testsuite/tests/ffi/should_compile/all.T b/testsuite/tests/ffi/should_compile/all.T
index cd0f66cd48f398d69f3a88adf1363551e600be7e..ab9931208c296b39a28430a36209de769d625302 100644
--- a/testsuite/tests/ffi/should_compile/all.T
+++ b/testsuite/tests/ffi/should_compile/all.T
@@ -6,13 +6,7 @@ setTestOpts(ffi)
 
 test('cc001', normal, compile, [''])
 
-# Non-static C call
-# cc004 test also uses stdcall, so it only works on i386.
-if config.platform.startswith('i386-'):
-    ways = normal
-else:
-    ways = expect_fail
-test('cc004', ways, compile, [''])
+test('cc004', expect_fail, compile, [''])
 
 test('cc005', normal, compile, [''])
 test('cc007', normal, compile, [''])
diff --git a/testsuite/tests/ffi/should_compile/cc004.hs b/testsuite/tests/ffi/should_compile/cc004.hs
index 915f054a0cb5a18b5dbc84f948af006400a7c76c..646b9b57590c95fd513f8f68f0f632799c44c53e 100644
--- a/testsuite/tests/ffi/should_compile/cc004.hs
+++ b/testsuite/tests/ffi/should_compile/cc004.hs
@@ -9,15 +9,9 @@ import Data.Word
 
 -- importing functions
 
--- We can't import the same function using both stdcall and ccall
--- calling conventions in the same file when compiling via C (this is a
--- restriction in the C backend caused by the need to emit a prototype
--- for stdcall functions).
 foreign import stdcall        "p" m_stdcall :: StablePtr a -> IO (StablePtr b)
 foreign import ccall   unsafe "q" m_ccall   :: ByteArray# -> IO Int
 
--- We can't redefine the calling conventions of certain functions (those from
--- math.h).
 foreign import stdcall "my_sin" my_sin :: Double -> IO Double
 foreign import stdcall "my_cos" my_cos :: Double -> IO Double
 
@@ -65,4 +59,3 @@ type Sink2 b = Ptr b
 
 foreign import ccall unsafe "dynamic"
   sink2 :: Ptr (Sink2 b) -> Sink2 b
-
diff --git a/testsuite/tests/ffi/should_run/T1288.hs b/testsuite/tests/ffi/should_run/T1288.hs
index c57b7c449d8efdbacb46ed7c506b3b47052a2169..d2796ad5284736fb374af97f71272041627fb182 100644
--- a/testsuite/tests/ffi/should_run/T1288.hs
+++ b/testsuite/tests/ffi/should_run/T1288.hs
@@ -1,6 +1,6 @@
 import Foreign
 import Foreign.C
 
-foreign import stdcall "test" ctest :: CInt -> IO ()
+foreign import ccall "test" ctest :: CInt -> IO ()
 
 main = ctest 3
diff --git a/testsuite/tests/ffi/should_run/T1288_c.c b/testsuite/tests/ffi/should_run/T1288_c.c
index 4ea5b13949a5ebc098cc288e27facd915b02c329..2fe90a989b5391bb4cb1d0081c924d3533381a3d 100644
--- a/testsuite/tests/ffi/should_run/T1288_c.c
+++ b/testsuite/tests/ffi/should_run/T1288_c.c
@@ -1,6 +1,6 @@
 #include <stdio.h>
 
-void __attribute__((stdcall)) test(int arg)
+void test(int arg)
 {
    printf("The argument passed was %i\n", arg );
 }
diff --git a/testsuite/tests/ffi/should_run/T1288_ghci.hs b/testsuite/tests/ffi/should_run/T1288_ghci.hs
index c57b7c449d8efdbacb46ed7c506b3b47052a2169..d2796ad5284736fb374af97f71272041627fb182 100644
--- a/testsuite/tests/ffi/should_run/T1288_ghci.hs
+++ b/testsuite/tests/ffi/should_run/T1288_ghci.hs
@@ -1,6 +1,6 @@
 import Foreign
 import Foreign.C
 
-foreign import stdcall "test" ctest :: CInt -> IO ()
+foreign import ccall "test" ctest :: CInt -> IO ()
 
 main = ctest 3
diff --git a/testsuite/tests/ffi/should_run/T1288_ghci_c.c b/testsuite/tests/ffi/should_run/T1288_ghci_c.c
index 4ea5b13949a5ebc098cc288e27facd915b02c329..2fe90a989b5391bb4cb1d0081c924d3533381a3d 100644
--- a/testsuite/tests/ffi/should_run/T1288_ghci_c.c
+++ b/testsuite/tests/ffi/should_run/T1288_ghci_c.c
@@ -1,6 +1,6 @@
 #include <stdio.h>
 
-void __attribute__((stdcall)) test(int arg)
+void test(int arg)
 {
    printf("The argument passed was %i\n", arg );
 }
diff --git a/testsuite/tests/ffi/should_run/T22159.hs b/testsuite/tests/ffi/should_run/T22159.hs
index 24e9511d3be42a5419ed8099ac557cc9ed5c42ed..a9b729661e3cf130a8c1fe80f14b90bf1a906efc 100644
--- a/testsuite/tests/ffi/should_run/T22159.hs
+++ b/testsuite/tests/ffi/should_run/T22159.hs
@@ -1,20 +1,12 @@
 {-# LANGUAGE CPP #-}
 module Main (main) where
 
-#if defined(i386_HOST_ARCH)
-# define WINDOWS_CCONV stdcall
-#elif defined(x86_64_HOST_ARCH)
-# define WINDOWS_CCONV ccall
-#else
-# error Unknown mingw32 arch
-#endif
-
 import Foreign.C.String (peekCWString)
 import Foreign.C.Types (CWchar)
 import Foreign.Marshal.Alloc (allocaBytes)
 import Foreign.Ptr (Ptr)
 
-foreign import WINDOWS_CCONV "hello" c_hello :: Ptr CWchar -> IO ()
+foreign import ccall "hello" c_hello :: Ptr CWchar -> IO ()
 
 main :: IO ()
 main = allocaBytes 12 $ \buf -> do
diff --git a/testsuite/tests/ffi/should_run/T2276.hs b/testsuite/tests/ffi/should_run/T2276.hs
index c7b14bd60dd345117ec10cd479189c46bd2099ef..7cd8696eff999ea31ffc0e74bedf848e44349bca 100644
--- a/testsuite/tests/ffi/should_run/T2276.hs
+++ b/testsuite/tests/ffi/should_run/T2276.hs
@@ -1,7 +1,7 @@
 import Foreign
 import Foreign.C
 
-foreign import stdcall "&test" ptest :: FunPtr (CInt -> IO ())
-foreign import stdcall "dynamic" ctest :: FunPtr (CInt -> IO ()) -> CInt -> IO ()
+foreign import ccall "&test" ptest :: FunPtr (CInt -> IO ())
+foreign import ccall "dynamic" ctest :: FunPtr (CInt -> IO ()) -> CInt -> IO ()
 
 main = ctest ptest 3
diff --git a/testsuite/tests/ffi/should_run/T2276_c.c b/testsuite/tests/ffi/should_run/T2276_c.c
index 4ea5b13949a5ebc098cc288e27facd915b02c329..2fe90a989b5391bb4cb1d0081c924d3533381a3d 100644
--- a/testsuite/tests/ffi/should_run/T2276_c.c
+++ b/testsuite/tests/ffi/should_run/T2276_c.c
@@ -1,6 +1,6 @@
 #include <stdio.h>
 
-void __attribute__((stdcall)) test(int arg)
+void test(int arg)
 {
    printf("The argument passed was %i\n", arg );
 }
diff --git a/testsuite/tests/ffi/should_run/T2276_ghci.hs b/testsuite/tests/ffi/should_run/T2276_ghci.hs
index c7b14bd60dd345117ec10cd479189c46bd2099ef..7cd8696eff999ea31ffc0e74bedf848e44349bca 100644
--- a/testsuite/tests/ffi/should_run/T2276_ghci.hs
+++ b/testsuite/tests/ffi/should_run/T2276_ghci.hs
@@ -1,7 +1,7 @@
 import Foreign
 import Foreign.C
 
-foreign import stdcall "&test" ptest :: FunPtr (CInt -> IO ())
-foreign import stdcall "dynamic" ctest :: FunPtr (CInt -> IO ()) -> CInt -> IO ()
+foreign import ccall "&test" ptest :: FunPtr (CInt -> IO ())
+foreign import ccall "dynamic" ctest :: FunPtr (CInt -> IO ()) -> CInt -> IO ()
 
 main = ctest ptest 3
diff --git a/testsuite/tests/ffi/should_run/T2276_ghci_c.c b/testsuite/tests/ffi/should_run/T2276_ghci_c.c
index 4ea5b13949a5ebc098cc288e27facd915b02c329..2fe90a989b5391bb4cb1d0081c924d3533381a3d 100644
--- a/testsuite/tests/ffi/should_run/T2276_ghci_c.c
+++ b/testsuite/tests/ffi/should_run/T2276_ghci_c.c
@@ -1,6 +1,6 @@
 #include <stdio.h>
 
-void __attribute__((stdcall)) test(int arg)
+void test(int arg)
 {
    printf("The argument passed was %i\n", arg );
 }
diff --git a/testsuite/tests/ffi/should_run/all.T b/testsuite/tests/ffi/should_run/all.T
index ef689e7b25aa208da4b25ce587c17f847f9569eb..404d4ffc4c49cb572c22c1204e8b2746e82afc36 100644
--- a/testsuite/tests/ffi/should_run/all.T
+++ b/testsuite/tests/ffi/should_run/all.T
@@ -61,17 +61,7 @@ else:
 test('ffi010', normal, compile_and_run, [''])
 test('ffi011', normal, compile_and_run, [''])
 
-# The stdcall calling convention works on Windows, and sometimes on
-# Linux, and fails everywhhere else.  For now, we test only on Windows,
-# because it's difficult to discover whether a given Linux supports
-# it.
-
-if config.os == 'mingw32':
-    skip_if_not_windows = normal
-else:
-    skip_if_not_windows = skip
-
-test('ffi012', skip_if_not_windows, compile_and_run, [''])
+test('ffi012', normal, warn_and_run, [''])
 test('ffi013', [normal, js_broken(22363)], compile_and_run, [''])
 
 # threaded2 sometimes gives ffi014: Main_dDu: interrupted
diff --git a/testsuite/tests/ffi/should_run/ffi012.ghc.stderr b/testsuite/tests/ffi/should_run/ffi012.ghc.stderr
new file mode 100644
index 0000000000000000000000000000000000000000..2dd6b5c4b5887bcc5ef08b32e1e49d38e4f216d1
--- /dev/null
+++ b/testsuite/tests/ffi/should_run/ffi012.ghc.stderr
@@ -0,0 +1,52 @@
+[1 of 2] Compiling Main             ( ffi012.hs, ffi012.o )
+ffi012.hs:11:1: warning: [GHC-01245] [-Wunsupported-calling-conventions (in -Wdefault)]
+    • the 'stdcall' calling convention is unsupported on this platform,
+      treating as ccall
+    • When checking declaration:
+        foreign import stdcall safe "wrapper" wrap_f :: F -> IO (FunPtr F)
+
+ffi012.hs:12:1: warning: [GHC-01245] [-Wunsupported-calling-conventions (in -Wdefault)]
+    • the 'stdcall' calling convention is unsupported on this platform,
+      treating as ccall
+    • When checking declaration:
+        foreign import stdcall safe "wrapper" wrap_f_io
+          :: IOF -> IO (FunPtr IOF)
+
+ffi012.hs:14:1: warning: [GHC-01245] [-Wunsupported-calling-conventions (in -Wdefault)]
+    • the 'stdcall' calling convention is unsupported on this platform,
+      treating as ccall
+    • When checking declaration:
+        foreign import stdcall safe "dynamic" f :: FunPtr F -> F
+
+ffi012.hs:15:1: warning: [GHC-01245] [-Wunsupported-calling-conventions (in -Wdefault)]
+    • the 'stdcall' calling convention is unsupported on this platform,
+      treating as ccall
+    • When checking declaration:
+        foreign import stdcall safe "dynamic" f_io :: FunPtr IOF -> IOF
+
+ffi012.hs:28:1: warning: [GHC-01245] [-Wunsupported-calling-conventions (in -Wdefault)]
+    • the 'stdcall' calling convention is unsupported on this platform,
+      treating as ccall
+    • When checking declaration:
+        foreign import stdcall safe "wrapper" wrap_d :: D -> IO (FunPtr D)
+
+ffi012.hs:29:1: warning: [GHC-01245] [-Wunsupported-calling-conventions (in -Wdefault)]
+    • the 'stdcall' calling convention is unsupported on this platform,
+      treating as ccall
+    • When checking declaration:
+        foreign import stdcall safe "wrapper" wrap_d_io
+          :: IOD -> IO (FunPtr IOD)
+
+ffi012.hs:31:1: warning: [GHC-01245] [-Wunsupported-calling-conventions (in -Wdefault)]
+    • the 'stdcall' calling convention is unsupported on this platform,
+      treating as ccall
+    • When checking declaration:
+        foreign import stdcall safe "dynamic" d :: FunPtr D -> D
+
+ffi012.hs:32:1: warning: [GHC-01245] [-Wunsupported-calling-conventions (in -Wdefault)]
+    • the 'stdcall' calling convention is unsupported on this platform,
+      treating as ccall
+    • When checking declaration:
+        foreign import stdcall safe "dynamic" d_io :: FunPtr IOD -> IOD
+
+[2 of 2] Linking ffi012
diff --git a/testsuite/tests/rts/Makefile b/testsuite/tests/rts/Makefile
index af677e899abe673af4b5211949d1aead37782abb..64f1a722389dec65db09f6b4e00c101405784a6b 100644
--- a/testsuite/tests/rts/Makefile
+++ b/testsuite/tests/rts/Makefile
@@ -64,16 +64,11 @@ T6006_setup :
 T8124_setup :
 	'$(TEST_HC)' $(TEST_HC_OPTS) -c T8124.hs
 
-ifeq "$(TARGETPLATFORM)" "i386-unknown-mingw32"
-T7037_CONST = const
-else
-T7037_CONST =
-endif
 .PHONY: T7037
 T7037:
 	$(RM) 7037.o 7037.hi 7037$(exeext)
 	"$(TEST_HC)" $(TEST_HC_OPTS) T7037.hs -v0
-	"$(TEST_HC)" -optc-DT7037_CONST=$(T7037_CONST) $(filter-out -rtsopts, $(TEST_HC_OPTS)) T7037_main.c -v0 -o T7037_main -no-hs-main
+	"$(TEST_HC)" $(filter-out -rtsopts, $(TEST_HC_OPTS)) T7037_main.c -v0 -o T7037_main -no-hs-main
 	./T7037_main
 
 T7040_ghci_setup :
diff --git a/testsuite/tests/rts/T12497.hs b/testsuite/tests/rts/T12497.hs
index e6498648420ac55eda63c66af0f80d583ee45c51..efbddc8641316ca1ea70cefad9906e6df5bbf13d 100644
--- a/testsuite/tests/rts/T12497.hs
+++ b/testsuite/tests/rts/T12497.hs
@@ -1,17 +1,7 @@
-{-# LANGUAGE CPP #-}
-
-#if defined(i386_HOST_ARCH)
-# define WINDOWS_CCONV stdcall
-#elif defined(x86_64_HOST_ARCH)
-# define WINDOWS_CCONV ccall
-#else
-# error Unknown mingw32 arch
-#endif
-
 import Foreign.C.String
 
-foreign import WINDOWS_CCONV "_strdup" strdup :: CString -> IO CString
-foreign import WINDOWS_CCONV "strdup" strdup2 :: CString -> IO CString
+foreign import ccall "_strdup" strdup :: CString -> IO CString
+foreign import ccall "strdup" strdup2 :: CString -> IO CString
 
 dupString :: String -> IO String
 dupString str = newCString str >>= strdup >>= peekCString
diff --git a/testsuite/tests/rts/T7037_main.c b/testsuite/tests/rts/T7037_main.c
index b85b98ec94ffba9dac103b9c8160c710e4a9f800..ab7c036ae98638ecbc5e52c1749e9ec08df87c21 100644
--- a/testsuite/tests/rts/T7037_main.c
+++ b/testsuite/tests/rts/T7037_main.c
@@ -2,6 +2,6 @@
 #include <unistd.h>
 
 int main(int argc, char *argv[]) {
-    char * T7037_CONST args[2] = {"T7037", NULL};
+    char * args[2] = {"T7037", NULL};
     execv("./T7037", args);
 }
diff --git a/testsuite/tests/rts/all.T b/testsuite/tests/rts/all.T
index a07c386a14c5c25c32aaeaac388f39b865557e8f..1a43dd3009404c21219be4cc96fa6a376b6ba042 100644
--- a/testsuite/tests/rts/all.T
+++ b/testsuite/tests/rts/all.T
@@ -239,8 +239,6 @@ def config_T5250(name, opts):
 
 test('T5250', [extra_files(['spalign.c']),
                 config_T5250,
-                # stack ptr is not 16-byte aligned on 32-bit Windows
-                when(platform('i386-unknown-mingw32'), expect_fail),
                 when(platform('i386-unknown-linux'),
                             expect_broken_for(4211,['llvm']))],
               compile_and_run, ['spalign.c'])
diff --git a/testsuite/tests/rts/linker/T11223/all.T b/testsuite/tests/rts/linker/T11223/all.T
index e58ca4afc8c70625c165874ea2bfff6b1c964d20..a7f01715ce599c63f6e366f813bcfa8a99a413b8 100644
--- a/testsuite/tests/rts/linker/T11223/all.T
+++ b/testsuite/tests/rts/linker/T11223/all.T
@@ -5,7 +5,7 @@ import re
 # Python normalization functions
 #--------------------------------------
 def normalise_duplicate_errmsg( msg ):
-     return re.sub(r"((?:[a-z, A-Z]+):|)[\/\\\\]+(?:.+[\/\\\\]+?)?(.+?)[\/\\\\]+", "    ", 
+     return re.sub(r"((?:[a-z, A-Z]+):|)[\/\\\\]+(?:.+[\/\\\\]+?)?(.+?)[\/\\\\]+", "    ",
                re.sub(r"version\s(\d+\.\d+\.\d+)\sfor\s[a-z,A-Z,0-9,_,-]+(?=\))", r"", msg))
 
 #--------------------------------------
@@ -33,7 +33,6 @@ test('T11223_simple_duplicate',
 
 test('T11223_simple_duplicate_lib',
      [extra_files(['bar.c', 'foo.c', 'foo.hs']),
-      when(platform('i386-unknown-mingw32'), expect_broken(13515)),
       when(ghc_dynamic(), skip), normalise_errmsg_fun(normalise_duplicate_errmsg),
       req_c],
      makefile_test, ['t_11223_simple_duplicate_lib'])
diff --git a/testsuite/tests/th/T23309A.hs b/testsuite/tests/th/T23309A.hs
index 749017fad60b6b2e7fabd06dd682df7114c42c5f..c84a856069885b915403a3ae09f2b886f2a11a8f 100644
--- a/testsuite/tests/th/T23309A.hs
+++ b/testsuite/tests/th/T23309A.hs
@@ -1,19 +1,6 @@
-{-# LANGUAGE CPP #-}
 module T23309A (c_foo) where
 
 import Foreign.C.String
 import Foreign.C.Types
 
-#if defined(mingw32_HOST_OS)
-# if defined(i386_HOST_ARCH)
-#  define CALLCONV stdcall
-# elif defined(x86_64_HOST_ARCH)
-#  define CALLCONV ccall
-# else
-#  error Unknown mingw32 arch
-# endif
-#else
-# define CALLCONV ccall
-#endif
-
-foreign import CALLCONV unsafe "foo" c_foo :: CInt -> IO CString
+foreign import ccall unsafe "foo" c_foo :: CInt -> IO CString
diff --git a/testsuite/timeout/WinCBindings.hsc b/testsuite/timeout/WinCBindings.hsc
index 983de3ae5319c79330447b4933d06f91e24bac79..0b1d505de44198564cccc014da223c1bd8aff2fd 100644
--- a/testsuite/timeout/WinCBindings.hsc
+++ b/testsuite/timeout/WinCBindings.hsc
@@ -3,14 +3,6 @@ module WinCBindings where
 
 #if defined(mingw32_HOST_OS)
 
-##if defined(i386_HOST_ARCH)
-## define WINDOWS_CCONV stdcall
-##elif defined(x86_64_HOST_ARCH)
-## define WINDOWS_CCONV ccall
-##else
-## error Unknown mingw32 arch
-##endif
-
 import Foreign
 import Foreign.C.Types
 import System.Win32.File
@@ -253,7 +245,7 @@ instance Storable JOBOBJECT_ASSOCIATE_COMPLETION_PORT where
             jacpCompletionPort = vCompletionPort}
 
 
-foreign import WINDOWS_CCONV unsafe "windows.h WaitForSingleObject"
+foreign import ccall unsafe "windows.h WaitForSingleObject"
     waitForSingleObject :: HANDLE -> DWORD -> IO DWORD
 
 type JOBOBJECTINFOCLASS = CInt
@@ -294,22 +286,22 @@ cCREATE_SUSPENDED = #const CREATE_SUSPENDED
 cHANDLE_FLAG_INHERIT :: DWORD
 cHANDLE_FLAG_INHERIT = #const HANDLE_FLAG_INHERIT
 
-foreign import WINDOWS_CCONV unsafe "windows.h GetExitCodeProcess"
+foreign import ccall unsafe "windows.h GetExitCodeProcess"
     getExitCodeProcess :: HANDLE -> LPDWORD -> IO BOOL
 
-foreign import WINDOWS_CCONV unsafe "windows.h CloseHandle"
+foreign import ccall unsafe "windows.h CloseHandle"
     closeHandle :: HANDLE -> IO BOOL
 
-foreign import WINDOWS_CCONV unsafe "windows.h TerminateJobObject"
+foreign import ccall unsafe "windows.h TerminateJobObject"
     terminateJobObject :: HANDLE -> UINT -> IO BOOL
 
-foreign import WINDOWS_CCONV unsafe "windows.h AssignProcessToJobObject"
+foreign import ccall unsafe "windows.h AssignProcessToJobObject"
     assignProcessToJobObject :: HANDLE -> HANDLE -> IO BOOL
 
-foreign import WINDOWS_CCONV unsafe "windows.h CreateJobObjectW"
+foreign import ccall unsafe "windows.h CreateJobObjectW"
     createJobObjectW :: LPSECURITY_ATTRIBUTES -> LPCTSTR -> IO HANDLE
 
-foreign import WINDOWS_CCONV unsafe "windows.h CreateProcessW"
+foreign import ccall unsafe "windows.h CreateProcessW"
     createProcessW :: LPCTSTR -> LPTSTR
                    -> LPSECURITY_ATTRIBUTES -> LPSECURITY_ATTRIBUTES
                    -> BOOL -> DWORD -> LPVOID -> LPCTSTR -> LPSTARTUPINFO
@@ -317,16 +309,16 @@ foreign import WINDOWS_CCONV unsafe "windows.h CreateProcessW"
 
 foreign import ccall unsafe "string.h" memset :: Ptr a -> CInt -> CSize -> IO (Ptr a)
 
-foreign import WINDOWS_CCONV unsafe "windows.h SetInformationJobObject"
+foreign import ccall unsafe "windows.h SetInformationJobObject"
     setInformationJobObject :: HANDLE -> JOBOBJECTINFOCLASS -> LPVOID -> DWORD -> IO BOOL
 
-foreign import WINDOWS_CCONV unsafe "windows.h CreateIoCompletionPort"
+foreign import ccall unsafe "windows.h CreateIoCompletionPort"
     createIoCompletionPort :: HANDLE -> HANDLE -> ULONG_PTR -> DWORD -> IO HANDLE
 
-foreign import WINDOWS_CCONV unsafe "windows.h GetQueuedCompletionStatus"
+foreign import ccall unsafe "windows.h GetQueuedCompletionStatus"
     getQueuedCompletionStatus :: HANDLE -> LPDWORD -> PULONG_PTR -> Ptr LPOVERLAPPED -> DWORD -> IO BOOL
 
-foreign import WINDOWS_CCONV unsafe "windows.h SetHandleInformation"
+foreign import ccall unsafe "windows.h SetHandleInformation"
     setHandleInformation :: HANDLE -> DWORD -> DWORD -> IO BOOL
 
 setJobParameters :: HANDLE -> IO BOOL
@@ -394,4 +386,3 @@ waitForJobCompletion _hJob ioPort timeout
                 then False -- Timeout occurred. *dark voice* YOU HAVE FAILED THIS TEST!.
                 else True
 #endif
-