Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[OpCode Benchmark] add benchmark files #3528

Draft
wants to merge 51 commits into
base: HF_Echidna
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
a7f7627
add benchmark files
Jim8y Oct 11, 2024
2213a14
Merge branch 'master' into opcode-bench-files
Jim8y Oct 12, 2024
ee45e63
fill some bench and result
Jim8y Oct 13, 2024
5452dc6
add more bench
Jim8y Oct 13, 2024
fbaf9e0
add more benchmark
Jim8y Oct 15, 2024
254c609
Benchmark native
Jim8y Oct 17, 2024
b2582a4
fix native bench
Jim8y Oct 18, 2024
d6bca11
Merge branch 'master' into opcode-bench-files
Jim8y Oct 25, 2024
bcbd449
update bench
Jim8y Nov 3, 2024
afa99ca
adopt light gc
Jim8y Nov 15, 2024
a6b3f69
format
Jim8y Nov 15, 2024
4874a6e
fix building issue in benchmark
Jim8y Nov 16, 2024
a8fd587
fix popitem
Jim8y Nov 16, 2024
4de3809
revert change
Jim8y Nov 17, 2024
d7cde61
revert to fix compatibillity
Jim8y Nov 17, 2024
e9061e5
Merge branch 'HF_Echidna' into rc-v2
Jim8y Nov 17, 2024
5d9d7c4
adopt new solution as using null rc, instead of making large scale ch…
Jim8y Nov 17, 2024
0ccd831
avoid change that is currently not necessary
Jim8y Nov 17, 2024
fc8df97
revert null default
Jim8y Nov 17, 2024
6acfc2c
revert null default
Jim8y Nov 17, 2024
2d6deab
revert null
Jim8y Nov 17, 2024
6200bdb
apply compound update and apply hardfork
Jim8y Nov 17, 2024
06fc016
fix stack
Jim8y Nov 17, 2024
4bb8043
fix applicationengine rc version issue
Jim8y Nov 17, 2024
e735b5e
update ut to adopt RCV2
Jim8y Nov 17, 2024
24efc8b
fix UT
Jim8y Nov 17, 2024
aa58fc9
update UT and bench, and apply hecate suggestion
Jim8y Nov 18, 2024
067d3bc
Merge branch 'HF_Echidna' into rc-v2
Jim8y Nov 18, 2024
83c3d2f
update exception message
Jim8y Nov 18, 2024
3b3d086
Merge branch 'master' into opcode-bench-files
Jim8y Nov 18, 2024
89671e7
revert change to vm
Jim8y Nov 18, 2024
c323ab7
Merge branch 'HF_Echidna' into opcode-bench-files
Jim8y Nov 18, 2024
cc3e3ca
Merge branch 'rc-v2' into opcode-bench-files
Jim8y Nov 18, 2024
2630930
add and fix more bench
Jim8y Nov 19, 2024
88c660d
do more bench
Jim8y Nov 21, 2024
a369d00
do more newarray bench
Jim8y Nov 21, 2024
678e1eb
try to apply new price rule
Jim8y Nov 26, 2024
4fb98e4
update to reverseN
Jim8y Nov 27, 2024
e7b37ba
try roman's comment
Jim8y Nov 30, 2024
0fda4aa
format
Jim8y Dec 10, 2024
1c4f944
Merge branch 'HF_Echidna' into opcode-bench-files
Jim8y Dec 10, 2024
1fd3ef8
HASKEY, KEYS
chenzhitong Dec 13, 2024
d443853
NEWARRAY0, NEWSTRUCT0, PICKITEM
chenzhitong Dec 16, 2024
3ed8968
BitwiseLogic
chenzhitong Dec 16, 2024
f589590
CAT, LEFT, RIGHT
chenzhitong Dec 16, 2024
db3de28
DROP, DUP
chenzhitong Dec 16, 2024
cdac5a4
NIP, OVER, PICK
chenzhitong Dec 16, 2024
0f2afdc
REVERSE3, REVERSE4, ROLL, ROT, TUCK
chenzhitong Dec 16, 2024
2999b31
CONVERT
chenzhitong Dec 18, 2024
1c23e0c
Updated Neo.VM.Benchmarks
chenzhitong Dec 20, 2024
c5f6328
Merge branch 'HF_Echidna' into opcode-bench-files
chenzhitong Dec 20, 2024
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
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.GE.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.GE.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_GE : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.GT.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.GT.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_GT : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.LE.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.LE.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_LE : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.LT.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.LT.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_LT : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.MODMUL.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.MODMUL.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_MODMUL : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.MODPOW.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.MODPOW.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_MODPOW : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.NOT.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.NOT.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_NOT : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.NUMEQUAL.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.NUMEQUAL.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_NUMEQUAL : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.NUMNOTEQUAL.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_NUMNOTEQUAL : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.POW.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.POW.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_POW : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.SHL.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.SHL.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_SHL : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.SHR.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.SHR.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_SHR : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.SIGN.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.SIGN.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_SIGN : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arithmetic/OpCode.SQRT.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.SQRT.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_SQRT : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arrays/OpCode.APPEND.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.APPEND.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_APPEND : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arrays/OpCode.CLEARITEMS.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.CLEARITEMS.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_CLEARITEMS : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
22 changes: 22 additions & 0 deletions benchmarks/Neo.VM.Benchmarks/OpCode/Arrays/OpCode.HASKEY.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Copyright (C) 2015-2024 The Neo Project.
//
// OpCode.HASKEY.cs file belongs to the neo project and is free
// software distributed under the MIT software license, see the
// accompanying file LICENSE in the main directory of the
// repository or http://www.opensource.org/licenses/mit-license.php
// for more details.
//
// Redistribution and use in source and binary forms with or without
// modifications are permitted.

namespace Neo.VM.Benchmark.OpCode;

public class OpCode_HASKEY : OpCodeBase
{
protected override byte[] CreateScript(BenchmarkMode benchmarkMode)
{
var builder = new InstructionBuilder();

return builder.ToArray();
}
}
Loading
Loading