hello.F 1.1 KB

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