Re: FORTH as a high-level assembler (was: Intro to Programming w/ Machine Language)
From: Randall Hyde (randyhyde_at_earthlink.net)
Date: 02/17/05
- Previous message: Frank Kotler: "Re: Need help on modifying and assembly of a small program!"
- In reply to: robert spykerman: "FORTH as a high-level assembler (was: Intro to Programming w/ Machine Language)"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 17 Feb 2005 14:05:23 GMT
"robert spykerman" <robspyke_nospam@no_spam_iprimus.com.au_no_spam> wrote in
message news:r1c811ttui8cnjjj9r3oqr3id0pvk5t3oc@4ax.com...
>
> There is a case to be made for using FORTH to learn assembly language.
> Hell you get to learn FORTH too at the same time, which is no bad
> thing.
No, not at all (a bad thing).
> For learning assembly, I have to admit I have made more progress
> using Forth than any traditional assembler, mainly because of the
> following:
Everyone is different. So this is not surprising. I doubt you're the only
one for whom FORTH is the best approach.
>
> 1. My forth system has a capable assembler (see above)
Yes, most do.
> 2. The forth philosophy of breaking things down into tiny chunks
> (factoring) fits my style of programming.
> 3. Interactiveness of the environment.
> 4. if you're using an x86 your x87 is actually a stack processor ;)
Of course, do realize that the x87 is slowly going away. Win64,
for example, disallows its use.
>
> PLUS, you have access to FORTH and all its weirdness and splendour. If
> you're nerdy enough to want to learn assembly chances are you might
> like Forth.
Therein lies the problem. Most people don't learn assembly because
they want to. They learn assembly because it's part of their course
curriculum. They aren't interested in the weirdness or splendor of
assembly (and probably wouldn't be interested in FORTH's, either).
Someone who is *interested* enough in learning assembly will learn
assembly no matter what tool and pedagogy they have available
to them. But this is only a small fraction of the people who actually
get exposed to assembly language every year.
>
> It's not for everyone, I have to admit, there are many weaknesses in
> Forth as it stands, but I am only proposing it here as a tool to LEARN
> x86 assembly and basic computer architecture.
I'm not sure that FORTH is any better a tool for learning architecture
than a high-level language (sure FORTH+assembly does the job,
'cause you've got the assembly part).
As for teaching assembly, the difference between the HLA approach
and the FORTH approach is that HLA's approach uses existing
HLL knowledge, the FORTH+assembly approach requires most
people to learn two new things at the same time. In a typical college
environment, it's better to build on existing knowledge.
Of course, if someone had an interest in learning FORTH, this
would be the way to go.
>
> Apologies, Randy, but I think FORTH is even better than HAL to be
> starting to learn assembly.
>
For some people, yes. For those interested in learning FORTH, yes.
But I don't think it would work for your average college student who
isn't interested in learning either language. The HLA approach works
by leveraging the student's *existing* knowledge, not by making them
learn two completely new languages simultaneously. Now if someone
already knew FORTH, this would be a great approach to teaching
them assembly language.
> PS I bought your book, it's a good introduction but for me what worked
> was Forth and some RTFMing from various sources, including your book,
> but not the HAL environment, mainly because it is too klunky and
> involves MASM, and strangely enough does not use MASM/intel style
> mnemonics as a default.
Actually, it *does* use MASM mnemonics (unlike, say, AT&T Gas).
What is difference is much of the other syntax.
But to each his own. If FORTH works for you, go for it. The fact that
you've learned assembly is the important thing, not which assembler
you happen to use.
Cheers,
Randy Hyde
- Previous message: Frank Kotler: "Re: Need help on modifying and assembly of a small program!"
- In reply to: robert spykerman: "FORTH as a high-level assembler (was: Intro to Programming w/ Machine Language)"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|