diff --git a/CHANGELOG.md b/CHANGELOG.md index 4a0add2e0..7f43fa512 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -78,6 +78,7 @@ Moreover, it generates a new file `seedname_band.labelinfo.dat` with information - Fix berry_task check for morb, and add check for kpoint_path block in parameters [[#258]](https://github.com/wannier-developers/wannier90/pull/258) +- Use 64 bit integer in io_wallclocktime [[#266]](https://github.com/wannier-developers/wannier90/pull/266) diff --git a/src/constants.F90 b/src/constants.F90 index 604c0363e..8b9a98043 100644 --- a/src/constants.F90 +++ b/src/constants.F90 @@ -29,6 +29,8 @@ module w90_constants private !~~ GENERIC CONSTANTS ~~! + integer, parameter, public :: i64 = selected_int_kind(15) + !! 64bit integer !aam_2012-04-11; fix to run on MacBook Air integer, parameter, public :: dp = kind(1.0d0) !! double precision diff --git a/src/io.F90 b/src/io.F90 index 9c90f7adf..589799e98 100644 --- a/src/io.F90 +++ b/src/io.F90 @@ -425,13 +425,13 @@ function io_wallclocktime() ! Returns elapsed wall clock time in seconds since its first call ! ! ! !=================================================================== - use w90_constants, only: dp + use w90_constants, only: dp, i64 implicit none real(kind=dp) :: io_wallclocktime - integer :: c0, c1 - integer :: rate + integer(kind=i64) :: c0, c1 + integer(kind=i64) :: rate logical :: first = .true. save first, rate, c0