Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Add support for Linux ARM64 #592

Open
martin-g opened this issue Jul 15, 2022 · 2 comments
Open

Feature request: Add support for Linux ARM64 #592

martin-g opened this issue Jul 15, 2022 · 2 comments

Comments

@martin-g
Copy link

Hello,

I'd like to request adding support for Linux ARM64 to gridss.

I've found two minor issues so far:

  1. https://hub.docker.com/r/gridss/gridss/tags currently supports only linux/amd64. Adding support for linux/arm64 should be easy by using docker/setup-qemu-action@v1 Github action. I could provide a PR for this if desired!

  2. 4 unit tests fail at the moment:


Failed tests: 
  SswJniAlignerTest>SmithWatermanAlignerTest.should_align_deletion:15->SmithWatermanAlignerTest.create:11->create:8
  SswJniAlignerTest>SmithWatermanAlignerTest.should_use_soft_clips:29->SmithWatermanAlignerTest.create:11->create:8
  SswJniAlignerTest>SmithWatermanAlignerTest.should_use_zero_based_reference_offset:23->SmithWatermanAlignerTest.create:11->create:8
  MathUtilTest.phredOr_should_minimise_error:16 expected:<2.7371665643157472> but was:<2.737166564315747>

2.1) Currently https://github.com/PapenfussLab/gridss/blob/master/src/main/resources/libsswjni.so is x86_64 only:

$ file src/main/resources/libsswjni.so
src/main/resources/libsswjni.so: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=5c830dd0468d0db783ed5c84bbf97f56d1b075b5, with debug_info, not stripped

So my workaround is:

diff --git src/test/java/au/edu/wehi/idsv/alignment/SswJniAlignerTest.java src/test/java/au/edu/wehi/idsv/alignment/SswJniAlignerTest.java
index 3931e64f..44e5fc11 100644
--- src/test/java/au/edu/wehi/idsv/alignment/SswJniAlignerTest.java
+++ src/test/java/au/edu/wehi/idsv/alignment/SswJniAlignerTest.java
@@ -1,11 +1,11 @@
 package au.edu.wehi.idsv.alignment;
 
-import static org.junit.Assert.assertTrue;
+import static org.junit.Assume.assumeTrue;
 
 public class SswJniAlignerTest extends SmithWatermanAlignerTest {
     @Override
     protected Aligner create(int match, int mismatch, int ambiguous, int gapOpen, int gapExtend) {
-        assertTrue(AlignerFactory.isSswjniLoaded());
+        assumeTrue(AlignerFactory.isSswjniLoaded());
         return new SswJniAligner(match, mismatch, ambiguous, gapOpen, gapExtend);
     }
-}
\ No newline at end of file
+}

2.2) I haven't investigated why MathUtil.java produces a different result on ARM64.

@martin-g martin-g changed the title Feature: Add support for Linux ARM64 Feature request: Add support for Linux ARM64 Jul 15, 2022
martin-g added a commit to martin-g/gridss that referenced this issue Jul 27, 2022
It should be ignored on non-x86_64 until src/main/resources/libsswjni.so
is provided for other architectures

Related-to: PapenfussLab#592

Signed-off-by: Martin Tzvetanov Grigorov <mgrigorov@apache.org>
martin-g added a commit to martin-g/gridss that referenced this issue Jul 27, 2022
Related-to: PapenfussLab#592

Maybe-related-to: https://bugs.openjdk.org/browse/JDK-8210416

Signed-off-by: Martin Tzvetanov Grigorov <mgrigorov@apache.org>
@d-cameron
Copy link
Member

Due to the x64 dependences in 3rd party libraries, there are currently no plans for ARM64 docker support.

All 3rd party x64 libraries used should have native Java fallbacks. In practice, the lack of acceleration means that GRIDSS is going to run slower on ARM.

@martin-g
Copy link
Author

martin-g commented Aug 5, 2022

Thanks for the answer, @d-cameron !

I will take a look at the 3rd party deps for the Docker image and I'll see what could be done for them!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants