aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorschnetter <schnetter@51d2df92-0e4f-0410-a727-bd43d766d6b6>2004-05-21 14:54:11 +0000
committerschnetter <schnetter@51d2df92-0e4f-0410-a727-bd43d766d6b6>2004-05-21 14:54:11 +0000
commit04df42c506fd6b0ac92315c46a40ee45e914d853 (patch)
treeeb4ba9acfcacd8937f244424dfa48495b850e076
parent86fa57d8ecd6f24301233858266dac39a51e1d6d (diff)
More interfaces
git-svn-id: http://svn.cactuscode.org/arrangements/CactusBase/Fortran/trunk@10 51d2df92-0e4f-0410-a727-bd43d766d6b6
-rw-r--r--src/cctk.F904
-rw-r--r--src/cctk_Interp.F9011
-rw-r--r--src/cctk_Main.F9050
-rw-r--r--src/cctk_Malloc.F9047
-rw-r--r--src/cctk_MemAlloc.F9039
-rw-r--r--src/cctk_Misc.F90105
-rw-r--r--src/make.code.defn4
7 files changed, 254 insertions, 6 deletions
diff --git a/src/cctk.F90 b/src/cctk.F90
index dbde6bb..396650e 100644
--- a/src/cctk.F90
+++ b/src/cctk.F90
@@ -32,5 +32,9 @@ module cctk
use cctk_IO
use cctk_IOMethods
use cctk_Interp
+ use cctk_Main
+ use cctk_Malloc
+ use cctk_MemAlloc
+ use cctk_Misc
implicit none
end module cctk
diff --git a/src/cctk_Interp.F90 b/src/cctk_Interp.F90
index 6495c1a..9fb9862 100644
--- a/src/cctk_Interp.F90
+++ b/src/cctk_Interp.F90
@@ -62,12 +62,8 @@ module cctk_Interp
integer num
end subroutine CCTK_NumInterpOperators
- end interface
-
- external CCTK_InterpGV
- external CCTK_InterpLocal
-
- interface
+ ! CCTK_InterpGV is declared below
+ ! CCTK_InterpLocal is declared below
subroutine CCTK_InterpLocalUniform &
(ierr, &
@@ -105,5 +101,8 @@ module cctk_Interp
end subroutine CCTK_InterpLocalUniform
end interface
+
+ external CCTK_InterpGV
+ external CCTK_InterpLocal
end module cctk_Interp
diff --git a/src/cctk_Main.F90 b/src/cctk_Main.F90
new file mode 100644
index 0000000..5f4a528
--- /dev/null
+++ b/src/cctk_Main.F90
@@ -0,0 +1,50 @@
+/*@@
+ @file $RCSfile$
+ @author $Author$
+ @date $Date$
+ @desc
+ Fortran 90 interface declarations for the routines
+ which have their C declarations in cctk_Main.h
+ @enddesc
+ @version $Header$
+@@*/
+
+#include "cctk.h"
+
+module cctk_Main
+ implicit none
+
+ interface
+
+ subroutine CCTK_Initialise (ierr, config)
+ implicit none
+ integer ierr
+ CCTK_POINTER config
+ end subroutine CCTK_Initialise
+
+ subroutine CCTK_Evolve (ierr, config)
+ implicit none
+ integer ierr
+ CCTK_POINTER config
+ end subroutine CCTK_Evolve
+
+ subroutine CCTK_Shutdown (ierr, config)
+ implicit none
+ integer ierr
+ CCTK_POINTER config
+ end subroutine CCTK_Shutdown
+
+ subroutine CCTK_MainLoopIndex (main_loop_index)
+ implicit none
+ integer main_loop_index
+ end subroutine CCTK_MainLoopIndex
+
+ subroutine CCTK_SetMainLoopIndex (ierr, main_loop_index)
+ implicit none
+ integer ierr
+ integer main_loop_index
+ end subroutine CCTK_SetMainLoopIndex
+
+ end interface
+
+end module cctk_Main
diff --git a/src/cctk_Malloc.F90 b/src/cctk_Malloc.F90
new file mode 100644
index 0000000..55d2775
--- /dev/null
+++ b/src/cctk_Malloc.F90
@@ -0,0 +1,47 @@
+/*@@
+ @file $RCSfile$
+ @author $Author$
+ @date $Date$
+ @desc
+ Fortran 90 interface declarations for the routines
+ which have their C declarations in cctk_Malloc.h
+ @enddesc
+ @version $Header$
+@@*/
+
+#include "cctk.h"
+
+module cctk_Malloc
+ implicit none
+
+ interface
+
+ subroutine CCTK_MemStat
+ implicit none
+ end subroutine CCTK_MemStat
+
+ subroutine CCTK_TotalMemory (amount)
+ implicit none
+ integer amount
+ end subroutine CCTK_TotalMemory
+
+ subroutine CCTK_MemTicketCash (diff, this_ticket)
+ implicit none
+ integer diff
+ integer this_ticket
+ end subroutine CCTK_MemTicketCash
+
+ subroutine CCTK_MemTicketRequest (ticket)
+ implicit none
+ integer ticket
+ end subroutine CCTK_MemTicketRequest
+
+ subroutine CCTK_MemTicketDelete (ierr, this_ticket)
+ implicit none
+ integer ierr
+ integer this_ticket
+ end subroutine CCTK_MemTicketDelete
+
+ end interface
+
+end module cctk_Malloc
diff --git a/src/cctk_MemAlloc.F90 b/src/cctk_MemAlloc.F90
new file mode 100644
index 0000000..eec8e04
--- /dev/null
+++ b/src/cctk_MemAlloc.F90
@@ -0,0 +1,39 @@
+/*@@
+ @file $RCSfile$
+ @author $Author$
+ @date $Date$
+ @desc
+ Fortran 90 interface declarations for the routines
+ which have their C declarations in cctk_MemAlloc.h
+ @enddesc
+ @version $Header$
+@@*/
+
+#include "cctk.h"
+
+module cctk_MemAlloc
+ implicit none
+
+ interface
+
+ subroutine CCTK_Malloc (ptr, size, line, file)
+ implicit none
+ CCTK_POINTER ptr
+ integer size
+ integer line
+ character(*) file
+ end subroutine CCTK_Malloc
+
+ subroutine CCTK_Free (ptr)
+ implicit none
+ CCTK_POINTER ptr
+ end subroutine CCTK_Free
+
+ subroutine CCTK_TotalMemory (size)
+ implicit none
+ integer size
+ end subroutine CCTK_TotalMemory
+
+ end interface
+
+end module cctk_MemAlloc
diff --git a/src/cctk_Misc.F90 b/src/cctk_Misc.F90
new file mode 100644
index 0000000..313fa33
--- /dev/null
+++ b/src/cctk_Misc.F90
@@ -0,0 +1,105 @@
+/*@@
+ @file $RCSfile$
+ @author $Author$
+ @date $Date$
+ @desc
+ Fortran 90 interface declarations for the routines
+ which have their C declarations in cctk_Misc.h
+ @enddesc
+ @version $Header$
+@@*/
+
+#include "cctk.h"
+
+module cctk_Misc
+ implicit none
+
+ interface
+
+ subroutine Util_SplitString (ierr, before, before_length, after, after_length, string, sep)
+ implicit none
+ integer ierr
+ character(*) before
+ integer before_length
+ character(*) after
+ integer after_length
+ character(*) string
+ character(*) sep
+ end subroutine Util_SplitString
+
+ ! CCTK_Equals is declared in cctk.h
+
+ subroutine CCTK_FortranString (nchars, c_string, f_string)
+ implicit none
+ integer nchars
+ CCTK_POINTER_TO_CONST c_string
+ character(*) f_string
+ end subroutine CCTK_FortranString
+
+ subroutine Util_NullTerminateString (c_string, f_string)
+ implicit none
+ CCTK_POINTER c_string
+ character(*) f_string
+ end subroutine Util_NullTerminateString
+
+ subroutine Util_IntInRange (inrange, inval, range)
+ implicit none
+ integer inrange
+ integer inval
+ character(*) range
+ end subroutine Util_IntInRange
+
+ subroutine Util_DoubleInRange (inrange, inval, range)
+ implicit none
+ integer inrange
+ double precision inval
+ character(*) range
+ end subroutine Util_DoubleInRange
+
+ subroutine CCTK_SetString (ierr, data, value)
+ implicit none
+ integer ierr
+ CCTK_POINTER data
+ character(*) value
+ end subroutine CCTK_SetString
+
+ subroutine CCTK_SetBoolean (ierr, data, value)
+ implicit none
+ integer ierr
+ CCTK_INT data
+ character(*) value
+ end subroutine CCTK_SetBoolean
+
+ subroutine CCTK_RunTime (time)
+ implicit none
+ integer time
+ end subroutine CCTK_RunTime
+
+ subroutine Util_CurrentTime (ierr, now)
+ implicit none
+ integer ierr
+ character(*) now
+ end subroutine Util_CurrentTime
+
+ subroutine Util_CurrentDate (ierr, now)
+ implicit none
+ integer ierr
+ character(*) now
+ end subroutine Util_CurrentDate
+
+ subroutine Util_RunTitle (ierr, title)
+ implicit none
+ integer ierr
+ character(*) title
+ end subroutine Util_RunTitle
+
+ end interface
+
+ external Util_InList
+ external IntInRangeList
+ external DoubleInRangeList
+ external SetDoubleInRangeList
+ external SetIntInRangeList
+ external SetKeywordInRangeList
+
+end module cctk_Misc
diff --git a/src/make.code.defn b/src/make.code.defn
index d024fad..4c12721 100644
--- a/src/make.code.defn
+++ b/src/make.code.defn
@@ -25,6 +25,10 @@ SRCS = cctk.F90 \
cctk_IO.F90 \
cctk_IOMethods.F90 \
cctk_Interp.F90 \
+ cctk_Main.F90 \
+ cctk_Malloc.F90 \
+ cctk_MemAlloc.F90 \
+ cctk_Misc.F90 \
util_Table.F90
else