Viewing TorqueScript VM assembly...
by Stephen Nichols · in Torque Game Builder · 03/20/2009 (9:25 am) · 3 replies
Does anyone know of a method for viewing TorqueScript VM "assembly code"? I've found the compiler / interpreter code in the engine without trouble. Pretty straightforward stuff...
However, I'm looking to formulate a set of best practices for writing "fast" TorqueScript. To that end, I'd love to view the disassembly of my compiled scripts.
Anyone know of such a tool? If not, I guess the worst case is that I'll write my own.
steve
However, I'm looking to formulate a set of best practices for writing "fast" TorqueScript. To that end, I'd love to view the disassembly of my compiled scripts.
Anyone know of such a tool? If not, I guess the worst case is that I'll write my own.
steve
#2
Do you know of any links to such tools? Any info would be great.
Do I really need to do this? I think so. I've worked with many scripting languages over my game programming career: SCI, lua, ActionScript, UnrealScript, PHP, Perl, Python, etc. One of the things I've learned through my experience with these languages is this: Understand the performance implications of writing code in them.
Scripting languages are a godsend... they allow for more rapid iteration and open up opportunities for "noob" programmers (i.e. game designers and artists) to contribute to the logic of the game. In my experience, non-programmers take more easily to scripting languages than C++.
That being said about scripting languages; they can also be a terrible burden. Any code can be written poorly and run slower... but poorly written script code can be excessively underperforming. I want to take a peek under the hood of the VM to see what kinds of patterns would be poor performers. And, from that information, we can determine how to write efficient script.
steve
03/20/2009 (3:31 pm)
Joe:Do you know of any links to such tools? Any info would be great.
Do I really need to do this? I think so. I've worked with many scripting languages over my game programming career: SCI, lua, ActionScript, UnrealScript, PHP, Perl, Python, etc. One of the things I've learned through my experience with these languages is this: Understand the performance implications of writing code in them.
Scripting languages are a godsend... they allow for more rapid iteration and open up opportunities for "noob" programmers (i.e. game designers and artists) to contribute to the logic of the game. In my experience, non-programmers take more easily to scripting languages than C++.
That being said about scripting languages; they can also be a terrible burden. Any code can be written poorly and run slower... but poorly written script code can be excessively underperforming. I want to take a peek under the hood of the VM to see what kinds of patterns would be poor performers. And, from that information, we can determine how to write efficient script.
steve
#3
Honestly it shouldn't take too terribly long to do... i would jump at it if i wasn't in GDC crunch time.
03/20/2009 (11:43 pm)
I don't know of any TorqueScript disassembly tools... but i'd love to see one thrown together. Honestly it shouldn't take too terribly long to do... i would jump at it if i wasn't in GDC crunch time.
Torque Owner Joe Rossi
Indri Games