Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Oberon > Re: Pascal to O...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 6 of 17 Topic 198 of 491
Post > Topic >>

Re: Pascal to Oberon Translator

by Ulrich <whywouldyousendspam@[EMAIL PROTECTED] > Nov 1, 2005 at 08:03 PM

Stewart Greenhill wrote:
> noch wrote:
> 
>> There are no suitable for me oberon-2 compiler for linux yet.
> 
> [...]
> 
>> There are only two compilers which produce native code:
>> xds, oo2c.
>> xds doesn't do garbage collection for swapped data.
>> oo2c is mot useful, but it is not real compiler, just translator.
> 
> [...]
> 
>> So, I tell you I need oberon to pascal compiler more than pascal to
>> oberon because if I have no suitable compiler for programming, and I am
>> forced to use the best available: oo2c, that just making translation
>> from oberon to c code. So it will be a good solution write oberon
>> program, translate to pascal and compile it with kylix or better
>> freepascal compiler.
> 
> 
> I hope that you can see the irony in what you are suggesting. You don't 
> like oo2c because its "just a translator", yet you consider and oberon 
> to pascal translator a "good solution".
> 
> Ultimately, all compilers are just translators. They take a source 
> language and produce object code. Often there are many intermediate 
> stages; sometimes there are none.
> 
> oo2c has a higly modular internal structure, consisting of multiple 
> intermediate stages. The parser builds an abstract syntax tree ("AST"), 
> which is then converted into a SSA intermediate representation ("IR"). 
> OOC does extensive optimisation and transformation on the IR code. This 
> includes data-flow analysis which allows it to pick up problems like 
> uninitialised objects, and unused objects at compile time. It also 
> allows certain "run-time" checks to be factored out at compile time, 
> which is im****tant for achieving best performance for complex array and 
> record manipulations. The IR code is then translated to assembley 
> language. For ****tability OOC uses "C" as its assembley language, and 
> "gcc" as its assembler.
> 
> Alternatively, you could write your own native back-end to generate 
> other kinds of output from the IR code. That would cost you a large 
> amount of your time, and would not likely produce any benefit except 
> perhaps some philosophical satisfaction. Indeed, OOC includes an 
> experimental x86 back-end which I suspect was developed for that very 
> reason. If you can write a better optimizer than OOC + gcc combined then

> you might gain something in terms of performance. If you have a large 
> team of programmers available to do this, then you can make the compiler

> less dependent on external tools. But in terms of sup****ted platforms 
> per programming hour you can't beat "C" output.
> 
> Really, oo2c *is* a compiler by any reasonable definition of the term. 
> Sure, it uses another program to generate the final object code, but 
> then so do many other compilers (eg. gcc).
> 
> Cheers,
>   Stewart

Do you think it's feasible to replace the C generating backend of OOC by a
Pascal generating one?
 




 17 Posts in Topic:
Pascal to Oberon Translator
"Chris Burrows"  2005-10-10 10:41:20 
Re: Pascal to Oberon Translator
"noch" <gnor  2005-10-24 06:34:38 
Re: Pascal to Oberon Translator
"Chris Burrows"  2005-10-28 10:31:18 
Re: Pascal to Oberon Translator
"noch" <gnor  2005-10-28 08:11:59 
Re: Pascal to Oberon Translator
Stewart Greenhill <nos  2005-10-31 13:23:14 
Re: Pascal to Oberon Translator
Ulrich <whywouldyousen  2005-11-01 20:03:20 
Re: Pascal to Oberon Translator
"noch" <gnor  2005-10-28 08:16:43 
Re: Pascal to Oberon Translator
"noch" <gnor  2005-10-31 23:51:38 
Re: Pascal to Oberon Translator
"noch" <gnor  2005-11-01 11:45:56 
Re: Pascal to Oberon Translator
"Chris Burrows"  2005-11-02 10:07:31 
Pascal to Oberon Translator
Ulrich <whywouldyousen  2005-11-02 14:36:20 
Re: Pascal to Oberon Translator
Stewart Greenhill <nos  2005-11-04 11:48:09 
Pascal to Oberon Translator
Ulrich <whywouldyousen  2005-11-04 23:33:21 
Re: Pascal to Oberon Translator
"Chris Burrows"  2005-11-05 09:15:39 
Re: Pascal to Oberon Translator
Stewart Greenhill <nos  2005-11-05 22:01:27 
Re: Pascal to Oberon Translator
"noch" <gnor  2005-11-02 04:03:16 
Re: Pascal to Oberon Translator
jmdrake_98@[EMAIL PROTECT  2005-11-17 11:47:24 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Wed Aug 20 13:06:35 CDT 2008.