comp.lang.ada
 help / color / mirror / Atom feed
* Requesting advice from compiler writers
@ 2015-08-23 18:16 Lucretia
  2015-08-23 22:02 ` Pascal Obry
  2015-08-24 11:50 ` Brian Drummond
  0 siblings, 2 replies; 4+ messages in thread
From: Lucretia @ 2015-08-23 18:16 UTC (permalink / raw)


Hi,

I'm one of the people considering a new Ada compiler, I would like to ask the people here who have actually done it, what their advice would be. i.e. what to aim for, what to avoid doing, etc?

I personally am aiming for a library based multi-backend system. Basically, I'd like to see a full Ada compiler frontend with an Ada backend, but with the ability to poach other backends, specifically LLVM. My initial targets are unusual, Z80, MIPS and x86 (16-bit -> 64-bit) and JVM bytecode.

Let the mayhem commence... :D

Ta,
Luke.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Requesting advice from compiler writers
  2015-08-23 18:16 Requesting advice from compiler writers Lucretia
@ 2015-08-23 22:02 ` Pascal Obry
  2015-08-24 11:50 ` Brian Drummond
  1 sibling, 0 replies; 4+ messages in thread
From: Pascal Obry @ 2015-08-23 22:02 UTC (permalink / raw)


Le dimanche 23 août 2015 à 11:16 -0700, Lucretia a écrit :
> Hi,
> 
> I'm one of the people considering a new Ada compiler, I would like to 
> ask the people here who have actually done it, what their advice 
> would be. i.e. what to aim for, what to avoid doing, etc?

Find 20 volunteers to work 10 hours a day to have a chance to see the
compiler in your lifetime :)

Ok, maybe a bit exaggerated, but yet...

-- 
  Pascal Obry /  Magny Les Hameaux (78)

  The best way to travel is by means of imagination

  http://v2p.fr.eu.org
  http://www.obry.net

  gpg --keyserver keys.gnupg.net --recv-key F949BD3B

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Requesting advice from compiler writers
  2015-08-23 18:16 Requesting advice from compiler writers Lucretia
  2015-08-23 22:02 ` Pascal Obry
@ 2015-08-24 11:50 ` Brian Drummond
  2015-08-24 12:02   ` Brian Drummond
  1 sibling, 1 reply; 4+ messages in thread
From: Brian Drummond @ 2015-08-24 11:50 UTC (permalink / raw)


On Sun, 23 Aug 2015 11:16:00 -0700, Lucretia wrote:

> Hi,
> 
> I'm one of the people considering a new Ada compiler, I would like to
> ask the people here who have actually done it, what their advice would
> be. i.e. what to aim for, what to avoid doing, etc?
> 
> I personally am aiming for a library based multi-backend system.
> Basically, I'd like to see a full Ada compiler frontend with an Ada
> backend, but with the ability to poach other backends, specifically
> LLVM. My initial targets are unusual, Z80, MIPS and x86 (16-bit ->
> 64-bit) and JVM bytecode.
> 
> Let the mayhem commence... :D
> 
> Ta,
> Luke.

I've mentioned before : I'd suggest looking at Gela-Asis as the front 
end. Natasha forked it to her Github last year, ( https://github.com/
faelys/gela-asis ) and (around the same time) I saw some activity on the 
original repo (which I can't currently see at http://gela.ada-ru.org/
gela_asis ) to bring it up to date with Ada-2012.

Then I would take a good look at the ghdl project for several reasons :
https://sourceforge.net/projects/ghdl-updates/?source=navbar

it is the only example I know of, of a complex language compiler 
successfully developed by a single individual. (Tristan Gingold, who now 
works for Adacore. Before deciding to use anything from ghdl, it would be 
worth asking him if he's comfortable that there's no conflict of interest)

it supports VHDL and therefore has quite a bit in common with Ada, 
including explicit parallelism (though a different model to Ada tasking)

it is written entirely in Ada up to the intermediate representation, an 
intermediate language called "ortho" (which I believe is Tristan's own).

it has one back-end also written in Ada - this is a JIT compiler, from 
"ortho" currently limited to 32-bit x86, and actually performs quite well.

it also has backends from ortho to both gcc and LLVM, which between them 
cover a lot of targets, but are clearly not in Ada. (and some debugging 
facilities to save ortho, replay it through a backend, and to print/
examine it)


I had considered writing a layer between Gela-Asis and ortho, using the 
ghdl compiler as an example of how to generate ortho. And I'm still 
considering it...

-- Brian


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Requesting advice from compiler writers
  2015-08-24 11:50 ` Brian Drummond
@ 2015-08-24 12:02   ` Brian Drummond
  0 siblings, 0 replies; 4+ messages in thread
From: Brian Drummond @ 2015-08-24 12:02 UTC (permalink / raw)


On Mon, 24 Aug 2015 11:50:21 +0000, Brian Drummond wrote:

> On Sun, 23 Aug 2015 11:16:00 -0700, Lucretia wrote:

>> Let the mayhem commence... :D
>> 
>> Ta,
>> Luke.
> 
> I've mentioned before : I'd suggest looking at Gela-Asis as the front
> end. Natasha forked it to her Github last year, ( https://github.com/
> faelys/gela-asis ) and (around the same time) I saw some activity on the
> original repo (which I can't currently see at http://gela.ada-ru.org/
> gela_asis ) to bring it up to date with Ada-2012.

see https://www.openhub.net/p/11234

This seems to be active.

-- Brian

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-08-24 12:02 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-08-23 18:16 Requesting advice from compiler writers Lucretia
2015-08-23 22:02 ` Pascal Obry
2015-08-24 11:50 ` Brian Drummond
2015-08-24 12:02   ` Brian Drummond

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox