Skip to content

Commit

Permalink
[Truffle] Call it load factor, as Java HashMap calls it.
Browse files Browse the repository at this point in the history
  • Loading branch information
eregon committed May 12, 2015
1 parent 9250f25 commit f93682c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ public Object setBuckets(VirtualFrame frame, RubyHash hash, Object key, Object v

// TODO CS 11-May-15 could store the next size for resize instead of doing a float operation each time

if (resizeProfile.profile(newSize / (double) entries.length > BucketsStrategy.MAX_LOAD_BALANCE)) {
if (resizeProfile.profile(newSize / (double) entries.length > BucketsStrategy.LOAD_FACTOR)) {
BucketsStrategy.resize(hash);
}
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

public abstract class BucketsStrategy {

public static final double MAX_LOAD_BALANCE = 0.75;
public static final double LOAD_FACTOR = 0.75;

public static final int SIGN_BIT_MASK = ~(1 << 31);

Expand Down

0 comments on commit f93682c

Please sign in to comment.