Page 1 of 1

Using Assembler code outside Flowstone

Posted: Wed Feb 03, 2016 9:35 am
by Perfect Human Interface
Hi all. If one were to go about recreating a Flowstone plugin in another programming language, say C++, how feasible would it be to copy assembly language code right out of FS to reuse it?

Re: Using Assembler code outside Flowstone

Posted: Thu Feb 04, 2016 3:27 am
by Youlean
It will be very easy to do this, but there is chance that it woudnt work on x64...

Re: Using Assembler code outside Flowstone

Posted: Thu Feb 04, 2016 3:30 am
by Perfect Human Interface
Youlean wrote:It will be very easy to do this, but there is chance that it woudnt work on x64...


Do you mean that the assembly code may potentially need to be modified for compatibility?

Re: Using Assembler code outside Flowstone

Posted: Thu Feb 04, 2016 4:25 am
by tulamide
Assembler is very close to machine language, which means you need different codes for each platform you're exporting to (32bit Windows, 64bit Windows, Mac, Android, etc.)

Re: Using Assembler code outside Flowstone

Posted: Thu Feb 04, 2016 4:29 am
by Perfect Human Interface
tulamide wrote:Assembler is very close to machine language, which means you need different codes for each platform you're exporting to (32bit Windows, 64bit Windows, Mac, Android, etc.)

I see. Are we talking generally just replacing a few bits or a significant rewrite, or impossible to say?

Re: Using Assembler code outside Flowstone

Posted: Thu Feb 04, 2016 4:52 am
by tulamide
This may be answered by Martin, Exo, Myco and the like.

What I can say is that it the opcodes vary, as well as memory addressing and bit-depth of value types.

Re: Using Assembler code outside Flowstone

Posted: Thu Feb 04, 2016 8:36 pm
by Nubeat7
depending on how you are doing it in c++, i would work with crossplattform enviroment, like juce or WDL, additionally you will maybe use specialized libraries for dsp..

these are optimized frameworks and libraries, so normally you don't need any assembler, all in all it will be easier to rewrite the codes, better to write clean and optimized c++ code then coding around corners to fit in existing assembler code.. anyways when you wrote your plugins in assembler you will have the dsp codes for it too which is really easy to rewrite in c++

Re: Using Assembler code outside Flowstone

Posted: Fri Feb 05, 2016 12:49 pm
by Perfect Human Interface
Thanks for all the responses!

Re: Using Assembler code outside Flowstone

Posted: Fri Feb 05, 2016 12:59 pm
by TheOm
I would recommend to rewrite your assembler into intrinsics.
This should usually be a very straighforward conversion.
Intrinsics are compiler-specific though.