data_request.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. /*
  2. * StarPU
  3. * Copyright (C) INRIA 2008-2009 (see AUTHORS file)
  4. *
  5. * This program is free software; you can redistribute it and/or modify
  6. * it under the terms of the GNU Lesser General Public License as published by
  7. * the Free Software Foundation; either version 2.1 of the License, or (at
  8. * your option) any later version.
  9. *
  10. * This program is distributed in the hope that it will be useful, but
  11. * WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  13. *
  14. * See the GNU Lesser General Public License in COPYING.LGPL for more details.
  15. */
  16. #ifndef __DATA_REQUEST_H__
  17. #define __DATA_REQUEST_H__
  18. #include <semaphore.h>
  19. #include <datawizard/coherency.h>
  20. #include <datawizard/copy-driver.h>
  21. #include <common/list.h>
  22. struct starpu_data_state_t;
  23. LIST_TYPE(data_request,
  24. struct starpu_data_state_t *state;
  25. uint32_t src_node;
  26. uint32_t dst_node;
  27. unsigned completed;
  28. int retval;
  29. );
  30. void init_data_request_lists(void);
  31. void deinit_data_request_lists(void);
  32. int post_data_request(struct starpu_data_state_t *state, uint32_t src_node, uint32_t dst_node);
  33. void handle_node_data_requests(uint32_t src_node);
  34. #endif // __DATA_REQUEST_H__