Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion make/test/BuildMicrobenchmark.gmk
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,20 @@ $(JMH_UNPACKED_JARS_DONE): $(JMH_RUNTIME_JARS)
$(RM) $(JMH_UNPACKED_DIR)/*.xml
$(TOUCH) $@

# Copy dependency files for inclusion in the benchmark JARs
$(eval $(call SetupCopyFiles, COPY_JAXP_TEST_XML, \
SRC := $(TOPDIR)/test/jaxp/javax/xml/jaxp/unittest, \
DEST := $(MICROBENCHMARK_CLASSES)/org/openjdk/bench/javax/xml, \
FILES := \
stream/XMLStreamWriterTest/message_12.xml \
validation/tck/reZ003vExc23082309.xml \
transform/msgAttach.xml, \
FLATTEN := true, \
))

# Create benchmarks JAR file with benchmarks for both the old and new JDK
$(eval $(call SetupJarArchive, BUILD_JDK_JAR, \
DEPENDENCIES := $(BUILD_JDK_MICROBENCHMARK) $(JMH_UNPACKED_JARS_DONE), \
DEPENDENCIES := $(BUILD_JDK_MICROBENCHMARK) $(JMH_UNPACKED_JARS_DONE) $(COPY_JAXP_TEST_XML), \
SRCS := $(MICROBENCHMARK_CLASSES) $(JMH_UNPACKED_DIR), \
BIN := $(MICROBENCHMARK_JAR_BIN), \
SUFFIXES := .*, \
Expand Down
6 changes: 2 additions & 4 deletions test/micro/org/openjdk/bench/javax/xml/AbstractXMLMicro.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2014, 2025, 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
Expand Down Expand Up @@ -38,15 +38,13 @@
@State(Scope.Benchmark)
public abstract class AbstractXMLMicro {

public static final String BUILDIMPL = "build-impl.xml";
public static final String LOGCOMP = "log_comp.xml";
public static final String MESSAGE12 = "message_12.xml";
public static final String MSGATTACH = "msgAttach.xml";
public static final String REZ = "reZ003vExc23082309.xml";

protected static final ConcurrentHashMap<String, byte[]> byteCache = new ConcurrentHashMap<>();

@Param({BUILDIMPL,LOGCOMP,MESSAGE12,MSGATTACH,REZ})
@Param({MESSAGE12,MSGATTACH,REZ})
protected String doc;

/**
Expand Down