From: Ludovic Brenta on 10 May 2007 13:07 Jean-Pierre Rosen <rosen(a)adalog.fr> writes: > Stefan Bellon a écrit : >> Gautier wrote: >> >>> - time stamps to check need of recompilations >> >> I've always wondered about the focussing on time stamps. I think the way >> to do it would be to calculate a hash sum (md5, sha1, ...) on the token >> stream without comments. This way you wouldn't have to recompile if you >> do layout and commentary changes, and even if you touch the file, you >> don't inadvertently trigger a recompilation. >> > Gnatmake can do that (see option -m) Ah yes, I forgot... I always have -k -m in my project files... quite handy when recompiling GPS :) -- Ludovic Brenta.
From: Stefan Bellon on 10 May 2007 13:14 Ludovic Brenta wrote: > Ah yes, I forgot... I always have -k -m in my project files... quite > handy when recompiling GPS :) Ah, ok, forgot about -m. Apart form debugging information being out of sync with the actual line numbers, is it otherwise always safe to use -m? -- Stefan Bellon
From: Pascal Obry on 10 May 2007 13:34 Why not play on a C generator for the Ada language ? Using ASIS as a start. You then don't have to play with backend generation. Probably a project that is easier to tackle than a true Ada compiler even if already quite a bit of work :) That's something I wanted to start at some point, and I think now that I won't have time to start this anytime soon :) Just thinking out loud :) Pascal. -- --|------------------------------------------------------ --| Pascal Obry Team-Ada Member --| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE --|------------------------------------------------------ --| http://www.obry.net --| "The best way to travel is by means of imagination" --| --| gpg --keyserver wwwkeys.pgp.net --recv-key C1082595
From: Pascal Obry on 10 May 2007 13:36 Stefan Bellon a �crit : > Gautier wrote: > >> - time stamps to check need of recompilations > > I've always wondered about the focussing on time stamps. I think the way > to do it would be to calculate a hash sum (md5, sha1, ...) on the token > stream without comments. This way you wouldn't have to recompile if you > do layout and commentary changes, and even if you touch the file, you > don't inadvertently trigger a recompilation. That's exactly what GNAT does BTW. Pascal. -- --|------------------------------------------------------ --| Pascal Obry Team-Ada Member --| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE --|------------------------------------------------------ --| http://www.obry.net --| "The best way to travel is by means of imagination" --| --| gpg --keyserver wwwkeys.pgp.net --recv-key C1082595
From: Pascal Obry on 10 May 2007 13:37
Ludovic Brenta a �crit : > That's what GNAT does, only it uses a simple checksum for performance > reasons. Calculating the checksum and comparing it with the one in > the library (.ali files in the case of GNAT) has to be faster than > recompiling the file. No that's not a simple checksum since some time. It is now using md5. Pascal. -- --|------------------------------------------------------ --| Pascal Obry Team-Ada Member --| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE --|------------------------------------------------------ --| http://www.obry.net --| "The best way to travel is by means of imagination" --| --| gpg --keyserver wwwkeys.pgp.net --recv-key C1082595 |