OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [gfortran.dg/] [c_by_val_1.f] - Blame information for rev 816

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 149 jeremybenn
C { dg-do run }
2
C { dg-additional-sources c_by_val.c }
3
C { dg-options "-ff2c -w -O0" }
4
 
5
      program c_by_val_1
6
      external   f_to_f, i_to_i, c_to_c
7
      real       a, b, c
8
      integer*4  i, j, k
9
      complex    u, v, w, c_to_c
10
 
11
      a = 42.0
12
      b = 0.0
13
      c = a
14
      call  f_to_f (b, %VAL (a), %REF (c), %LOC (c))
15
      if ((2.0 * a).ne.b) call abort ()
16
 
17
      i = 99
18
      j = 0
19
      k = i
20
      call i_to_i (j, %VAL (i), %REF (k), %LOC (k))
21
      if ((3 * i).ne.j) call abort ()
22
 
23
      u = (-1.0, 2.0)
24
      v = (1.0, -2.0)
25
      w = u
26
      v = c_to_c (%VAL (u), %REF (w), %LOC (w))
27
      if ((4.0 * u).ne.v) call abort ()
28
 
29
      stop
30
      end
31
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.