1

I tried

  • Pascal Script
  • Fast Script
  • Script Studio
  • IdScript Engine

However none support inline ASM. Is there some library that DOES support it?

14
  • 1
    You want to write a script that contains assembly language. You do understand what "script" means don't you? You want to be able to write scripts that compile to raw asm code? Then it's not really scripting any more is it? Native compilation is not scripting. Scripting is not native compilation. Etc etc. Commented Oct 13, 2012 at 13:02
  • 2
    If you are still dead set on 64 bit, and your asm is 32 bit which it almost certainly is, you've got a port on your hands. Port to a high level language, not to another asm ghetto. Commented Oct 13, 2012 at 13:17
  • 3
    He's asking you if you could provide some more details so that there might be some way to accomplish what ever it is that you want to accomplish with a scripting language that is Pascal based, but which allows you to mix inline assembly via ASM, and if he can think of anything that would help you, he'd tell you about it. Because what you're asking for in your question is a huge (complex, problematic, unworkable) and probably impossible thing. How do you suppose that a scripting engine that compiles and then runs assembly language could do so safely? Check out Google NaCL. Commented Oct 13, 2012 at 15:02
  • 2
    Joe, the purpose of these comments is to get clarification of the question so that one can be able to answer. Are you suggesting that David be able to answer this very awkward question without clarification? Commented Oct 13, 2012 at 16:54
  • 4
    Voted Up. I don't understand all this flame. OP has pascal code with ASM blocks and want to execute it in a script with minimal edits. What is wrong with the question? Commented Oct 13, 2012 at 18:11

1 Answer 1

6

AFAIK DelphiWebScript aka DWScript supports ASM via it's language extension modules, specifically the dwsAsmLibModule.

UPDATE: found an Eric's blog post where he describes the feature. Looks like you need to have NASM installed in order to use ASM blocks in DWScript.

Sign up to request clarification or add additional context in comments.

6 Comments

Interesting.. I heard to support asm the code base would require to be massive like 5-10k lines of code.
I thought that the ASM directive in DelphiWebScript was for letting you use raw JavaScript inside a DWS, not x86 assembly language.
@WarrenP, the JavaScript asm part is for the SmartMobileStudio DWS extension. See from-op4js-to-smart-mobile-studio.
@LURD Seems like you can do this with ScriptStudio by TMS just need to "encapsulate" and it will work.
@ain By the way NASM is 64 bits. So hopefully one day it will be supported in DWS.
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.