From: pthaugen Date: Fri, 14 May 2010 15:48:51 +0000 (+0000) Subject: * tree-ssa-loop.prefetch.c (prune_ref_by_group_reuse): Cast abs() X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3a4137294458e201f42049e4696ee86d1fd7cb4a;p=thirdparty%2Fgcc.git * tree-ssa-loop.prefetch.c (prune_ref_by_group_reuse): Cast abs() result to unsigned. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@159397 138bc75d-0d04-0410-961f-82ee72b054a4 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 1b727ad87dad..3d84fe834f4e 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2010-05-14 Pat Haugen + + * tree-ssa-loop.prefetch.c (prune_ref_by_group_reuse): Cast abs() + result to unsigned. + 2010-05-14 Tristan Gingold * toplev.c (default_debug_hooks): Remove this variable. diff --git a/gcc/tree-ssa-loop-prefetch.c b/gcc/tree-ssa-loop-prefetch.c index daf9956d3bc3..f828ed3f1a1d 100644 --- a/gcc/tree-ssa-loop-prefetch.c +++ b/gcc/tree-ssa-loop-prefetch.c @@ -717,7 +717,7 @@ prune_ref_by_group_reuse (struct mem_ref *ref, struct mem_ref *by, prefetch_before = (hit_from - delta_r + step - 1) / step; /* Do not reduce prefetch_before if we meet beyond cache size. */ - if (prefetch_before > abs (L2_CACHE_SIZE_BYTES / step)) + if (prefetch_before > (unsigned) abs (L2_CACHE_SIZE_BYTES / step)) prefetch_before = PREFETCH_ALL; if (prefetch_before < ref->prefetch_before) ref->prefetch_before = prefetch_before;