summaryrefslogtreecommitdiff
path: root/gcc/loop.c
diff options
context:
space:
mode:
authorsayle <sayle@138bc75d-0d04-0410-961f-82ee72b054a4>2005-01-02 00:15:01 +0000
committersayle <sayle@138bc75d-0d04-0410-961f-82ee72b054a4>2005-01-02 00:15:01 +0000
commit41e6d31e74f2b9e3ea8fbe3447e56195a18e6ba3 (patch)
tree7c808e0f9b99a5e60249250ee8aeb7d54e1559e0 /gcc/loop.c
parentd39c5ca0dc3ec7fb4dd419888cdf50f77ae450c4 (diff)
downloadgcc-41e6d31e74f2b9e3ea8fbe3447e56195a18e6ba3.tar.gz
PR rtl-optimization/12092
* loop.c (emit_prefetch_instructions): Do nothing if PREFETCH_BLOCK is zero. * gcc.dg/pr12092-1.c: New test case. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@92794 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/loop.c')
-rw-r--r--gcc/loop.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/gcc/loop.c b/gcc/loop.c
index faf6cb23b82..7a446eadc12 100644
--- a/gcc/loop.c
+++ b/gcc/loop.c
@@ -1,6 +1,7 @@
/* Perform various loop optimizations, including strength reduction.
- Copyright (C) 1987, 1988, 1989, 1991, 1992, 1993, 1994, 1995, 1996, 1997,
- 1998, 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
+ Copyright (C) 1987, 1988, 1989, 1991, 1992, 1993, 1994, 1995,
+ 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
+ Free Software Foundation, Inc.
This file is part of GCC.
@@ -4116,7 +4117,7 @@ emit_prefetch_instructions (struct loop *loop)
struct prefetch_info info[MAX_PREFETCHES];
struct loop_ivs *ivs = LOOP_IVS (loop);
- if (!HAVE_prefetch)
+ if (!HAVE_prefetch || PREFETCH_BLOCK == 0)
return;
/* Consider only loops w/o calls. When a call is done, the loop is probably