ARM Support for Typesense on AWS Graviton Servers
TLDR Tatu inquires on ARM support for Typesense. Kishore Nallan informs it's on the roadmap with end of year completion. After some troubleshooting, they successfully test an ARM build, preparing it for the 0.23 release.
1
Sep 24, 2021 (28 months ago)
Tatu
11:52 AMKishore Nallan
12:04 PM1. We have to ensure that all dependencies that Typesense uses can compile on ARM.
2. Port x86 specific SIMD intrinsics to NEON -- I've already checked on this and this should not be a blocker.
3. Build Typesense and run our perf tests to ensure that there aren't any gotchas.
I think we should be able to go through this and be ARM compatible by end of the year.
Tatu
12:06 PMKishore Nallan
12:07 PMTo start with, we need to know if these dependencies build on ARM: https://github.com/typesense/typesense/blob/master/docker/development.Dockerfile
Kishore Nallan
12:08 PMTatu
12:08 PMKishore Nallan
12:09 PMTatu
06:07 PMTatu
06:14 PM1. Change python-software-properties to software-properties-common
2. Change CMake from
cmake-3.15.2-Linux-x86_64.tar.gz
to cmake-3.21.3-linux-aarch64.tar.gz
. The 3.15.2 version doesn't have aarch64 variant available.3. brpc build fails. The solution is to add
-Wno-narrowing
in CMAKE_CXX_FLAGS
of patches/brpc_cmakelists.txtOtherwise no issues. Built on AWS Graviton t4g.medium instance running a clean install of Ubuntu 20.04.2.
Tatu
06:33 PM-msse4 -msse4.2
from CMAKE_CPP_FLAGS
of /opt/braft-c649789133566dc06e39ebd0c69a824f8e98993a/CMakeLists.txt
seemed to work and the build succeeded. Don't know if that affects something, but at least everything builds now.Sep 25, 2021 (28 months ago)
Kishore Nallan
01:47 AM> Don't know if that affects something, but at least everything builds now.
-msse4 -msse4.2
flags enable SIMD instructions. There might be equivalent flags for ARM which we we can enable. I will check it out.But overall, this is great news: it means that there are no major blockers! I will update this thread as I patch the code to make these changes and start on Typesense specific changes for NEON.
1
Dec 01, 2021 (26 months ago)
Tatu
09:39 PMDec 02, 2021 (26 months ago)
Kishore Nallan
06:25 AMTatu
10:40 AMDec 04, 2021 (25 months ago)
Kishore Nallan
01:12 PMI already did some smoke testing and as well as run the test suite and some benchmarking, and it looks fine.
Tatu
02:51 PMKishore Nallan
02:54 PMThe current plan is to make the ARM build available as part of the 0.23 release (0.22 is under code freeze and will be released pretty soon).
This build has a couple of minor features planned for 0.23 (specifically treating space as typo: https://github.com/typesense/typesense/issues/133) but should be otherwise stable to use.
Kishore Nallan
02:55 PMTatu
03:18 PMThere's a lot more we could do with Typesense I think, now that we're able to complete our transition to ARM I think it's time to start to explore a bit more what Typesense has to offer!
Kishore Nallan
03:29 PMTypesense
Indexed 3015 threads (79% resolved)
Similar Threads
Trouble Running Typesense Docker Image on AMD Phenom II X4 955 Processor
Ian struggles to run Typesense on an AMD Phenom II X4 955 Processor, experiencing the docker image to shut down immediately upon startup. Jason and Kishore Nallan suggest multiple troubleshooting steps, identifying the potential issue as the processor's lack of support for MSSE4 flags.
Announcing Typesense v0.23 and Addressing Queries
Jason announced new Typesense v0.23 upgrades and addressed inquiries from Ross about schema changes and cloud updates. User Janaka asked about price-performance on ARM, which Jason answered. Others, like A, Bill, Carl, and Ailish, expressed excitement.
Resolving Issues with Infix and Prefix in Query Searches
Daren struggled with searches missing values in production. Jason and Kishore Nallan offered insights and created new features to help solve the problem, which was then tested and deployed by Daren.
Discussing Search API Limitations and Solutions
Sidharth had problems with search API response limitations and sorting issues. Kishore Nallan suggested multi_search query and provided links for an updated version. After installation, some timeout and performance issues were encountered, partially resolved by adjusting client timeout values.
Seeking C++ Project Contribution Guidance
Peka wants to contribute to a project and seeks resources. Kishore Nallan provides initial guidance and recommends starting with a simple task on the Typesense project. Peka encounters a setup error well into the process.