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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gnat.dg/] [volatile8.adb] - Blame information for rev 774

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 696 jeremybenn
-- { dg-do compile }
2
-- { dg-options "-O2 -fdump-tree-optimized" }
3
 
4
function Volatile8 return Integer is
5
 
6
   type Vol is new Integer;
7
   pragma Volatile (Vol);
8
 
9
   type A is array (1..4) of Vol;
10
 
11
   V : A := (others => 0);
12
 
13
begin
14
   for J in 1 .. 10 loop
15
      V(1) := V(1) + 1;
16
   end loop;
17
 
18
   return Integer (V(1));
19
end;
20
 
21
-- { dg-final { scan-tree-dump "goto" "optimized" } }
22
-- { dg-final { cleanup-tree-dump "optimized" } }

powered by: WebSVN 2.1.0

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