{"id":19151966,"url":"https://github.com/roaringbitmap/roaringcli","last_synced_at":"2025-05-07T05:42:32.211Z","repository":{"id":66359522,"uuid":"100542088","full_name":"RoaringBitmap/RoaringCLI","owner":"RoaringBitmap","description":"A CLI (.NET) wrapper around Roaring64Map that exposes the existing native C++ interfaces for .NET callers","archived":false,"fork":false,"pushed_at":"2017-08-22T09:29:02.000Z","size":271,"stargazers_count":4,"open_issues_count":0,"forks_count":2,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-04-19T19:05:07.964Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/RoaringBitmap.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":"AUTHORS","dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2017-08-16T23:46:16.000Z","updated_at":"2023-12-17T16:40:13.000Z","dependencies_parsed_at":"2023-02-22T03:45:13.089Z","dependency_job_id":null,"html_url":"https://github.com/RoaringBitmap/RoaringCLI","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RoaringBitmap%2FRoaringCLI","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RoaringBitmap%2FRoaringCLI/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RoaringBitmap%2FRoaringCLI/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RoaringBitmap%2FRoaringCLI/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RoaringBitmap","download_url":"https://codeload.github.com/RoaringBitmap/RoaringCLI/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252823671,"owners_count":21809707,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-09T08:16:11.338Z","updated_at":"2025-05-07T05:42:32.187Z","avatar_url":"https://github.com/RoaringBitmap.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CRoaring [![Build Status](https://travis-ci.org/RoaringBitmap/CRoaring.png)](https://travis-ci.org/RoaringBitmap/CRoaring)\nRoaring bitmaps in C (and C++)\n\n# Introduction\n\nBitsets, also called bitmaps, are commonly used as fast data structures. Unfortunately, they can use too much memory.\n To compensate, we often use compressed bitmaps.\n\nRoaring bitmaps are compressed bitmaps which tend to outperform conventional compressed bitmaps such as WAH, EWAH or Concise.\nThey are used by several major systems such as [Apache Lucene][lucene] and derivative systems such as [Solr][solr] and\n[Elasticsearch][elasticsearch], [Metamarkets' Druid][druid], [LinkedIn Pinot][pinot], [Netflix Atlas][atlas],  [Apache Spark][spark], [OpenSearchServer][opensearchserver], [Cloud Torrent][cloudtorrent], [Whoosh][whoosh],  [Pilosa][pilosa],  [Microsoft Visual Studio Team Services (VSTS)][vsts], and eBay's [Apache Kylin][kylin].\n\n[lucene]: https://lucene.apache.org/\n[solr]: https://lucene.apache.org/solr/\n[elasticsearch]: https://www.elastic.co/products/elasticsearch\n[druid]: http://druid.io/\n[spark]: https://spark.apache.org/\n[opensearchserver]: http://www.opensearchserver.com\n[cloudtorrent]: https://github.com/jpillora/cloud-torrent\n[whoosh]: https://bitbucket.org/mchaput/whoosh/wiki/Home\n[pilosa]: https://www.pilosa.com/\n[kylin]: http://kylin.apache.org/\n[pinot]: http://github.com/linkedin/pinot/wiki\n[vsts]: https://www.visualstudio.com/team-services/\n[atlas]: https://github.com/Netflix/atlas\n\nRoaring bitmaps are found to work well in many important applications:\n\n\u003e Use Roaring for bitmap compression whenever possible. Do not use other bitmap compression methods ([Wang et al., SIGMOD 2017](http://db.ucsd.edu/wp-content/uploads/2017/03/sidm338-wangA.pdf))\n\n\nThere is a serialized format specification for interoperability between implementations: https://github.com/RoaringBitmap/RoaringFormatSpec/\n\n# Objective\n\nThe primary goal of the CRoaring is to provide a high performance low-level implementation that fully take advantage\nof the latest hardware. Roaring bitmaps are already available on a variety of platform through Java, Go, Rust... implementations. CRoaring is a library that seeks to achieve superior performance by staying close to the latest hardware.\n\n\n(c) 2016-2017 The CRoaring authors.\n\n\n\n# Requirements\n\n- The library should build on a  Linux-like operating system (including MacOS).\n- We also support Microsoft Visual studio.\n- Though most reasonable processors should be supported, we expect a recent Intel processor: Haswell (2013) or better but support all x64/x86 processors. The library builds without problem on ARM processors.\n- Recent C compiler supporting the C11 standard (GCC 4.8 or better or clang), there is also an optional C++ class that requires a C++ compiler supporting the C++11 standard.\n- CMake (to contribute to the project, users can rely on amalgamation/unity builds).\n- clang-format (optional).\n\nSerialization on big endian hardware may not be compatible with serialization on little endian hardware.\n\n# Amalgamation/Unity Build\n\nThe CRoaring library can be amalgamated into a single source file that makes it easier\nfor integration into other projects. Moreover, by making it possible to compile\nall the critical code into one compilation unit, it can improve the performance. For\nthe rationale, please see the SQLite documentation, https://www.sqlite.org/amalgamation.html,\nor the corresponding Wikipedia entry (https://en.wikipedia.org/wiki/Single_Compilation_Unit).\nUsers who choose this route, do not need to rely on CRoaring's build system (based on CMake).\n\nWe maintain pre-generated amalgamated files at https://github.com/lemire/CRoaringUnityBuild for your convenience.\n\nTo generate the amalgamated files yourself, you can invoke a bash script...\n\n```bash\n./amalgamation.sh\n```\n\n(Bash shells are standard under Linux and macOS. Bash shells are available under Windows as part of the  [GitHub Desktop](https://desktop.github.com/) under the name ``Git Shell``. So if you have cloned the ``CRoaring`` GitHub repository from within the GitHub Desktop, you can right-click on ``CRoaring``, select ``Git Shell`` and then enter the above commands.)\n\nIt is not necessary to invoke the script in the CRoaring directory. You can invoke\nit from any directory where you want the amalgamation files to be written.\n\nIt will generate three files for C users: ``roaring.h``, ``roaring.c`` and ``amalgamation_demo.c``... as well as some brief instructions. The ``amalgamation_demo.c`` file is a short example, whereas ``roaring.h`` and ``roaring.c`` are \"amalgamated\" files (including all source and header files for the project). This means that you can simply copy the files ``roaring.h`` and ``roaring.c`` into your project and be ready to go! No need to produce a library! See the ``amalgamation_demo.c`` file.\n\nFor example, you can use the C code as follows:\n```\n#include \u003cstdio.h\u003e\n#include \"roaring.c\"\nint main() {\n  roaring_bitmap_t *r1 = roaring_bitmap_create();\n  for (uint32_t i = 100; i \u003c 1000; i++) roaring_bitmap_add(r1, i);\n  printf(\"cardinality = %d\\n\", (int) roaring_bitmap_get_cardinality(r1));\n  roaring_bitmap_free(r1);\n  return 0;\n}\n```\n\nThe script will also generate C++ files for C++ users, including an example. You can use the C++ as follows.\n\n```\n#include \u003ciostream\u003e\n#include \"roaring.hh\"\n#include \"roaring.c\"\nint main() {\n  Roaring r1;\n  for (uint32_t i = 100; i \u003c 1000; i++) {\n    r1.add(i);\n  }\n  std::cout \u003c\u003c \"cardinality = \" \u003c\u003c r1.cardinality() \u003c\u003c std::endl;\n\n  Roaring64Map r2;\n  for (uint64_t i = 18000000000000000100ull; i \u003c 18000000000000001000ull; i++) {\n    r2.add(i);\n  }\n  std::cout \u003c\u003c \"cardinality = \" \u003c\u003c r2.cardinality() \u003c\u003c std::endl;\n  return 0;\n}\n```\n\nIf you prefer a silent output, you can use the following command to redirect ``stdout`` :\n\n```bash\n./amalgamation.sh \u003e /dev/null\n```\n\n# API\n\nThe interface is found in the file ``include/roaring/roaring.h``.\n\n# Example (C)\n\n```c\n////\n//// #include \u003croaring/roaring.h\u003e\n////\n\n// create a new empty bitmap\nroaring_bitmap_t *r1 = roaring_bitmap_create();\n// then we can add values\nfor (uint32_t i = 100; i \u003c 1000; i++) roaring_bitmap_add(r1, i);\n// check whether a value is contained\nassert(roaring_bitmap_contains(r1, 500));\n// compute how many bits there are:\nuint32_t cardinality = roaring_bitmap_get_cardinality(r1);\nprintf(\"Cardinality = %d \\n\", cardinality);\n\n// if your bitmaps have long runs, you can compress them by calling\n// run_optimize\nuint32_t expectedsizebasic = roaring_bitmap_portable_size_in_bytes(r1);\nroaring_bitmap_run_optimize(r1);\nuint32_t expectedsizerun = roaring_bitmap_portable_size_in_bytes(r1);\nprintf(\"size before run optimize %d bytes, and after %d bytes\\n\",\n       expectedsizebasic, expectedsizerun);\n\n// create a new bitmap containing the values {1,2,3,5,6}\nroaring_bitmap_t *r2 = roaring_bitmap_of(5, 1, 2, 3, 5, 6);\nroaring_bitmap_printf(r2);  // print it\n\n// we can also create a bitmap from a pointer to 32-bit integers\nuint32_t somevalues[] = {2, 3, 4};\nroaring_bitmap_t *r3 = roaring_bitmap_of_ptr(3, somevalues);\n\n// we can also go in reverse and go from arrays to bitmaps\nuint64_t card1 = roaring_bitmap_get_cardinality(r1);\nuint32_t *arr1 = (uint32_t *) malloc(card1 * sizeof(uint32_t));\nassert(arr1  != NULL);\nroaring_bitmap_to_uint32_array(r1, arr1);\nroaring_bitmap_t *r1f = roaring_bitmap_of_ptr(card1, arr1);\nfree(arr1);\nassert(roaring_bitmap_equals(r1, r1f));  // what we recover is equal\nroaring_bitmap_free(r1f);\n\n// we can copy and compare bitmaps\nroaring_bitmap_t *z = roaring_bitmap_copy(r3);\nassert(roaring_bitmap_equals(r3, z));  // what we recover is equal\nroaring_bitmap_free(z);\n\n// we can compute union two-by-two\nroaring_bitmap_t *r1_2_3 = roaring_bitmap_or(r1, r2);\nroaring_bitmap_or_inplace(r1_2_3, r3);\n\n// we can compute a big union\nconst roaring_bitmap_t *allmybitmaps[] = {r1, r2, r3};\nroaring_bitmap_t *bigunion = roaring_bitmap_or_many(3, allmybitmaps);\nassert(\n    roaring_bitmap_equals(r1_2_3, bigunion));  // what we recover is equal\n// can also do the big union with a heap\nroaring_bitmap_t *bigunionheap = roaring_bitmap_or_many_heap(3, allmybitmaps);\nassert_true(roaring_bitmap_equals(r1_2_3, bigunionheap));\n\nroaring_bitmap_free(r1_2_3);\nroaring_bitmap_free(bigunion);\nroaring_bitmap_free(bigunionheap);\n\n// we can compute intersection two-by-two\nroaring_bitmap_t *i1_2 = roaring_bitmap_and(r1, r2);\nroaring_bitmap_free(i1_2);\n\n// we can write a bitmap to a pointer and recover it later\nuint32_t expectedsize = roaring_bitmap_portable_size_in_bytes(r1);\nchar *serializedbytes = malloc(expectedsize);\nroaring_bitmap_portable_serialize(r1, serializedbytes);\nroaring_bitmap_t *t = roaring_bitmap_portable_deserialize(serializedbytes);\nassert(roaring_bitmap_equals(r1, t));  // what we recover is equal\nroaring_bitmap_free(t);\nfree(serializedbytes);\n\n// we can iterate over all values using custom functions\nuint32_t counter = 0;\nroaring_iterate(r1, roaring_iterator_sumall, \u0026counter);\n/**\n * bool roaring_iterator_sumall(uint32_t value, void *param) {\n *        *(uint32_t *) param += value;\n *        return true; //iterate till the end\n *  }\n *\n */\n// we can also create iterator structs\ncounter = 0;\nroaring_uint32_iterator_t *  i = roaring_create_iterator(r1);\nwhile(i-\u003ehas_value) {\n   counter++; // could use    i-\u003ecurrent_value\n   roaring_advance_uint32_iterator(i);\n}\nroaring_free_uint32_iterator(i);\n// roaring_bitmap_get_cardinality(r1) == counter\n\nroaring_bitmap_free(r1);\nroaring_bitmap_free(r2);\nroaring_bitmap_free(r3);\n```\n\n# Example (C++)\n\n```c++\n////\n//// #include \"roaring.hh\" from cpp directory\n////\nRoaring r1;\nfor (uint32_t i = 100; i \u003c 1000; i++) {\n  r1.add(i);\n}\n\n// check whether a value is contained\nassert(r1.contains(500));\n\n// compute how many bits there are:\nuint32_t cardinality = r1.cardinality();\n\n// if your bitmaps have long runs, you can compress them by calling\n// run_optimize\nuint32_t size = r1.getSizeInBytes();\nr1.runOptimize();\n\n// you can enable \"copy-on-write\" for fast and shallow copies\nr1.setCopyOnWrite(true);\n\n\nuint32_t compact_size = r1.getSizeInBytes();\nstd::cout \u003c\u003c \"size before run optimize \" \u003c\u003c size \u003c\u003c \" bytes, and after \"\n            \u003c\u003c  compact_size \u003c\u003c \" bytes.\" \u003c\u003c std::endl;\n\n\n// create a new bitmap with varargs\nRoaring r2 = Roaring::bitmapOf(5, 1, 2, 3, 5, 6);\n\nr2.printf();\nprintf(\"\\n\");\n\n// we can also create a bitmap from a pointer to 32-bit integers\nconst uint32_t values[] = {2, 3, 4};\nRoaring r3(3, values);\n\n// we can also go in reverse and go from arrays to bitmaps\nuint64_t card1 = r1.cardinality();\nuint32_t *arr1 = new uint32_t[card1];\nr1.toUint32Array(arr1);\nRoaring r1f(card1, arr1);\ndelete[] arr1;\n\n// bitmaps shall be equal\nassert(r1 == r1f);\n\n// we can copy and compare bitmaps\nRoaring z (r3);\nassert(r3 == z);\n\n// we can compute union two-by-two\nRoaring r1_2_3 = r1 | r2;\nr1_2_3 |= r3;\n\n// we can compute a big union\nconst Roaring *allmybitmaps[] = {\u0026r1, \u0026r2, \u0026r3};\nRoaring bigunion = Roaring::fastunion(3, allmybitmaps);\nassert(r1_2_3 == bigunion);\n\n// we can compute intersection two-by-two\nRoaring i1_2 = r1 \u0026 r2;\n\n// we can write a bitmap to a pointer and recover it later\nuint32_t expectedsize = r1.getSizeInBytes();\nchar *serializedbytes = new char [expectedsize];\nr1.write(serializedbytes);\nRoaring t = Roaring::read(serializedbytes);\nassert(r1 == t);\ndelete[] serializedbytes;\n\n// we can iterate over all values using custom functions\nuint32_t counter = 0;\nr1.iterate(roaring_iterator_sumall, \u0026counter);\n    /**\n     * bool roaring_iterator_sumall(uint32_t value, void *param) {\n     *        *(uint32_t *) param += value;\n     *        return true; // iterate till the end\n     *  }\n     *\n     */\n\n// we can also iterate the C++ way\ncounter = 0;\nfor(Roaring::const_iterator i = t.begin() ; i != t.end() ; i++) {\n   ++counter;\n}\n// counter == t.cardinality()\n\n```\n\n\n\n# Building with cmake (Linux and macOS, Visual Studio users should see below)\n\nCRoaring follows the standard cmake workflow. Starting from the root directory of\nthe project (CRoaring), you can do:\n\n```\nmkdir -p build\ncd build\ncmake ..\nmake\n# follow by 'make test' if you want to test.\n# you can also type 'make install' to install the library on your system\n```\n(You can replace the ``build`` directory with any other directory name.)\n\nBy default, on all platforms, we build a dynamic library. You can generate a static library by adding ``-DBUILD_STATIC=ON`` to the command line.\n\nAs with all ``cmake`` projects, you can specify the compilers you wish to use by adding (for example) ``-DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++`` to the ``cmake`` command line.\n\n\n\nIf wish to build an x64 version while disabling AVX2 and BMI2 support at the expense of performance, you can do the following :\n\n```\nmkdir -p buildnoavx\ncd buildnoavx\ncmake -DDISABLE_AVX=ON ..\nmake\n```\n\nThe reverse is also possible. Some compilers may not enable AVX2 support, but you can force it in the following manner:\n\n```\nmkdir -p buildwithavx\ncd buildwithavx\ncmake -DFORCE_AVX=ON ..\nmake\n```\n\n\nIf you have x64 hardware, but you wish to disable all x64-specific optimizations (including AVX), then you can\ndo the following...\n\n```\nmkdir -p buildnox64\ncd buildnoavx\ncmake -DDISABLE_X64=ON ..\nmake\n```\n\n\nFor a debug release, starting from the root directory of the project (CRoaring), try\n\n```\nmkdir -p debug\ncd debug\ncmake -DCMAKE_BUILD_TYPE=Debug -DSANITIZE=ON ..\nmake\n```\n\n(Again, you can use the ``-DDISABLE_AVX=ON`` flag if you need it.)\n\n(Of course you can replace the ``debug`` directory with any other directory name.)\n\n\nTo run unit tests (you must first run ``make``):\n\n```\nmake test\n```\n\nThe detailed output of the tests can be found in ``Testing/Temporary/LastTest.log``.\n\nTo run real-data benchmark\n\n```\n./real_bitmaps_benchmark ../benchmarks/realdata/census1881\n```\nwhere you must adjust the path \"../benchmarks/realdata/census1881\" so that it points to one of the directories in the benchmarks/realdata directory.\n\n\nTo check that your code abides by the style convention (make sure that ``clang-format`` is installed):\n\n```\n./tools/clang-format-check.sh\n```\n\nTo reformat your code according to the style convention (make sure that ``clang-format`` is installed):\n\n```\n./tools/clang-format.sh\n```\n\n# Building (Visual Studio under Windows)\n\nWe are assuming that you have a common Windows PC with at least Visual Studio 2015, and an x64 processor.\n\nTo build with at least Visual Studio 2015 from the command line:\n- Grab the CRoaring code from GitHub, e.g., by cloning it using [GitHub Desktop](https://desktop.github.com/).\n- Install [CMake](https://cmake.org/download/). When you install it, make sure to ask that ``cmake`` be made available from the command line.\n- Create a subdirectory within CRoaring, such as ``VisualStudio``.\n- Using a shell, go to this newly created directory. For example, within GitHub Desktop, you can right-click on  ``CRoaring`` in your GitHub repository list, and select ``Open in Git Shell``, then type ``cd VisualStudio`` in the newly created shell.\n- Type ``cmake -DCMAKE_GENERATOR_PLATFORM=x64 ..`` in the shell while in the ``VisualStudio`` repository. (Alternatively, if you want to build a static library, you may use the command line ``cmake -DCMAKE_GENERATOR_PLATFORM=x64 -DBUILD_STATIC=ON  ..``.)\n- This last command created a Visual Studio solution file in the newly created directory (e.g., ``RoaringBitmap.sln``). Open this file in Visual Studio. You should now be able to build the project and run the tests. For example, in the ``Solution Explorer`` window (available from the ``View`` menu), right-click ``ALL_BUILD`` and select ``Build``. To test the code, still in the ``Solution Explorer`` window, select ``RUN_TESTS`` and select ``Build``.\n\nTo build with at least Visual Studio 2017 directly in the IDE:\n- Grab the CRoaring code from GitHub, e.g., by cloning it using [GitHub Desktop](https://desktop.github.com/).\n- Select the ``Visual C++ tools for CMake`` optional component when installing the C++ Development Workload within Visual Studio.\n- Within Visual Studio use ``File \u003e Open \u003e Folder...`` to open the CRoaring folder.\n- Right click on ``CMakeLists.txt`` in the parent directory within ``Solution Explorer`` and select ``Build`` to build the project.\n- For testing, in the Standard toolbar, drop the ``Select Startup Item...`` menu and choose one of the tests. Run the test by pressing the button to the left of the dropdown.\n\n\nWe have optimizations specific to AVX2 in the code, and they are turned only if the ``__AVX2__`` macro is defined. In turn, these optimizations should only be enabled if you know that your target machines will support AVX2. Given that all recent Intel and AMD processors support AVX2, you may want to make this assumption. Thankfully, Visual Studio does define the ``__AVX2__`` macro whenever the ``/arch:AVX2`` compiler option is set. Unfortunately, this option might not be set by default. Thankfully, you can enable it with CMake by adding the ``-DFORCE_AVX=ON`` flag (e.g., type ``cmake -DFORCE_AVX=ON -DCMAKE_GENERATOR_PLATFORM=x64 ..`` instead of  ``cmake -DCMAKE_GENERATOR_PLATFORM=x64 ..``). If you are building directly in the IDE (with at least Visual Studio 2017 and the Visual C++ tools for CMake component), then right click on ``CMakeLists.txt`` and select \"Change CMake Settings\". This opens a JSON file called ``CMakeSettings.json``. This file allows you to add CMake flags by editing the ``\"cmakeCommandArgs\"`` keys. [E.g., you can modify the lines that read ``\"cmakeCommandArgs\" : \"\"`` so that they become ``\"cmakeCommandArgs\" : \"-DFORCE_AVX=ON\"``.](https://goo.gl/photos/XH7peTKYRCSxWzph9) The relevant part of the JSON file might look at follows:\n\n      {\n        \"name\": \"x64-Debug\",\n        \"generator\": \"Visual Studio 15 2017 Win64\",\n        \"configurationType\": \"Debug\",\n        \"buildRoot\": \"${env.LOCALAPPDATA}\\\\CMakeBuild\\\\${workspaceHash}\\\\build\\\\${name}\",\n        \"cmakeCommandArgs\": \"-DFORCE_AVX=ON\",\n        \"buildCommandArgs\": \"-m -v:minimal\"\n      },\n      {\n        \"name\": \"x64-Release\",\n        \"generator\": \"Visual Studio 15 2017 Win64\",\n        \"configurationType\" : \"Release\",\n        \"buildRoot\":  \"${env.LOCALAPPDATA}\\\\CMakeBuild\\\\${workspaceHash}\\\\build\\\\${name}\",\n        \"cmakeCommandArgs\":  \"-DFORCE_AVX=ON\",\n        \"buildCommandArgs\": \"-m -v:minimal\"\n       }\n\nAfter this modification, the output of CMake should include a line such as this one:\n\n       CMAKE_C_FLAGS:   /arch:AVX2  -Wall\n\nYou must understand that this implies that the produced binaries will not run on hardware that does not support AVX2. However, you might get better performance.\n\nWe have additionnal optimizations that use inline assembly. However, Visual Studio does not support inline assembly so you cannot benefit from these optimizations under Visual Studio.\n\n\n# Thread safety\n\nLike, for example, STL containers or Java's default data structures, the CRoaring library has no built-in thread support. Thus whenever you modify a bitmap in one thread, it is unsafe to query it in others. It is safe however to query bitmaps (without modifying them) from several distinct threads,  as long as you do not use the copy-on-write attribute. For example, you can safely copy a bitmap and use both copies in concurrently. One should probably avoid the use of the copy-on-write attribute in a threaded environment.\n\n\n# Python Wrapper\n\nTom Cornebize wrote a Python wrapper available at https://github.com/Ezibenroc/PyRoaringBitMap\n\n# C# Wrapper\n\nBrandon Smith wrote a C# wrapper available at https://github.com/RogueException/CRoaring.Net (works for Windows and Linux under x64 processors)\n\n\n# Go (golang) Wrapper\n\nThere is a Go (golang) wrapper available at https://github.com/RoaringBitmap/gocroaring\n\n# Rust Wrapper\n\nSaulius Grigaliunas wrote a Rust wrapper available at https://github.com/saulius/croaring-rs\n\n\n# Redis Module\n\nAntonio Guilherme Ferreira Viggiano wrote a Redis Module available at https://github.com/aviggiano/redis-roaring\n\n\n# References and further reading\n\n-  Array layouts for comparison-based searching http://arxiv.org/pdf/1509.05053.pdf\n-  Schlegel et al., Fast Sorted-Set Intersection using SIMD Instructions\n\n\n# Mailing list/discussion group\n\nhttps://groups.google.com/forum/#!forum/roaring-bitmaps\n\n# References about Roaring\n\n-  Samy Chambi, Daniel Lemire, Owen Kaser, Robert Godin,\nBetter bitmap performance with Roaring bitmaps,\nSoftware: Practice and Experience Volume 46, Issue 5, pages 709–719, May 2016\nhttp://arxiv.org/abs/1402.6407 This paper used data from http://lemire.me/data/realroaring2014.html\n- Daniel Lemire, Gregory Ssi-Yan-Kai, Owen Kaser, Consistently faster and smaller compressed bitmaps with Roaring, Software: Practice and Experience (accepted in 2016, to appear) http://arxiv.org/abs/1603.06549\n- Samy Chambi, Daniel Lemire, Robert Godin, Kamel Boukhalfa, Charles Allen, Fangjin Yang, Optimizing Druid with Roaring bitmaps, IDEAS 2016, 2016. http://r-libre.teluq.ca/950/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Froaringbitmap%2Froaringcli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Froaringbitmap%2Froaringcli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Froaringbitmap%2Froaringcli/lists"}