@@ -29,13 +29,15 @@ static void MempoolEviction(benchmark::State& state)
29
29
CMutableTransaction tx1 = CMutableTransaction ();
30
30
tx1.vin .resize (1 );
31
31
tx1.vin [0 ].scriptSig = CScript () << OP_1;
32
+ tx1.vin [0 ].scriptWitness .stack .push_back ({1 });
32
33
tx1.vout .resize (1 );
33
34
tx1.vout [0 ].scriptPubKey = CScript () << OP_1 << OP_EQUAL;
34
35
tx1.vout [0 ].nValue = 10 * COIN;
35
36
36
37
CMutableTransaction tx2 = CMutableTransaction ();
37
38
tx2.vin .resize (1 );
38
39
tx2.vin [0 ].scriptSig = CScript () << OP_2;
40
+ tx2.vin [0 ].scriptWitness .stack .push_back ({2 });
39
41
tx2.vout .resize (1 );
40
42
tx2.vout [0 ].scriptPubKey = CScript () << OP_2 << OP_EQUAL;
41
43
tx2.vout [0 ].nValue = 10 * COIN;
@@ -44,6 +46,7 @@ static void MempoolEviction(benchmark::State& state)
44
46
tx3.vin .resize (1 );
45
47
tx3.vin [0 ].prevout = COutPoint (tx2.GetHash (), 0 );
46
48
tx3.vin [0 ].scriptSig = CScript () << OP_2;
49
+ tx3.vin [0 ].scriptWitness .stack .push_back ({3 });
47
50
tx3.vout .resize (1 );
48
51
tx3.vout [0 ].scriptPubKey = CScript () << OP_3 << OP_EQUAL;
49
52
tx3.vout [0 ].nValue = 10 * COIN;
@@ -52,8 +55,10 @@ static void MempoolEviction(benchmark::State& state)
52
55
tx4.vin .resize (2 );
53
56
tx4.vin [0 ].prevout .SetNull ();
54
57
tx4.vin [0 ].scriptSig = CScript () << OP_4;
58
+ tx4.vin [0 ].scriptWitness .stack .push_back ({4 });
55
59
tx4.vin [1 ].prevout .SetNull ();
56
60
tx4.vin [1 ].scriptSig = CScript () << OP_4;
61
+ tx4.vin [1 ].scriptWitness .stack .push_back ({4 });
57
62
tx4.vout .resize (2 );
58
63
tx4.vout [0 ].scriptPubKey = CScript () << OP_4 << OP_EQUAL;
59
64
tx4.vout [0 ].nValue = 10 * COIN;
@@ -64,8 +69,10 @@ static void MempoolEviction(benchmark::State& state)
64
69
tx5.vin .resize (2 );
65
70
tx5.vin [0 ].prevout = COutPoint (tx4.GetHash (), 0 );
66
71
tx5.vin [0 ].scriptSig = CScript () << OP_4;
72
+ tx5.vin [0 ].scriptWitness .stack .push_back ({4 });
67
73
tx5.vin [1 ].prevout .SetNull ();
68
74
tx5.vin [1 ].scriptSig = CScript () << OP_5;
75
+ tx5.vin [1 ].scriptWitness .stack .push_back ({5 });
69
76
tx5.vout .resize (2 );
70
77
tx5.vout [0 ].scriptPubKey = CScript () << OP_5 << OP_EQUAL;
71
78
tx5.vout [0 ].nValue = 10 * COIN;
@@ -76,8 +83,10 @@ static void MempoolEviction(benchmark::State& state)
76
83
tx6.vin .resize (2 );
77
84
tx6.vin [0 ].prevout = COutPoint (tx4.GetHash (), 1 );
78
85
tx6.vin [0 ].scriptSig = CScript () << OP_4;
86
+ tx6.vin [0 ].scriptWitness .stack .push_back ({4 });
79
87
tx6.vin [1 ].prevout .SetNull ();
80
88
tx6.vin [1 ].scriptSig = CScript () << OP_6;
89
+ tx6.vin [1 ].scriptWitness .stack .push_back ({6 });
81
90
tx6.vout .resize (2 );
82
91
tx6.vout [0 ].scriptPubKey = CScript () << OP_6 << OP_EQUAL;
83
92
tx6.vout [0 ].nValue = 10 * COIN;
@@ -88,8 +97,10 @@ static void MempoolEviction(benchmark::State& state)
88
97
tx7.vin .resize (2 );
89
98
tx7.vin [0 ].prevout = COutPoint (tx5.GetHash (), 0 );
90
99
tx7.vin [0 ].scriptSig = CScript () << OP_5;
100
+ tx7.vin [0 ].scriptWitness .stack .push_back ({5 });
91
101
tx7.vin [1 ].prevout = COutPoint (tx6.GetHash (), 0 );
92
102
tx7.vin [1 ].scriptSig = CScript () << OP_6;
103
+ tx7.vin [1 ].scriptWitness .stack .push_back ({6 });
93
104
tx7.vout .resize (2 );
94
105
tx7.vout [0 ].scriptPubKey = CScript () << OP_7 << OP_EQUAL;
95
106
tx7.vout [0 ].nValue = 10 * COIN;
0 commit comments