< prev index next >

src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCompiledCodeBuilder.java

Print this page

        

*** 34,45 **** import java.util.Comparator; import java.util.EnumMap; import java.util.List; import java.util.ListIterator; import java.util.Map; - import java.util.stream.Stream; - import java.util.stream.Stream.Builder; import org.graalvm.compiler.api.replacements.MethodSubstitution; import org.graalvm.compiler.api.replacements.Snippet; import org.graalvm.compiler.code.CompilationResult; import org.graalvm.compiler.code.CompilationResult.CodeAnnotation; --- 34,43 ----
*** 111,127 **** DataSection data = compResult.getDataSection(); byte[] dataSection = new byte[data.getSectionSize()]; ByteBuffer buffer = ByteBuffer.wrap(dataSection).order(ByteOrder.nativeOrder()); ! Builder<DataPatch> patchBuilder = Stream.builder(); data.buildDataSection(buffer, (position, vmConstant) -> { ! patchBuilder.accept(new DataPatch(position, new ConstantReference(vmConstant))); }); int dataSectionAlignment = data.getSectionAlignment(); ! DataPatch[] dataSectionPatches = patchBuilder.build().toArray(len -> new DataPatch[len]); int totalFrameSize = compResult.getTotalFrameSize(); StackSlot customStackArea = compResult.getCustomStackArea(); boolean isImmutablePIC = compResult.isImmutablePIC(); --- 109,125 ---- DataSection data = compResult.getDataSection(); byte[] dataSection = new byte[data.getSectionSize()]; ByteBuffer buffer = ByteBuffer.wrap(dataSection).order(ByteOrder.nativeOrder()); ! List<DataPatch> patches = new ArrayList<>(); data.buildDataSection(buffer, (position, vmConstant) -> { ! patches.add(new DataPatch(position, new ConstantReference(vmConstant))); }); int dataSectionAlignment = data.getSectionAlignment(); ! DataPatch[] dataSectionPatches = patches.toArray(new DataPatch[patches.size()]); int totalFrameSize = compResult.getTotalFrameSize(); StackSlot customStackArea = compResult.getCustomStackArea(); boolean isImmutablePIC = compResult.isImmutablePIC();
< prev index next >