Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

8264223: CodeHeap::verify fails extra_hops assertion in fastdebug test #3212

Closed
wants to merge 3 commits into from
Closed
Changes from all commits
Commits
File filter
Filter file types
Jump to
Jump to file
Failed to load files.

Always

Just for now

@@ -835,7 +835,10 @@ void CodeHeap::verify() {
}
}
assert(nseg == _next_segment, "CodeHeap: segment count mismatch. found %d, expected %d.", (int)nseg, (int)_next_segment);
assert((count == 0) || (extra_hops < (16 + 2*count)), "CodeHeap: many extra hops due to optimization. blocks: %d, extra hops: %d.", count, extra_hops);
assert(extra_hops <= _fragmentation_count, "CodeHeap: extra hops wrong. fragmentation: %d, extra hops: %d.", _fragmentation_count, extra_hops);
if (extra_hops >= (16 + 2 * count)) {
warning("CodeHeap: many extra hops due to optimization. blocks: %d, extra hops: %d.", count, extra_hops);
}

// Verify that the number of free blocks is not out of hand.
static int free_block_threshold = 10000;
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2010, 2021, 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
@@ -29,6 +29,14 @@
* @run main/othervm -Xcomp compiler.codegen.Test6935535
*/

/**
* @test
* @bug 8264223
* @summary add CodeHeap verification
*
* @requires vm.debug
* @run main/othervm -Xcomp -XX:+VerifyCodeCache compiler.codegen.Test6935535
*/
package compiler.codegen;

public class Test6935535 {
ProTip! Use n and p to navigate between commits in a pull request.