File tree 11 files changed +18
-51
lines changed
11 files changed +18
-51
lines changed Original file line number Diff line number Diff line change @@ -7,10 +7,6 @@ SIMDJSON_PUSH_DISABLE_ALL_WARNINGS
7
7
#include < benchmark/benchmark.h>
8
8
SIMDJSON_POP_DISABLE_WARNINGS
9
9
10
- #if SIMDJSON_IMPLEMENTATION_HASWELL
11
- #include " simdjson/haswell/begin.h"
12
- #endif // SIMDJSON_IMPLEMENTATION_HASWELL
13
-
14
10
#include " partial_tweets/ondemand.h"
15
11
#include " partial_tweets/iter.h"
16
12
#include " partial_tweets/dom.h"
@@ -24,7 +20,3 @@ SIMDJSON_POP_DISABLE_WARNINGS
24
20
#include " kostya/dom.h"
25
21
26
22
BENCHMARK_MAIN ();
27
-
28
- #if SIMDJSON_IMPLEMENTATION_HASWELL
29
- #include " simdjson/haswell/end.h"
30
- #endif // SIMDJSON_IMPLEMENTATION_HASWELL
Original file line number Diff line number Diff line change @@ -8,16 +8,7 @@ SIMDJSON_PUSH_DISABLE_ALL_WARNINGS
8
8
#include < benchmark/benchmark.h>
9
9
SIMDJSON_POP_DISABLE_WARNINGS
10
10
11
-
12
- #if SIMDJSON_IMPLEMENTATION_HASWELL
13
- #include " simdjson/haswell/begin.h"
14
- #endif // SIMDJSON_IMPLEMENTATION_HASWELL
15
-
16
11
#include " partial_tweets/sax.h"
17
12
#include " largerandom/sax.h"
18
13
19
14
BENCHMARK_MAIN ();
20
-
21
- #if SIMDJSON_IMPLEMENTATION_HASWELL
22
- #include " simdjson/haswell/end.h"
23
- #endif // SIMDJSON_IMPLEMENTATION_HASWELL
Original file line number Diff line number Diff line change 1
1
#pragma once
2
2
3
- #ifdef SIMDJSON_IMPLEMENTATION
4
3
#if SIMDJSON_EXCEPTIONS
5
4
6
5
#include " kostya.h"
7
6
8
7
namespace kostya {
9
8
10
9
using namespace simdjson ;
11
- using namespace simdjson ::SIMDJSON_IMPLEMENTATION ;
10
+ using namespace simdjson ::builtin ;
12
11
13
12
class Iter {
14
13
public:
@@ -21,12 +20,12 @@ class Iter {
21
20
ondemand::parser parser{};
22
21
std::vector<my_point> container{};
23
22
24
- simdjson_really_inline simdjson_result<double > first_double (SIMDJSON_IMPLEMENTATION:: ondemand::json_iterator &iter, const char *key) {
23
+ simdjson_really_inline simdjson_result<double > first_double (ondemand::json_iterator &iter, const char *key) {
25
24
if (!iter.start_object () || ondemand::raw_json_string (iter.field_key ()) != key || iter.field_value ()) { throw " Invalid field" ; }
26
25
return iter.get_double ();
27
26
}
28
27
29
- simdjson_really_inline simdjson_result<double > next_double (SIMDJSON_IMPLEMENTATION:: ondemand::json_iterator &iter, const char *key) {
28
+ simdjson_really_inline simdjson_result<double > next_double (ondemand::json_iterator &iter, const char *key) {
30
29
if (!iter.has_next_field () || ondemand::raw_json_string (iter.field_key ()) != key || iter.field_value ()) { throw " Invalid field" ; }
31
30
return iter.get_double ();
32
31
}
@@ -95,4 +94,3 @@ BENCHMARK_TEMPLATE(KostyaSum, Iter);
95
94
} // namespace kostya
96
95
97
96
#endif // SIMDJSON_EXCEPTIONS
98
- #endif // SIMDJSON_IMPLEMENTATION
Original file line number Diff line number Diff line change 1
1
#pragma once
2
2
3
- #ifdef SIMDJSON_IMPLEMENTATION
4
3
#if SIMDJSON_EXCEPTIONS
5
4
6
5
#include " kostya.h"
7
6
8
7
namespace kostya {
9
8
10
9
using namespace simdjson ;
11
- using namespace simdjson ::SIMDJSON_IMPLEMENTATION ;
10
+ using namespace simdjson ::builtin ;
12
11
13
12
class OnDemand {
14
13
public:
@@ -75,4 +74,3 @@ BENCHMARK_TEMPLATE(KostyaSum, OnDemand);
75
74
} // namespace kostya
76
75
77
76
#endif // SIMDJSON_EXCEPTIONS
78
- #endif // SIMDJSON_IMPLEMENTATION
Original file line number Diff line number Diff line change 1
1
#pragma once
2
2
3
- #ifdef SIMDJSON_IMPLEMENTATION
4
3
#if SIMDJSON_EXCEPTIONS
5
4
6
5
#include " largerandom.h"
7
6
8
7
namespace largerandom {
9
8
10
9
using namespace simdjson ;
11
- using namespace simdjson ::SIMDJSON_IMPLEMENTATION ;
10
+ using namespace simdjson ::builtin ;
12
11
13
12
class Iter {
14
13
public:
@@ -21,12 +20,12 @@ class Iter {
21
20
ondemand::parser parser{};
22
21
std::vector<my_point> container{};
23
22
24
- simdjson_really_inline double first_double (SIMDJSON_IMPLEMENTATION:: ondemand::json_iterator &iter) {
23
+ simdjson_really_inline double first_double (ondemand::json_iterator &iter) {
25
24
if (iter.start_object ().error () || iter.field_key ().error () || iter.field_value ()) { throw " Invalid field" ; }
26
25
return iter.get_double ();
27
26
}
28
27
29
- simdjson_really_inline double next_double (SIMDJSON_IMPLEMENTATION:: ondemand::json_iterator &iter) {
28
+ simdjson_really_inline double next_double (ondemand::json_iterator &iter) {
30
29
if (!iter.has_next_field () || iter.field_key ().error () || iter.field_value ()) { throw " Invalid field" ; }
31
30
return iter.get_double ();
32
31
}
@@ -91,4 +90,3 @@ BENCHMARK_TEMPLATE(LargeRandomSum, Iter);
91
90
} // namespace largerandom
92
91
93
92
#endif // SIMDJSON_EXCEPTIONS
94
- #endif // SIMDJSON_IMPLEMENTATION
Original file line number Diff line number Diff line change 1
1
#pragma once
2
2
3
- #ifdef SIMDJSON_IMPLEMENTATION
4
3
#if SIMDJSON_EXCEPTIONS
5
4
6
5
#include " largerandom.h"
7
6
8
7
namespace largerandom {
9
8
10
9
using namespace simdjson ;
11
- using namespace simdjson ::SIMDJSON_IMPLEMENTATION ;
10
+ using namespace simdjson ::builtin ;
12
11
13
12
class OnDemand {
14
13
public:
@@ -72,4 +71,3 @@ BENCHMARK_TEMPLATE(LargeRandomSum, OnDemand);
72
71
} // namespace largerandom
73
72
74
73
#endif // SIMDJSON_EXCEPTIONS
75
- #endif // SIMDJSON_IMPLEMENTATION
Original file line number Diff line number Diff line change 1
1
#pragma once
2
2
3
- #ifdef SIMDJSON_IMPLEMENTATION
4
3
#if SIMDJSON_EXCEPTIONS
5
4
6
5
#include " largerandom.h"
7
6
8
7
namespace largerandom {
9
8
10
9
using namespace simdjson ;
11
- using namespace SIMDJSON_IMPLEMENTATION ;
12
- using namespace SIMDJSON_IMPLEMENTATION ::stage2;
10
+ using namespace simdjson ::builtin ;
11
+ using namespace simdjson ::builtin ::stage2;
13
12
14
13
class Sax {
15
14
public:
@@ -28,8 +27,8 @@ class Sax {
28
27
};
29
28
30
29
using namespace simdjson ;
31
- using namespace SIMDJSON_IMPLEMENTATION ;
32
- using namespace SIMDJSON_IMPLEMENTATION ::stage2;
30
+ using namespace simdjson ::builtin ;
31
+ using namespace simdjson ::builtin ::stage2;
33
32
struct sax_point_reader_visitor {
34
33
public:
35
34
std::vector<my_point> &points;
@@ -123,4 +122,3 @@ BENCHMARK_TEMPLATE(LargeRandom, Sax);
123
122
} // namespace largerandom
124
123
125
124
#endif // SIMDJSON_EXCEPTIONS
126
- #endif // SIMDJSON_IMPLEMENTATION
Original file line number Diff line number Diff line change 1
1
#pragma once
2
2
3
- #ifdef SIMDJSON_IMPLEMENTATION
4
3
#if SIMDJSON_EXCEPTIONS
5
4
6
5
#include " partial_tweets.h"
7
6
8
7
namespace partial_tweets {
9
8
10
9
using namespace simdjson ;
11
- using namespace simdjson ::SIMDJSON_IMPLEMENTATION ;
10
+ using namespace simdjson ::builtin ;
12
11
13
12
class Iter {
14
13
public:
@@ -92,4 +91,3 @@ BENCHMARK_TEMPLATE(PartialTweets, Iter);
92
91
} // namespace partial_tweets
93
92
94
93
#endif // SIMDJSON_EXCEPTIONS
95
- #endif // SIMDJSON_IMPLEMENTATION
Original file line number Diff line number Diff line change 1
1
#pragma once
2
2
3
- #ifdef SIMDJSON_IMPLEMENTATION
4
3
#if SIMDJSON_EXCEPTIONS
5
4
6
5
#include " partial_tweets.h"
7
6
8
7
namespace partial_tweets {
9
8
10
9
using namespace simdjson ;
11
- using namespace simdjson ::SIMDJSON_IMPLEMENTATION ;
10
+ using namespace simdjson ::builtin ;
12
11
13
12
class OnDemand {
14
13
public:
@@ -57,4 +56,3 @@ BENCHMARK_TEMPLATE(PartialTweets, OnDemand);
57
56
} // namespace partial_tweets
58
57
59
58
#endif // SIMDJSON_EXCEPTIONS
60
- #endif // SIMDJSON_IMPLEMENTATION
Original file line number Diff line number Diff line change 1
1
#pragma once
2
2
3
- #ifdef SIMDJSON_IMPLEMENTATION
4
3
5
4
#include " partial_tweets.h"
6
5
#include " sax_tweet_reader_visitor.h"
7
6
8
7
namespace partial_tweets {
9
8
10
9
using namespace simdjson ;
11
- using namespace SIMDJSON_IMPLEMENTATION ;
12
- using namespace SIMDJSON_IMPLEMENTATION ::stage2;
10
+ using namespace simdjson ::builtin ;
11
+ using namespace simdjson ::builtin ::stage2;
13
12
14
13
class Sax {
15
14
public:
@@ -68,4 +67,3 @@ BENCHMARK_TEMPLATE(PartialTweets, Sax);
68
67
69
68
} // namespace partial_tweets
70
69
71
- #endif // SIMDJSON_IMPLEMENTATION
Original file line number Diff line number Diff line change 7
7
namespace partial_tweets {
8
8
9
9
using namespace simdjson ;
10
- using namespace SIMDJSON_IMPLEMENTATION ;
11
- using namespace SIMDJSON_IMPLEMENTATION ::stage2;
10
+ using namespace simdjson ::builtin ;
11
+ using namespace simdjson ::builtin ::stage2;
12
12
13
13
struct sax_tweet_reader_visitor {
14
14
public:
You can’t perform that action at this time.
0 commit comments