Mercurial > hg > graal-compiler
comparison src/share/vm/code/debugInfo.hpp @ 17885:bd58c9e40d0a
8035735: Metaspace::contains become extremely slow in some cases
Summary: Call is_metadata instead which does less work for the call in debugInfo.hpp which is called for all compiled code stack frames.
Reviewed-by: jmasa, dcubed
author | coleenp |
---|---|
date | Mon, 03 Mar 2014 13:58:52 -0500 |
parents | 55fb97c4c58d |
children | b51e29501f30 52b4284cb496 |
comparison
equal
deleted
inserted
replaced
17884:cf9f24de0b93 | 17885:bd58c9e40d0a |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. | 2 * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. | 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * | 4 * |
5 * This code is free software; you can redistribute it and/or modify it | 5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as | 6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
271 assert(o == NULL || o->is_oop(), "oop only"); | 271 assert(o == NULL || o->is_oop(), "oop only"); |
272 return o; | 272 return o; |
273 } | 273 } |
274 Method* read_method() { | 274 Method* read_method() { |
275 Method* o = (Method*)(code()->metadata_at(read_int())); | 275 Method* o = (Method*)(code()->metadata_at(read_int())); |
276 assert(o == NULL || | 276 // is_metadata() is a faster check than is_metaspace_object() |
277 o->is_metaspace_object(), "meta data only"); | 277 assert(o == NULL || o->is_metadata(), "meta data only"); |
278 return o; | 278 return o; |
279 } | 279 } |
280 ScopeValue* read_object_value(); | 280 ScopeValue* read_object_value(); |
281 ScopeValue* get_cached_object(); | 281 ScopeValue* get_cached_object(); |
282 // BCI encoding is mostly unsigned, but -1 is a distinguished value | 282 // BCI encoding is mostly unsigned, but -1 is a distinguished value |