Giter Site home page Giter Site logo

Add riscv64 support about js80p HOT 3 CLOSED

aimixsaka avatar aimixsaka commented on May 25, 2024
Add riscv64 support

from js80p.

Comments (3)

attilammagyar avatar attilammagyar commented on May 25, 2024 1

Thanks! I merged your patches, and added a few whistles and bells in release.sh around target and build platform handling.

riscv64 is not compatible with SSE or AVX, I think it's better to build a seperate bundle

It's not a problem, as long as it's in a separate directory inside the bundle, because VST 3 hosts are supposed to load the plugin from paths like js80p.vst3/Contents/$(uname -m)-linux/js80p.so.

So if you load a VST 3 bundle on an x86_64 system, then the host should be looking for js80p.vst3/Contents/x86_64-linux/js80p.so, and if you load the same bundle on RISC-V 64, then it should attempt to load js80p.vst3/Contents/riscv64-linux/js80p.so. (That's why the collision between instruction sets occurs only when the instruction sets are different flavors of the same platform, and that's why this collision requires separate bundles or non-trivial dynamic loading.)

But in the end, putting the binaries for different platforms into a single bundle is just a convenience thing, not a requirement of VST 3, so it's fine either way, therefore I kept your version of building separate bundles.

And I don't know if it's ok to change the SUFFIX/arch name from 32/64bit to x86/x86_64/riscv64,
as it seems a little "breaking"

It's fine, this affects only the directory names inside dist/ and the name of the ZIP files, but nothing depends on these.

from js80p.

attilammagyar avatar attilammagyar commented on May 25, 2024

Thank you!

I don't plan to release the plugin for other platforms than the current ones, but I'm happy to merge your changes if it makes things easier for you, and also to add links to the readme and the website to direct users to your project who are looking for a riscv64 version.

At first glance, your changes look okay, but in release.sh, the VST3 packaging seems to have a little bug: when building the SSE2 compatible VST3 bundle, you're supposed to include both the x86 and the x86_64 binaries (for both Linux and Windows) in the same single bundle. Other than that, it's up to you if you want to release the riscv64 version as a separate bundle, or if you want to release either or both of the SSE2 and the AVX bundles extended with the riscv64 version as well.

By the way, the only reason I build a separate bundle for AVX is that the specs only use the output of uname -m to find out the directory name for the platform, but they don't distinguish different instruction set extensions within a platform, so the SSE-compatible and the AVX-compatible plugin would run into a path and file name collision. (I guess this could be resolved by detecting the platform's capabilities at runtime, and loading the appropriate binary dynamically, but I was not confident that I could implement that properly.)

I'm sorry for the confusion.

from js80p.

aimixsaka avatar aimixsaka commented on May 25, 2024

Sorry for the late reply.

you're supposed to include both the x86 and the x86_64 binaries (for both Linux and Windows) in the same single bundle

Thanks. Already fixed this at latest commit

it's up to you if you want to release the riscv64 version as a separate bundle

riscv64 is not compatible with SSE or AVX, I think it's better to build a seperate bundle

And I don't know if it's ok to change the SUFFIX/arch name from 32/64bit to x86/x86_64/riscv64,
as it seems a little "breaking"

from js80p.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.