Live data from Hacker News

Starting Forth

forth.com

31–40 of 71 posts

Re: Starting Forth

#31
post #5

Is Forth still being used in industry other than for legacy systems? (genuine question)

Yes in OS boot loaders. FreeBSD uses it, and I think Apple uses it for OSX. Possibly iOS.

Re: Starting Forth

#32
post #5

Is Forth still being used in industry other than for legacy systems? (genuine question)

Yes in OS boot loaders. FreeBSD uses it, and I think Apple uses it for OSX. Possibly iOS.

Sorry, I'm wrong regarding OSX and iOS. OpenFirmware is used at numerous places, but Apple is not one of them.

Re: Starting Forth

#33
post #14

Earlier quoted context omitted.

Open Firmware and the FreeBSD loader use it presently.

Yes, IIRC Intel's Itanium (IA64) architecture used firmware and drivers in Forth (instead of machine code) so you could use the hardware on any CPU architecture.

No, Itanium specifically eschewed OpenFirmware (IEEE1275-1994, which is ANS Forth based) in favor of inventing EFI, which would develop into UEFI later.

Among the reasons: no interest in bytecode (UEFI now has EBC), no ACPI support (IEEE1275 predates ACPI by a decade, Intel didn't bother), protecting Intel's "Independent" BIOS Vendors from having to compete in an existing market (there were several OpenFirmware vendors).

Most OF implementations are now open source, we collected them at www.openfirmware.info.

Re: Starting Forth

#34
post #27

Forth seems to have one thing in common with Lisp: a small dedicated following that believe it's the way forward and considerably easier to learn, despite never really having taken off. I suspect this is something to do with different ways of conceptualising programs.

They're different branches of computing history. There are few that consider it the 'way forward' as far as the mainstream is concerned, but the fans tend to consider it an underexplored model for one reason or another.

See also oberon, smalltalk, eiffel for more language communities of that kind (the jury is still undecided where haskell ends up); os/2, plan9, l4 when it comes to operating systems/kernels; 6502, m68k, mill for Instruction Set Architectures; (and so on)

Every now and then, us non-mainstreamers tend to sound a bit preachy when we get an audience, I grant that :-)

Re: Starting Forth

#35
post #27

Forth seems to have one thing in common with Lisp: a small dedicated following that believe it's the way forward and considerably easier to learn, despite never really having taken off. I suspect this is something to do with different ways of conceptualising programs.

if you take away the parentheses from Lisp you end with a Forth

Not at all. I have developed in both languages. Forth is almost bare metal, between Assembler and C. Lisp is a high level language. Its abstraction level can be pushed way beyond any other language. DSL creation is much easier in Lisp than in Forth.

Re: Starting Forth

#36
post #25

Earlier quoted context omitted.

What has the industry moved onto now?

Embedded stuff is nearly always C. Arduino have made the "Wiring" language popular for rapid prototyping (based on processing and hence javascript). But these days, embedded full Linux systems are just too cheap to not be the default option when you want to develop on the device itself.

Processing is based on Java, not JavaScript.

Re: Starting Forth

#37
post #25

Earlier quoted context omitted.

What has the industry moved onto now?

Embedded stuff is nearly always C. Arduino have made the "Wiring" language popular for rapid prototyping (based on processing and hence javascript). But these days, embedded full Linux systems are just too cheap to not be the default option when you want to develop on the device itself.

My understanding is that the link between Arduino and Processing is solely in the IDE. I don't think the two share any common ground beyond just the fact that Java (which Processing is a very thin layer on top of) is similar to C (which Arduino is a very thin layer on top of.)

Re: Starting Forth

#38

Earlier quoted context omitted.

Yes in OS boot loaders. FreeBSD uses it, and I think Apple uses it for OSX. Possibly iOS.

Sorry, I'm wrong regarding OSX and iOS. OpenFirmware is used at numerous places, but Apple is not one of them.

Apple used it when they were still PowerPC-based. They sadly dropped it with the move to Intel.

Re: Starting Forth

#39

Earlier quoted context omitted.

Yes in OS boot loaders. FreeBSD uses it, and I think Apple uses it for OSX. Possibly iOS.

Sorry, I'm wrong regarding OSX and iOS. OpenFirmware is used at numerous places, but Apple is not one of them.

Apple used to use it in the PowerPC days as did Sun - https://en.wikipedia.org/wiki/Open_Firmware http://www.brendangregg.com/Sun/obp.html

Re: Starting Forth

#40

An approachable platform for hacking Forth is the OLPC laptop[1]. For about $25 USD[2], that's a pretty cheap way to go Forth and multiply :-). 1 - http://www.openfirmware.info/Forth/FCode 2 - http://www.ebay.com/sch/items/?_nkw=olpc+laptop&_sacat=&_ex_...

If you have an OLPC XO 1 then you can also download the specifications for the AMD CPU here: http://www.versalogic.com/support/Downloads/PDF/LXManualMay0...

That tells you how to do graphics hacks and so on. I had fun with that on my OLPC. I optimized the Forth console to scroll using hardware BLIT (much faster than CPU copy of the framebuffer) and I ported Squeak Smalltalk to run directly on OFW using hardware graphics primitives e.g. for the mouse pointer.

Fun times :)

Post reply on HN