From 1f2ca15ee52bd64a3cb64478bb7b983a956b4437 Mon Sep 17 00:00:00 2001 From: Joe Taylor Date: Sat, 17 Oct 2020 13:16:46 -0400 Subject: [PATCH] Allocate some big arrays on the heap. --- CMakeLists.txt | 2 +- lib/qra65_decode.f90 | 3 ++- lib/spec_qra65.f90 | 3 ++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index c88b61e10..05cf0ae6a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1382,7 +1382,7 @@ if (${OPENMP_FOUND} OR APPLE) endif (APPLE) if (WIN32) set_target_properties (jt9 PROPERTIES - LINK_FLAGS -Wl,--stack,28000000 + LINK_FLAGS -Wl,--stack,16777216 ) endif () target_link_libraries (jt9 wsjt_fort_omp wsjt_cxx fort_qt) diff --git a/lib/qra65_decode.f90 b/lib/qra65_decode.f90 index d79275f53..beb174527 100644 --- a/lib/qra65_decode.f90 +++ b/lib/qra65_decode.f90 @@ -51,7 +51,7 @@ contains character(len=6) :: hisgrid character*37 decoded !Decoded message integer*2 iwave(NMAX) !Raw data - real dd(NMAX) !Raw data + real, allocatable :: dd(:) !Raw data integer dat4(12) !Decoded message as 12 6-bit integers logical ltext complex, allocatable :: c00(:) !Analytic signal, 6000 Sa/s @@ -62,6 +62,7 @@ contains mode65=2**nsubmode nfft1=ntrperiod*12000 nfft2=ntrperiod*6000 + allocate(dd(NMAX)) allocate (c00(0:nfft1-1)) allocate (c0(0:nfft1-1)) diff --git a/lib/spec_qra65.f90 b/lib/spec_qra65.f90 index 9f6af0b38..15e8fd092 100644 --- a/lib/spec_qra65.f90 +++ b/lib/spec_qra65.f90 @@ -3,12 +3,13 @@ subroutine spec_qra65(c0,nsps,s3,LL,NN) ! Compute synchronized symbol spectra. complex c0(0:85*nsps-1) !Synchronized complex data at 6000 S/s - complex cs(0:nsps-1) !Complex symbol spectrum + complex, allocatable :: cs(:) !Complex symbol spectrum real s3(LL,NN) !Synchronized symbol spectra real xbase0(LL),xbase(LL) !Work arrays integer isync(22) !Indices of sync symbols data isync/1,9,12,13,15,22,23,26,27,33,35,38,46,50,55,60,62,66,69,74,76,85/ + allocate(cs(0:nsps-1)) fac=1.0/nsps j=0 n=1