From bbe9ae2704dd108c185f2a83f0466428465be456 Mon Sep 17 00:00:00 2001 From: Wolfgang Bangerth Date: Wed, 4 Feb 2004 16:12:25 +0000 Subject: [PATCH] In optimized mode, newer gccs can optimize the burn() function away entirely if the variable s is a local one. Make it global. git-svn-id: https://svn.dealii.org/trunk@8394 0785d39b-7218-0410-832d-ea1e28bc413d --- tests/base/timer.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/base/timer.cc b/tests/base/timer.cc index 7c957b0346..5a23e3e3f8 100644 --- a/tests/base/timer.cc +++ b/tests/base/timer.cc @@ -2,7 +2,7 @@ // $Id$ // Version: $Name$ // -// Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 by the deal.II authors +// Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004 by the deal.II authors // // This file is subject to QPL and may not be distributed // without copyright and license information. Please refer @@ -37,9 +37,9 @@ void compare (double t1, double t2, double ratio) // burn computer time +double s = 0.; void burn (unsigned int n) { - double s = 0.; for (unsigned int i=0 ; i