Compass vs. WBASS (vs. other assemblers?)

Pagina 1/2
| 2

Door Grauw

Ascended (10583)

afbeelding van Grauw

22-01-2003, 01:13

Ro wrote:

here we go..

o Wbass Tokenizes code and PRE-assembles it while editing

thangx to this, 2step assembling is done very fast

o Coding in modules, and linking them is cool, but takes MUCH longer

to assemble...

o Wbass is NOT (I repeat NOT) ment to use in BASIC, you should know that.

Basic is just an environment in which a general MSX will start mostly. Coding is just programming your CPU and memory. nothing more. Our F-kernel, just an example, runs perfect using DOS x.x routines. (I said USING DOS, not running in/under DOS).

DOS is just one of them many operation systems.

o Wbass is a plain, basic assembler, I agree. So, we made our own versions, using F-kernel which has memory management and there for making use if it with wbass was e.z. as 1.2.3. There you have it: As much SOURCES as you like in memory!! (no limit, but the memory size)

o Label handling was done better in wbass, but a minor was the 6 string length..

o Data handling was done sooo much better, I could do ANYTHING with ANY data, which I had trouble with in compass.

and so on.

Don't get me wrong here, I was eager to use Compass, really. But after having done some code with it.. I was a bit dissapointed about certain thinx (which I can't recall it this moment, exept for some statements mentioned above).

So I would stick to wbass. And, I hate to say this, I could really good some nice meals with it! (can't disagree that the fuzz made some okay stuff, not?)

But again, it's the CODING issue which is being discused in another threat (general).

Hmmmz I wanna talk more about Compass vs. WBASS hehe... You're talking about a version of WBASS you apparantly modified yourself to overcome the source size limit... Well hehe if I modify Compass myself I bet I can make it do awesome things too Smile. Anyways ofcourse this way, comparing Compass with WBASS is a little 'unfair' in the sense that I and other people don't have access to that 'version'. Or erm, are you going to release your custom WBASS to the public? Hmmz??? ;p

About assembling time, Compass doesn't precompile while editing (yet) (Compass 2.0 will), but still it is very fast. It assembles 1600 lines of codes in 10 seconds. I don't know how fast WBASS does this because it's been awhile and I didn't assemble sources of this size back then (actually a 1600-line source probably won't be too much for WBASS I think), but it's clear that Compass is pretty fast.

WBASS, just like Compass, allows you to quickly make a shell to Basic. However as far as I can remember, a shell to DOS wasn't possible, which is quite essential when programming .com files Smile. Compass can do both very well, although it doesn't 'remember' the basic code inbetween Basic sessions. But then again, I since long ago don't program hybride anymore. And even then, Compass 2.0 *will* remember the code (same goes for DOS, it will even be able to interrupt for example a DIR command, and continue it later on!).

Compass has pretty much an ideal mapper & memory handler, you can do everything and set exactly how you want it to behave. I've never run into any limits when using it, which I mainly do in the debugger. Talking about the debugger, it's pretty spiff too ^_^.

But erm, in what way is label handling in WBASS better? When using 2-pass assembling you can only do so much. Also, the data handling kind of puzzles me... So far, I've never been unable to do something (alignment filler bytes for example is rather easy). Although there are several features which I'd like to see (a lot of them implemented in Compass 2.0), afaik Compass already handles most if not all directives WBASS supports... Compass doesn't support ALIGN or INCBIN at the moment (yet? I don't know, I hope so), but WBASS doesn't either, does it??

Oh, on a sidenote, I'm not coding in modules and linking them afterwards, I'm just including them in the sourcecode ^_^. Linking is too much of a hassle to me, has limits too (6 characters lable length with current linkers), and so far the assembling hasn't taken a bothersome amount of time yet. And assembling times will only get better in (again) Compass 2.0 (Jon, hurry up damnit, I *need* it hehe) (it's like drugs, gimme a little of it and I want more).

Although I can understand that the WBASS you use is much better fit for more advanced programming stuff, other people don't have such a version ofcourse, nor do I, and especially when comparing the 'original' WBASS with Compass my main objection against WBASS remains its limited source size, it is sharing the same small <32k area from #8000 to #Esomething with both a. the basic program, b. the source code, and c. the assembled output code. That's what made me abandon WBASS in the first place - it was nice to get started on, but as soon as projects became too large and 'serious' it became a handicap. From that time on I used Gen80. Maybe sloooooow but at least placing no limits, and I also learned to appreciate the bliss of the Dos2 environment with it's 64k of TPA (user RAM) ^_^. After that I switched to Compass which was a big, big relief after Gen80.

Oh, and WBASS its limited label length also bothered me. Although at that time it wasn't really a big concern to me, because as long as your programs remain small it can be coped with, but now I've tasted 'the good life'... I'd never want anything else.

On the other hand there is WBASS's ease of use, especially as far as hybride programming is concerned, and it being an IDE, and it being a very fast assembler (something which definately can't be said of Gen80). As I said before, it is really the best assembler to start learning assembly with. It's easy to use, you can test your code very easily in a familiar (Basic) environment, has an IDE, and above all, is free.

~Grauw

Aangemeld of registreer om reacties te plaatsen

Van Grauw

Ascended (10583)

afbeelding van Grauw

22-01-2003, 01:31

Oh, btw, I don't have any experience with crossassemblers, but people who do, also feel free to contribute to the discussion and spam some opinions on and discuss the merits of your favorite assembler ;p. I didn't intend this discussion to cover solely WBASS and Compass (as the topic also implies Smile).

It would be nice to know what people think is the best assembler and why they think that. I bet it'll be interesting, and since I also still need to write an article comparing the several available assemblers for the MAP (MSX Assembly Page, an info site for assembly programmers) sometime in the future... For that I ofcourse have to know a little what I'm talking about, and also need to know what other people' opinion is. Also, the authors of assemblers which are still in development (Compass, TNIasm, etc. (?)) might just get a couple of good ideas from this ^_^.

~Grauw

Van anonymous

incognito ergo sum (116)

afbeelding van anonymous

22-01-2003, 02:22

tniASM 0wnz Tongue

Van pitpan

Prophet (3152)

afbeelding van pitpan

22-01-2003, 10:44

Actually I have written two different cross-assemblers for the PC mainly focused on MSX development: asMSX and rZ80. Both are available for MS-DOS (32-bits) and Win32 in console mode. A Linux/Solaris/etc. port could be easily done because it is coded using GNU GCC compiler.

It is curious, because asMSX was published a bit earlier than the first version of TNIasm and both have the same features.

rZ80 is a bit more advanced than asMSX, and it includes floating-point and fixed-point arithmethics, and that means trigonometry and much more. Also produces directly .ROM files and MSX-BASIC binaries, MSX-DOS executables and RAW Z80 binaries.

Anyway, both projects, asMSX and rZ80 are now discontinued. By the end of February I will start to code a brand-new assembler with all the missing features and some more. I have asked in the spanish mailing list (hispaMSX) if anybody has any interesting suggestion. It should be an option for developers, despite TNIasm is really powerful and it is really used. I use my own assembler, and that is great. Remember: any suggestion is welcome and included features will be properly acknowledged.

Van BiFi

Enlighted (4348)

afbeelding van BiFi

22-01-2003, 11:47

tniASM 0wnz Tongue

GuyveR800, for all the people who don't know tniASM, please tell more about it. What's better compared to other assemblers? What does it have that other assemblers don't and what features are still planned?

Van BiFi

Enlighted (4348)

afbeelding van BiFi

22-01-2003, 12:13

I've used many different assemblers: ZAS (an assembler written in Basic), Gen80, Macro80, ZSM, WB-ASS2 and Compass.

At the moment I only use Compass and sometimes WB-ASS2. I've mainly used WB-ASS2 for small things and testing stuff. Nowadays I use Compass for that as well. For me Compass is the best MSX assembler as I'm convinced good development for MSX should be done on MSX. I think it's much easier for debugging purposes since you can trace code and see if everything is going the way you planned it.

One of the things I miss in Compass is a real-time I/O monitor/editor, but even that is implemented in Compass 2.0.

Some other very useful options in Compass would be disassembling the RST &h30 interslot call to a more readable format like "CALLF P-S address" though I don't think that will be implemented and using official BIOS call names, system variable names and hook names in the (dis)assembler.

Van scratch_disk

Expert (72)

afbeelding van scratch_disk

22-01-2003, 16:29

I liked ZEN. In the good old days ZEN was the only mean for me to write small assmebly progs. I was not good at it, and still, but it was a real fun to wirte some.

Somebody tell me how to learn assembly? I have compass and I need small pieces of assmebly code to study.

Never heard about WBASS. Where can I find it?

Van Latok

msx guru (3867)

afbeelding van Latok

22-01-2003, 19:03

Did anyone of you ever used META? The -as far as I know- first cross assembler? It was made by MSX ENGINE.....

Van anonymous

incognito ergo sum (116)

afbeelding van anonymous

23-01-2003, 01:40

I have to say I have never heard about asMSX and rZ80 before now. I would be interested to know where to download them!

About what tniASM has to offer, I have to see the manual because I've been developing the NEW tniASM for so long I don't know exactly what features are also in the old one ^^;

tniASM:

- is a multi-pass assembler. That means it can handle multiple nested forward references.

- supports conditional assembly. It can assemble a block of code depending on the outcome of an expression (calculation), the previous declaration of a label, the existance of a label or the existance of a file.

- has a flexible local label mechanism. Among other useful things this allows you to use more descriptive labels without making them unnecessarily long.

- has a powerful 32 bit expressions parser with precedence levels. Among other things this allows you to write programs greater than 64kB.

- has source code and binary file inclusion. Where with INCBIN you can include portions of a file if you wish.

- has nestable block comments. So there is no need to use a lot of ;'s to write a big comment or temporarily comment out code. (BTW, you can also use the conditional assembly to achieve the that.)

- is able to output to multiple files from a single sourcefile. You can write a single .asm file where you INCLUDE all others, so it is similar to a MAKE-file.

- is able to output to within an already existing file. This allows you to patch existing files, for instance updating just part of a big LIBRARY file containing all program and data.

Besides these main features, tniASM also has UNLIMITED label lengths and flexible placement of instructions and labels. (You can place more than one instruction on a single line)

With tniASM you also have full control over the seperated Program Counter and File Position. The order of your program in source code does not have to be the same as it will be in memory!

tniASM also has directives for using uninitialised data, allowing you to reserve RAM without increasing filesize and without using badly maintainable EQU-constructs.

And last but not least, it is very fast Smile

I've already talked a bit about the new tniASM in other parts of the MRC Forums, so I won't do so here. Besides, it will take a while before it is ready anyway Tongue

I am very glad to hear people are using it, and I am always glad to recieve feedback from users! So email to the tniASM email address is very much appreciated.

Van ro

Scribe (4698)

afbeelding van ro

23-01-2003, 08:59

very nice...

Don't get me wrong, I like compass.. but not as much as I liked wbass2. I got so used to the command line in wbass.

Consider it as using the good old command line in windows x.x. I use that like 50% of my time (as being a sysop/netop/engineer) In wbass2 the command console is flexible, and good to use. Can do stuff like CALL, LOAD, read regs etc. just for debugging sake.

This is what I missed in compass (it's what I mean by saying label handling was done very good with wbass2)

it's just that I don't want to open up another window and test a formula with labels.. or anything. just typing formulas with labels on command line, and executing from there is very cool to work with.

It's what I used 90% of my debugging time (believe me, a lot had to be done Smile

Maybe another good reason:

The f-kernel thing. (our os)

We couldn't get it working under (and WITH!!) compass as we saw fit.

again, using command line options for kernel was great!

I've done some pretty good coding in wbass2, and never even got to finish a little test thingy in compass, just because I missed the command line etc.

I'd love to see compass2 with a command line, where I could use labels as freely as wbass2 could. (oh, wait... I haven't used my msx in years.. damn)

Van Grauw

Ascended (10583)

afbeelding van Grauw

23-01-2003, 17:55

Well if I want to test a formula (with labels) I type CTRL-C to bring up the calculator, you type PRINT (or whatever the command for calculating a formula is ^_^)... Anyways I could image one being used to the commandline, on the other hand in Compass I barely use the menu's, I can do all actions with fast shortcuts... Only for assembling to disk I use F4+ENTER (pressing down the first time I do that because assemble to disk is the 2nd menu item).

There's one sidenote though, Compass only knows the labels after assembling the program. I don't know how WBASS2 (or Compass 2.0 for that matter) does that with their pre-assembling during the editing... Maybe that's what you mean with 'better' label-handling?

As for Compass 2.0 and commandline stuff, Compass 2.0 will definately have more advanced commandline options (one of the very useful improvements) but that concerns the DOS commandline, and inside compass itself there is no and probably will never be a commandline. It's a menu/window-based IDE with shortcuts to speed things up...

One 'annoying' (read: it could be done better) thing in Compass is that I have to load the files manually after I start it, so I go through the same common ritual everytime I start Compass: CTRL-6 (60Hz), CTRL-D (disk menu), CTRL-1 (source buffer 1), type filename 1, move 1 left, SPACE, CTRL-2, type filename 2, SPACE, CTRL-3, type filename 3, SPACE, ESC, CTRL-1... That makes me switch to 60Hz and load 3 sourcebuffers. One gets used to it but it's still quite a hassle, and because of that I am really looking forward to Compass 2.0's better command line support, allowing the batch file to do all that (well, probably except for the 60Hz, but I could ofcourse simply run my little 60HZ.COM program, which in the contrary to crappy pal.com and ntsc.com *does* write back the modified r#9 contents to the BIOS mirror ;p).

~Grauw

Pagina 1/2
| 2