Clean up compiler warnings#78
Conversation
/work/noaa/fv3-cam/djovic/ufs/ufs-weather-model/stochastic_physics/stochy_patterngenerator.F90(162): warning #8221: This integer constant is outside the default integer range - using INTEGER(8) instead. [2147483648]
count4 = mod(iseed(np) + 2147483648, 4294967296) - 2147483648
------------------------------------^
/work/noaa/fv3-cam/djovic/ufs/ufs-weather-model/stochastic_physics/stochy_data_mod.F90(488): remark #7713: This statement function has not been used. [INDLSOD] integer :: indev,indod,indlsod,indlsev,varid1,varid2,varid3,varid4,ierr --------------------------^ /work/noaa/fv3-cam/djovic/ufs/ufs-weather-model/stochastic_physics/stochy_data_mod.F90(488): remark #7713: This statement function has not been used. [INDLSEV] integer :: indev,indod,indlsod,indlsev,varid1,varid2,varid3,varid4,ierr ----------------------------------^
|
When code is compiled with debug flags (-DDEBUG=ON) I see additional warnings: Simplest way to fix this warning is to define plumes subroutine inside a module, for example plume_mod, and use that module in update_cells_sgs subroutine in update_ca.F90 |
…to fix compiler warning
|
There are also bunch or undeclared variables in spectral_transforms.F90: All these warnings are from RADBG_STOCHY subroutine, which uses two implicit real statements to declare real variables, like: I suggest we add |
|
One more warning about missing explicit interface: This sleep subroutine is called just before the stop statement, here: if(wrk(i) .eq. 0.0) then
write(6,*) ' la2ga: error'
call sleep(2)
stop
endif
enddo
return
!
end subroutine stochy_la2gaI think this call can just be removed. I do not see the need to sleep for 2 seconds before stopping the program. |
|
UFS PR #2225 is ready for merging. Please merge. |
copying @pjpegion as well. |
This PR cleans up compiler warnings when Intel compiler is used without a compiler flag that suppresses all warnings.
fixes: #73