This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| _hashCode java/lang/Object.hashCode()I | |
| _getClass java/lang/Object.getClass()Ljava/lang/Class; | |
| _clone java/lang/Object.clone()Ljava/lang/Object; | |
| _dabs java/lang/Math.abs(D)D | |
| _dsin java/lang/Math.sin(D)D | |
| _dcos java/lang/Math.cos(D)D | |
| _dtan java/lang/Math.tan(D)D | |
| _datan2 java/lang/Math.atan2(DD)D | |
| _dsqrt java/lang/Math.sqrt(D)D | |
| _dlog java/lang/Math.log(D)D |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package bench; | |
| import org.openjdk.jmh.annotations.Benchmark; | |
| import org.openjdk.jmh.annotations.Param; | |
| import org.openjdk.jmh.annotations.Scope; | |
| import org.openjdk.jmh.annotations.Setup; | |
| import org.openjdk.jmh.annotations.State; | |
| import org.openjdk.jmh.annotations.Threads; | |
| import sun.misc.Unsafe; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const int ASSERT = 0 | |
| const int STACK_BIAS = 0 | |
| const int oopSize = 8 | |
| const int LogBytesPerWord = 3 | |
| const int BytesPerWord = 8 | |
| const int BytesPerLong = 8 | |
| const int LogKlassAlignmentInBytes = 3 | |
| const int ageTable::table_size = 16 | |
| const int BarrierSet::ModRef = 0 | |
| const int BarrierSet::CardTableModRef = 1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package bench; | |
| import org.openjdk.jmh.annotations.Benchmark; | |
| import org.openjdk.jmh.annotations.Param; | |
| import org.openjdk.jmh.annotations.Scope; | |
| import org.openjdk.jmh.annotations.Setup; | |
| import org.openjdk.jmh.annotations.State; | |
| import sun.misc.Unsafe; | |
| import java.lang.reflect.Field; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * Compile: gcc -I $JAVA_HOME/include -I $JAVA_HOME/include/linux -shared -fPIC -O3 -olibrafpatch.so -Wl,-soname,librafpatch.so rafpatch.c $JAVA_HOME/lib/amd64/libjava.so | |
| * Run: java -agentpath:/path/to/librafpatch.so MainClass | |
| */ | |
| #include <jvmti.h> | |
| #include <jni.h> | |
| #include <sys/types.h> | |
| #include <sys/stat.h> | |
| #include <unistd.h> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package bench; | |
| import org.openjdk.jmh.annotations.Benchmark; | |
| import org.openjdk.jmh.annotations.Scope; | |
| import org.openjdk.jmh.annotations.State; | |
| @State(Scope.Thread) | |
| public class InliningBenchmark { | |
| static volatile int value = 20; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * Copyright (C) 2014 Brett Wooldridge, Andrei Pangin | |
| * | |
| * Licensed under the Apache License, Version 2.0 (the "License"); | |
| * you may not use this file except in compliance with the License. | |
| * You may obtain a copy of the License at | |
| * | |
| * http://www.apache.org/licenses/LICENSE-2.0 | |
| * | |
| * Unless required by applicable law or agreed to in writing, software |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package lz4; | |
| import static lz4.LZ4Common.*; | |
| public class LZ4Array { | |
| private static long getLong(byte[] b, int p) { | |
| return (b[p] & 0xffL) | |
| | (b[p + 1] & 0xffL) << 8 | |
| | (b[p + 2] & 0xffL) << 16 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package bench; | |
| import org.openjdk.jmh.annotations.*; | |
| import java.util.*; | |
| import java.util.stream.Collectors; | |
| import java.util.stream.IntStream; | |
| @State(Scope.Benchmark) | |
| public class ListIndexOf { | |
| private static final Random random = new Random(0); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import com.sun.tools.attach.VirtualMachine; | |
| import java.nio.file.Paths; | |
| public class InjectAgent { | |
| public static void main(String[] args) throws Exception { | |
| String PID = args[0]; | |
| String agentJar = Paths.get("retransformer.jar").toAbsolutePath().toString(); |
OlderNewer