diff src/share/vm/utilities/hashtable.cpp @ 17709:f9e35a9dc8c7

8033792: AltHashing used jint for imprecise bit shifting Summary: AltHashing used jint the way of juint in bit shifting which could lead loss of precision. Fix by change _seed defined as juint. Reviewed-by: coleenp, ccheung Contributed-by: yumin.qi@oracle.com
author minqi
date Mon, 10 Feb 2014 21:29:14 -0800
parents 190899198332
children 524b54a7f1b5 152cf4afc11f
line wrap: on
line diff
--- a/src/share/vm/utilities/hashtable.cpp	Wed Mar 05 11:28:33 2014 -0800
+++ b/src/share/vm/utilities/hashtable.cpp	Mon Feb 10 21:29:14 2014 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2014, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -93,7 +93,7 @@
   return false;
 }
 
-template <class T, MEMFLAGS F> jint Hashtable<T, F>::_seed = 0;
+template <class T, MEMFLAGS F> juint Hashtable<T, F>::_seed = 0;
 
 // Create a new table and using alternate hash code, populate the new table
 // with the existing elements.   This can be used to change the hash code