hello.F 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. C
  2. C StarPU --- Runtime system for heterogeneous multicore architectures.
  3. C
  4. C Copyright (C) 2009 Université Bordeaux 1
  5. C Copyright (C) 2010 Centre National de la Recherche Scientifique
  6. C
  7. C StarPU is free software; you can redistribute it and/or modify
  8. C it under the terms of the GNU Lesser General Public License as published by
  9. C the Free Software Foundation; either version 2.1 of the License, or (at
  10. C your option) any later version.
  11. C
  12. C StarPU is distributed in the hope that it will be useful, but
  13. C WITHOUT ANY WARRANTY; without even the implied warranty of
  14. C MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  15. C
  16. C See the GNU Lesser General Public License in COPYING.LGPL for more details.
  17. C
  18. #include "StarPU_fortran.h"
  19. SUBROUTINE HELLOSUB(X)
  20. INTEGER :: X
  21. WRITE(*,*) 'X =', X
  22. END SUBROUTINE
  23. PROGRAM HELLO
  24. USE STARPU_FORTRAN
  25. USE ISO_C_BINDING
  26. INTEGER :: TOTO
  27. TOTO = 42
  28. CALL STARPU_SUBMIT_CODELET(PRINT_INT, TOTO)
  29. C CALL STARPU_SUBMIT_CODELET(HELLOSUB, TOTO)
  30. C CALL DUMMY_C_FUNC(TOTO)
  31. END PROGRAM