mirror of
https://github.com/simdjson/simdjson
synced 2026-06-08 17:27:07 +00:00
Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 61c8cfa07d | |||
| 6c8fa7c1bc | |||
| 1f73998f67 | |||
| bac174aece | |||
| a7fbb17ac1 |
@@ -0,0 +1,29 @@
|
|||||||
|
name: VS15-CI
|
||||||
|
|
||||||
|
on: [push, pull_request]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
ci:
|
||||||
|
if: >-
|
||||||
|
! contains(toJSON(github.event.commits.*.message), '[skip ci]') &&
|
||||||
|
! contains(toJSON(github.event.commits.*.message), '[skip github]')
|
||||||
|
name: windows-vs15
|
||||||
|
runs-on: windows-2016
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
- {gen: Visual Studio 15 2017, arch: Win32}
|
||||||
|
- {gen: Visual Studio 15 2017, arch: x64}
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Configure
|
||||||
|
run: |
|
||||||
|
mkdir build
|
||||||
|
cd build && cmake -DSIMDJSON_COMPETITION=OFF -G "${{matrix.gen}}" -A ${{matrix.arch}} ..
|
||||||
|
- name: Build
|
||||||
|
run: cmake --build build --config Release --parallel
|
||||||
|
- name: 'Run CTest'
|
||||||
|
run: |
|
||||||
|
cd build
|
||||||
|
ctest -C Release -LE explicitonly --output-on-failure
|
||||||
+9
-3
@@ -7,8 +7,8 @@ project(simdjson
|
|||||||
|
|
||||||
set(PROJECT_VERSION_MAJOR 0)
|
set(PROJECT_VERSION_MAJOR 0)
|
||||||
set(PROJECT_VERSION_MINOR 8)
|
set(PROJECT_VERSION_MINOR 8)
|
||||||
set(PROJECT_VERSION_PATCH 0)
|
set(PROJECT_VERSION_PATCH 2)
|
||||||
set(SIMDJSON_SEMANTIC_VERSION "0.8.0" CACHE STRING "simdjson semantic version")
|
set(SIMDJSON_SEMANTIC_VERSION "0.8.2" CACHE STRING "simdjson semantic version")
|
||||||
set(SIMDJSON_LIB_VERSION "7.0.0" CACHE STRING "simdjson library version")
|
set(SIMDJSON_LIB_VERSION "7.0.0" CACHE STRING "simdjson library version")
|
||||||
set(SIMDJSON_LIB_SOVERSION "7" CACHE STRING "simdjson library soversion")
|
set(SIMDJSON_LIB_SOVERSION "7" CACHE STRING "simdjson library soversion")
|
||||||
set(SIMDJSON_GITHUB_REPOSITORY https://github.com/simdjson/simdjson)
|
set(SIMDJSON_GITHUB_REPOSITORY https://github.com/simdjson/simdjson)
|
||||||
@@ -50,7 +50,13 @@ configure_package_config_file("${PROJECT_SOURCE_DIR}/cmake/simdjson-config.cmake
|
|||||||
INSTALL_DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/simdjson"
|
INSTALL_DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/simdjson"
|
||||||
NO_SET_AND_CHECK_MACRO
|
NO_SET_AND_CHECK_MACRO
|
||||||
NO_CHECK_REQUIRED_COMPONENTS_MACRO)
|
NO_CHECK_REQUIRED_COMPONENTS_MACRO)
|
||||||
|
write_basic_package_version_file(
|
||||||
|
"${PROJECT_BINARY_DIR}/simdjson-config-version.cmake"
|
||||||
|
VERSION ${SIMDJSON_SEMANTIC_VERSION}
|
||||||
|
COMPATIBILITY SameMinorVersion)
|
||||||
|
install(FILES "${PROJECT_BINARY_DIR}/simdjson-config.cmake"
|
||||||
|
"${PROJECT_BINARY_DIR}/simdjson-config-version.cmake"
|
||||||
|
DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/simdjson")
|
||||||
#
|
#
|
||||||
# Compile tools / tests / benchmarks
|
# Compile tools / tests / benchmarks
|
||||||
#
|
#
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ PROJECT_NAME = simdjson
|
|||||||
# could be handy for archiving the generated documentation or if some version
|
# could be handy for archiving the generated documentation or if some version
|
||||||
# control system is used.
|
# control system is used.
|
||||||
|
|
||||||
PROJECT_NUMBER = "0.8.0"
|
PROJECT_NUMBER = "0.8.2"
|
||||||
|
|
||||||
# Using the PROJECT_BRIEF tag one can provide an optional one line description
|
# Using the PROJECT_BRIEF tag one can provide an optional one line description
|
||||||
# for a project that appears at the top of each page and should give viewer a
|
# for a project that appears at the top of each page and should give viewer a
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
# Clone the repository if it's not there
|
# Clone the repository if it's not there
|
||||||
find_package(Git QUIET)
|
find_package(Git QUIET)
|
||||||
if (Git_FOUND AND (GIT_VERSION_STRING VERSION_GREATER "2.1.4") AND (NOT CMAKE_GENERATOR MATCHES Ninja) ) # We use "-C" which requires a recent git
|
if (Git_FOUND AND (GIT_VERSION_STRING VERSION_GREATER "2.1.4") AND (NOT CMAKE_GENERATOR MATCHES Ninja) AND (NOT MSVC) ) # We use "-C" which requires a recent git
|
||||||
message(STATUS "Git is available and it is recent. We are enabling checkperf targets.")
|
message(STATUS "Git is available and it is recent. We are enabling checkperf targets.")
|
||||||
# sync_git_repository(myrepo ...) creates two targets:
|
# sync_git_repository(myrepo ...) creates two targets:
|
||||||
# myrepo - if the repo does not exist, creates and syncs it against the origin branch
|
# myrepo - if the repo does not exist, creates and syncs it against the origin branch
|
||||||
|
|||||||
@@ -1,4 +1,8 @@
|
|||||||
|
if(NOT MSVC)
|
||||||
option(ENABLE_FUZZING "enable building the fuzzers" ON)
|
option(ENABLE_FUZZING "enable building the fuzzers" ON)
|
||||||
|
else()
|
||||||
|
option(ENABLE_FUZZING "enable building the fuzzers" OFF)
|
||||||
|
endif()
|
||||||
|
|
||||||
if(ENABLE_FUZZING)
|
if(ENABLE_FUZZING)
|
||||||
|
|
||||||
|
|||||||
@@ -173,6 +173,7 @@ constexpr size_t DEFAULT_MAX_DEPTH = 1024;
|
|||||||
// even if we do not have C++17 support.
|
// even if we do not have C++17 support.
|
||||||
#ifdef __cpp_lib_string_view
|
#ifdef __cpp_lib_string_view
|
||||||
#define SIMDJSON_HAS_STRING_VIEW
|
#define SIMDJSON_HAS_STRING_VIEW
|
||||||
|
#include <string_view> // by the standard, this has to be safe.
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Some systems have string_view even if we do not have C++17 support,
|
// Some systems have string_view even if we do not have C++17 support,
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
#define SIMDJSON_SIMDJSON_VERSION_H
|
#define SIMDJSON_SIMDJSON_VERSION_H
|
||||||
|
|
||||||
/** The version of simdjson being used (major.minor.revision) */
|
/** The version of simdjson being used (major.minor.revision) */
|
||||||
#define SIMDJSON_VERSION 0.8.0
|
#define SIMDJSON_VERSION 0.8.2
|
||||||
|
|
||||||
namespace simdjson {
|
namespace simdjson {
|
||||||
enum {
|
enum {
|
||||||
@@ -19,7 +19,7 @@ enum {
|
|||||||
/**
|
/**
|
||||||
* The revision (major.minor.REVISION) of simdjson being used.
|
* The revision (major.minor.REVISION) of simdjson being used.
|
||||||
*/
|
*/
|
||||||
SIMDJSON_VERSION_REVISION = 0
|
SIMDJSON_VERSION_REVISION = 2
|
||||||
};
|
};
|
||||||
} // namespace simdjson
|
} // namespace simdjson
|
||||||
|
|
||||||
|
|||||||
@@ -120,15 +120,18 @@ include(${PROJECT_SOURCE_DIR}/cmake/add_compile_only_test.cmake)
|
|||||||
#
|
#
|
||||||
# Test the generated simdjson.cpp/simdjson.h using the generated amalgamate_demo.cpp
|
# Test the generated simdjson.cpp/simdjson.h using the generated amalgamate_demo.cpp
|
||||||
#
|
#
|
||||||
|
if(NOT MSVC)
|
||||||
add_executable(amalgamate_demo $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/amalgamate_demo.cpp>)
|
add_executable(amalgamate_demo $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/amalgamate_demo.cpp>)
|
||||||
target_link_libraries(amalgamate_demo simdjson-singleheader-include-source simdjson-internal-flags)
|
target_link_libraries(amalgamate_demo simdjson-singleheader-include-source simdjson-internal-flags)
|
||||||
add_test(amalgamate_demo amalgamate_demo ${EXAMPLE_JSON} ${EXAMPLE_NDJSON})
|
add_test(amalgamate_demo amalgamate_demo ${EXAMPLE_JSON} ${EXAMPLE_NDJSON})
|
||||||
|
endif()
|
||||||
|
|
||||||
install(FILES simdjson.h DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
|
install(FILES simdjson.h DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
|
||||||
|
if(NOT MSVC)
|
||||||
add_library(simdjson-singleheader STATIC "")
|
add_library(simdjson-singleheader STATIC "")
|
||||||
target_link_libraries(simdjson-singleheader simdjson-singleheader-source simdjson-internal-flags)
|
target_link_libraries(simdjson-singleheader simdjson-singleheader-source simdjson-internal-flags)
|
||||||
add_compile_only_test(simdjson-singleheader)
|
add_compile_only_test(simdjson-singleheader)
|
||||||
|
endif()
|
||||||
|
|
||||||
#
|
#
|
||||||
# Test the existing simdjson.cpp/simdjson.h using the existing amalgamate_demo.cpp, using
|
# Test the existing simdjson.cpp/simdjson.h using the existing amalgamate_demo.cpp, using
|
||||||
@@ -144,9 +147,9 @@ if (NOT (${CMAKE_CURRENT_SOURCE_DIR} STREQUAL ${CMAKE_CURRENT_BINARY_DIR}))
|
|||||||
add_library(simdjson-singleheader-source-direct-from-repository INTERFACE)
|
add_library(simdjson-singleheader-source-direct-from-repository INTERFACE)
|
||||||
target_sources(simdjson-singleheader-source-direct-from-repository INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
|
target_sources(simdjson-singleheader-source-direct-from-repository INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
|
||||||
target_link_libraries(simdjson-singleheader-source-direct-from-repository INTERFACE simdjson-singleheader-include-source-direct-from-repository)
|
target_link_libraries(simdjson-singleheader-source-direct-from-repository INTERFACE simdjson-singleheader-include-source-direct-from-repository)
|
||||||
|
if(NOT MSVC)
|
||||||
add_executable(amalgamate_demo_direct_from_repository ${CMAKE_CURRENT_SOURCE_DIR}/amalgamate_demo.cpp)
|
add_executable(amalgamate_demo_direct_from_repository ${CMAKE_CURRENT_SOURCE_DIR}/amalgamate_demo.cpp)
|
||||||
target_link_libraries(amalgamate_demo_direct_from_repository simdjson-singleheader-include-source-direct-from-repository simdjson-internal-flags)
|
target_link_libraries(amalgamate_demo_direct_from_repository simdjson-singleheader-include-source-direct-from-repository simdjson-internal-flags)
|
||||||
add_test(amalgamate_demo_direct_from_repository amalgamate_demo_direct_from_repository ${EXAMPLE_JSON} ${EXAMPLE_NDJSON})
|
add_test(amalgamate_demo_direct_from_repository amalgamate_demo_direct_from_repository ${EXAMPLE_JSON} ${EXAMPLE_NDJSON})
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
/* auto-generated on 2021-01-20 13:20:49 -0500. Do not edit! */
|
/* auto-generated on 2021-01-28 09:47:45 -0500. Do not edit! */
|
||||||
/* begin file src/simdjson.cpp */
|
/* begin file src/simdjson.cpp */
|
||||||
#include "simdjson.h"
|
#include "simdjson.h"
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
/* auto-generated on 2021-01-20 13:20:49 -0500. Do not edit! */
|
/* auto-generated on 2021-01-28 09:47:45 -0500. Do not edit! */
|
||||||
/* begin file include/simdjson.h */
|
/* begin file include/simdjson.h */
|
||||||
#ifndef SIMDJSON_H
|
#ifndef SIMDJSON_H
|
||||||
#define SIMDJSON_H
|
#define SIMDJSON_H
|
||||||
@@ -429,6 +429,7 @@ constexpr size_t DEFAULT_MAX_DEPTH = 1024;
|
|||||||
// even if we do not have C++17 support.
|
// even if we do not have C++17 support.
|
||||||
#ifdef __cpp_lib_string_view
|
#ifdef __cpp_lib_string_view
|
||||||
#define SIMDJSON_HAS_STRING_VIEW
|
#define SIMDJSON_HAS_STRING_VIEW
|
||||||
|
#include <string_view> // by the standard, this has to be safe.
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Some systems have string_view even if we do not have C++17 support,
|
// Some systems have string_view even if we do not have C++17 support,
|
||||||
@@ -2017,7 +2018,7 @@ SIMDJSON_DISABLE_UNDESIRED_WARNINGS
|
|||||||
#define SIMDJSON_SIMDJSON_VERSION_H
|
#define SIMDJSON_SIMDJSON_VERSION_H
|
||||||
|
|
||||||
/** The version of simdjson being used (major.minor.revision) */
|
/** The version of simdjson being used (major.minor.revision) */
|
||||||
#define SIMDJSON_VERSION 0.8.0
|
#define SIMDJSON_VERSION 0.8.2
|
||||||
|
|
||||||
namespace simdjson {
|
namespace simdjson {
|
||||||
enum {
|
enum {
|
||||||
@@ -2032,7 +2033,7 @@ enum {
|
|||||||
/**
|
/**
|
||||||
* The revision (major.minor.REVISION) of simdjson being used.
|
* The revision (major.minor.REVISION) of simdjson being used.
|
||||||
*/
|
*/
|
||||||
SIMDJSON_VERSION_REVISION = 0
|
SIMDJSON_VERSION_REVISION = 2
|
||||||
};
|
};
|
||||||
} // namespace simdjson
|
} // namespace simdjson
|
||||||
|
|
||||||
|
|||||||
@@ -10,16 +10,20 @@ add_subdirectory(ondemand)
|
|||||||
#
|
#
|
||||||
# These tests explicitly do #include "simdjson.cpp" so they can override stuff
|
# These tests explicitly do #include "simdjson.cpp" so they can override stuff
|
||||||
#
|
#
|
||||||
|
if(NOT MSVC)
|
||||||
add_cpp_test(numberparsingcheck LABELS acceptance per_implementation)
|
add_cpp_test(numberparsingcheck LABELS acceptance per_implementation)
|
||||||
target_link_libraries(numberparsingcheck simdjson-include-source simdjson-windows-headers)
|
target_link_libraries(numberparsingcheck simdjson-include-source simdjson-windows-headers)
|
||||||
target_compile_definitions(numberparsingcheck PRIVATE NOMINMAX)
|
target_compile_definitions(numberparsingcheck PRIVATE NOMINMAX)
|
||||||
add_cpp_test(stringparsingcheck LABELS acceptance per_implementation)
|
add_cpp_test(stringparsingcheck LABELS acceptance per_implementation)
|
||||||
target_link_libraries(stringparsingcheck simdjson-include-source simdjson-windows-headers)
|
target_link_libraries(stringparsingcheck simdjson-include-source simdjson-windows-headers)
|
||||||
target_compile_definitions(stringparsingcheck PRIVATE NOMINMAX)
|
target_compile_definitions(stringparsingcheck PRIVATE NOMINMAX)
|
||||||
|
endif()
|
||||||
|
|
||||||
# All remaining tests link with simdjson proper
|
# All remaining tests link with simdjson proper
|
||||||
link_libraries(simdjson)
|
link_libraries(simdjson)
|
||||||
|
if(NOT MSVC)
|
||||||
add_cpp_test(random_string_number_tests LABELS dom acceptance per_implementation)
|
add_cpp_test(random_string_number_tests LABELS dom acceptance per_implementation)
|
||||||
|
endif()
|
||||||
add_cpp_test(basictests LABELS dom acceptance per_implementation)
|
add_cpp_test(basictests LABELS dom acceptance per_implementation)
|
||||||
add_cpp_test(document_stream_tests LABELS dom acceptance per_implementation)
|
add_cpp_test(document_stream_tests LABELS dom acceptance per_implementation)
|
||||||
add_cpp_test(document_tests LABELS dom acceptance per_implementation)
|
add_cpp_test(document_tests LABELS dom acceptance per_implementation)
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
#include <string>
|
#include <string>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
#include <cctype>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
#include "simdjson.h"
|
#include "simdjson.h"
|
||||||
|
|||||||
Reference in New Issue
Block a user