@@ -0,0 +1,2351 @@
+package org.jvirtanen.philadelphia.perf;%0A%0Aimport static org.jvirtanen.philadelphia.fix42.FIX42Enumerations.*;%0Aimport static org.jvirtanen.philadelphia.fix42.FIX42MsgTypes.*;%0Aimport static org.jvirtanen.philadelphia.fix42.FIX42Tags.*;%0A%0Aimport java.nio.ByteBuffer;%0Aimport java.util.concurrent.TimeUnit;%0Aimport org.jvirtanen.philadelphia.FIXMessage;%0Aimport org.jvirtanen.philadelphia.FIXMessageOverflowException;%0Aimport org.jvirtanen.philadelphia.FIXValueOverflowException;%0Aimport org.openjdk.jmh.annotations.Benchmark;%0Aimport org.openjdk.jmh.annotations.BenchmarkMode;%0Aimport org.openjdk.jmh.annotations.Level;%0Aimport org.openjdk.jmh.annotations.Mode;%0Aimport org.openjdk.jmh.annotations.OutputTimeUnit;%0Aimport org.openjdk.jmh.annotations.Scope;%0Aimport org.openjdk.jmh.annotations.Setup;%0Aimport org.openjdk.jmh.annotations.State;%0Aimport org.openjdk.jmh.annotations.TearDown;%0A%0A@State(Scope.Thread)%0A@OutputTimeUnit(TimeUnit.NANOSECONDS)%0Apublic class FIXMessageBenchmark %7B%0A%0A    private FIXMessage message;%0A%0A    private ByteBuffer buffer;%0A%0A    @Setup(Level.Iteration)%0A    public void prepare() %7B%0A        message = new FIXMessage(32, 32);%0A%0A        message.addField(MsgType).setChar(OrderSingle);%0A        message.addField(SenderCompID).setString(%22initiator%22);%0A        message.addField(TargetCompID).setString(%22acceptor%22);%0A        message.addField(MsgSeqNum).setInt(2);%0A        message.addField(SendingTime).setString(%2220150924-09:30:05.250%22);%0A        message.addField(ClOrdID).setString(%22123%22);%0A        message.addField(HandlInst).setChar(HandlInstValues.AutomatedExecutionNoIntervention);%0A        message.addField(Symbol).setString(%22FOO%22);%0A        message.addField(Side).setChar(SideValues.Buy);%0A        message.addField(TransactTime).setString(%2220150924-09:30:05.250%22);%0A        message.addField(OrdType).setChar(OrdTypeValues.Limit);%0A        message.addField(Price).setFloat(150.25, 2);%0A%0A        buffer = ByteBuffer.allocate(1024);%0A%0A        message.put(buffer);%0A%0A        buffer.flip();%0A    %7D%0A%0A    @Benchmark%0A    @BenchmarkMode(Mode.SampleTime)%0A    public FIXMessage get() throws FIXMessageOverflowException, FIXValueOverflowException %7B%0A        message.get(buffer);%0A%0A        buffer.flip();%0A%0A        return message;%0A    %7D%0A%0A    @Benchmark%0A    @BenchmarkMode(Mode.SampleTime)%0A    public void put() %7B%0A        message.put(buffer);%0A%0A        buffer.flip();%0A    %7D%0A%0A%7D%0A

Add FIX message benchmark