Java Code Examples for org.graalvm.compiler.debug.internal.method.MethodMetricsImpl

Following code examples demonstrate how to use org.graalvm.compiler.debug.internal.method.MethodMetricsImplfrom java. These examples are extracted from various highly rated open source projects. You can directly use these code snippets or view their entire linked source code. These snippets are extracted to provide contextual information about how to use this class in the real world. These samples also let you understand some good practices on how to use org.graalvm.compiler.debug.internal.method.MethodMetricsImpland various code implementation of this class.

        public void add(long value) {
            if (isEnabled()) {
                if (Debug.isMethodMeterEnabled()) {
                    MethodMetricsImpl.addToCurrentScopeMethodMetrics(getName(), value);
                }
                super.addToCurrentValue(value);
            }
        } 


        protected void interceptDifferenceFlat(long difference) {
            if (Debug.isMethodMeterEnabled()) {
                MethodMetricsImpl.addToCurrentScopeMethodMetrics(counter.flat.getName(), difference);
            }
        } 

        protected void interceptDifferenceAccm(long difference) {
            if (Debug.isMethodMeterEnabled()) {
                MethodMetricsImpl.addToCurrentScopeMethodMetrics(counter.getName(), difference);
            }
        } 

Advertisement
Javadoc
A list capturing all method metrics data of all the compiler threads. Every thread registers a refer

ence to its thread local map of compilation metrics in this list. During metrics dumping this list is globally locked and all method entries across all threads are merged to a result.

Read More
Advertisement