~ubuntu-branches/ubuntu/quantal/starpu-contrib/quantal

« back to all changes in this revision

Viewing changes to gcc-plugin/tests/acquire.c

  • Committer: Package Import Robot
  • Author(s): Samuel Thibault
  • Date: 2012-04-12 15:04:15 UTC
  • mfrom: (1.1.2)
  • Revision ID: package-import@ubuntu.com-20120412150415-gzp107thb5wknugm
Tags: 1.0.1-1
* New upstream release.
* Explicitly use gcc-4.6 to fix plugin build (Closes: Bug#667381).
* Use gcc-4.5 for starpu, as nvcc does not actually support all 4.6
  features, notably not __float128.
* patches/relax-gcc-plugin: Relax gcc-4.6 dependency for plugins to upstream
  release version (Closes: #670422)
* watch: Fix URL.

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
 
21
21
#include <mocks.h>
22
22
 
 
23
static void
 
24
foo (char *x, int foo)
 
25
{
 
26
  expected_acquire_arguments.pointer = x;
 
27
#pragma starpu acquire x
 
28
}
 
29
 
 
30
 
23
31
int
24
32
main (int argc, char *argv[])
25
33
{
44
52
  expected_acquire_arguments.pointer = z;
45
53
#pragma starpu acquire z
46
54
 
 
55
  foo (z, 345);
 
56
 
47
57
  assert (data_register_calls == 2);
48
 
  assert (data_acquire_calls == 2);
 
58
  assert (data_acquire_calls == 3);
49
59
 
50
60
  return EXIT_SUCCESS;
51
61
}