On 2015-02-21 01:44, ben wrote:
On 2/20/2015 5:02 PM, Dave G4UGM wrote:
Almost all , so there exceptions, modern
compliers are written in a high
level language. Most use LEXX and YACC or their modern equivalents to
generate the program fragments needed to generate the code.
I would say that is 50%. If you have LEXX and YACC you tend have a
UNIX system with a C compiler.
You don't even have that. LEX and YACC will give you the basics of the
parsing of the source code. Everything beyond that, you still have to write.
You have a front-end, which does the lexical work and
translates the
program into some intermediate form, such as a tree. In the middle, you
have optimization and checking--and finally, you have the back end which
essentially emits code--but that doesn't necessarily imply that the
compiler
author knows the numeric opcodes or the precise
instruction format.
Many
compiler backends feed into an existing assembler, which puts it all
together.
How do handle byte operations in C like *x++ on a PDP 10?
Do you need information on how byte operations and byte pointers work on
a PDP-10?
KCC, which is the one C compiler for the PDP-10 I sortof know something
about, use 9 bit chars, and of course you then get four bytes to a word.
Not sure what in your question is hard to see how it is done.
Johnny
--
Johnny Billquist || "I'm on a bus
|| on a psychedelic trip
email: bqt at softjar.se || Reading murder books
pdp is alive! || tryin' to stay hip" - B. Idol