Help with workflow

2020-12-20 Thread Patrick

Hi Everyone

This is my first post here.

I need help mapping a enjoyable workflow from GnuCOBOL to GCC.

I love COBOL and with GnuCOBOL, I can compile one of my programs to 
intermediate C and then take the GnuCOBOL source code for the runtime 
and the C outputted and hop around though it using ctags.


It is great to write something in COBOL and then to see how it is 
actually implemented in the runtime in C.


I want to do the same thing with Ada.

This was my first attempt:

gcc -c -gnatDGL

but the output wasn't really that meaningful, it was basically just my 
program with no ctag links into the runtime.



I tried to create a little shell script :

gcc -c -fdump-tree-original-raw ada83_syntax.adb
gcc -c -fdump-tree-gimple-raw ada83_syntax.adb
gcc -c -fdump-tree-cfg-raw  ada83_syntax.adb

ctags ../*.[ch] ../ada/* *.original *.gimple *.cfg
gvim ../*.[ch] ../ada/* *.original *.gimple *.cfg tags

I was hoping that I would catch the top level C code and that it would 
help. It didn't seem to.


Could anyone help with what I am trying to do?

Thanks for reading-Pat




Re: Help with workflow

2020-12-20 Thread Arnaud Charlet
Pat,

Not sure what you are trying to do . Are you trying to generate C code
from Ada? If so, can you clarify why? In other words, what is the high level
problem you are trying to solve and that you'd like to achieve? Is it the
ability to navigate in Ada code?

If you want to generate C from Ada, GCC isn't the right tool, since GCC
doesn't generate C code, it generates an intermediate representation which
is then translated into assembly code directly, without ever generating C code.

Arno


GSoC 2021 project help

2020-12-20 Thread Adharsh Kamath via Gcc
Hi everyone
I came across the list of project ideas that were selected for GSoC 2020
and I'm interested in contributing to the project regarding the *Implementation
of OMPD in GCC, libgomp, and GDB. *
I was able to build GCC from source, as specified in the *Before you apply*
section.
Is this project going to be considered for GSoC 2021 as well?
How can I get started with this project? Can I contact the mentor who is
mentioned in the above project's description regarding this?

Thanks,
Adharsh


Re: Help with workflow

2020-12-20 Thread Patrick

On 2020-12-20 7:24 a.m., Arnaud Charlet wrote:

Pat,

Not sure what you are trying to do . Are you trying to generate C code
from Ada? If so, can you clarify why? In other words, what is the high level
problem you are trying to solve and that you'd like to achieve? Is it the
ability to navigate in Ada code?

If you want to generate C from Ada, GCC isn't the right tool, since GCC
doesn't generate C code, it generates an intermediate representation which
is then translated into assembly code directly, without ever generating C code.

Arno


Hi Arnaud

Thanks for responding to my post. I am not trying to generate C but to 
follow the intermediate representation into the Ada runtime.


So let's just say we had this:

*with*  Ada.Text_IO;
*use*   Ada.Text_IO;
*procedure*  Do_Delays*is*
*begin*
  Put_Line("Wait 5 seconds.");
  *delay*  5.0;
  Put_Line("Wait 2 seconds.");
  *delay*  2.0;
  Put_Line("Wait 7 seconds.");
  *delay*  7.0;
  Put_Line("That's all folks.");
*end*  Do_Delays;

I want to follow "delay" through the intermediate representation into the Ada 
runtime to see where the code actually causes a pause state to occur.

I can do this with GnuCOBOL because it compiles to C but that is not the case 
here and I can't seem to figure out how to follow the code as it is being 
translated through it's various stages and into the runtime.

Thanks again-Pat



Re: Help with workflow

2020-12-20 Thread Arnaud Charlet


> Thanks for responding to my post. I am not trying to generate C but to follow 
> the intermediate representation into the Ada runtime.
> 
> So let's just say we had this:
> 
> with Ada.Text_IO;
> use  Ada.Text_IO;
> procedure Do_Delays is
> begin
>   Put_Line("Wait 5 seconds.");
>   delay 5.0;
>   Put_Line("Wait 2 seconds.");
>   delay 2.0;
>   Put_Line("Wait 7 seconds.");
>   delay 7.0;
>   Put_Line("That's all folks."); 
> end Do_Delays;
> 
> I want to follow "delay" through the intermediate representation into the Ada 
> runtime to see where the code actually causes a pause state to occur.

Ok so you should indeed use -gnatDL and you will see these runtime calls 
materialize. The syntax of the .dg files is documented in gcc/ada/sprint.ads
> 
> I can do this with GnuCOBOL because it compiles to C but that is not the case 
> here and I can't seem to figure out how to follow the code as it is being 
> translated through it's various stages and into the runtime.
> 
> Thanks again-Pat


gcc-11-20201220 is now available

2020-12-20 Thread GCC Administrator via Gcc
Snapshot gcc-11-20201220 is now available on
  https://gcc.gnu.org/pub/gcc/snapshots/11-20201220/
and on various mirrors, see http://gcc.gnu.org/mirrors.html for details.

This snapshot has been generated from the GCC 11 git branch
with the following options: git://gcc.gnu.org/git/gcc.git branch master 
revision 18e86fae2a14f78e70aae06afce6bb9853068bb1

You'll find:

 gcc-11-20201220.tar.xz   Complete GCC

  SHA256=d733cb587560b6220410a43ed44eeb184f00a8ab925a365d55a2ee443166aa2f
  SHA1=0e5ff38831aaba9b55572d6060af43685cb70476

Diffs from 11-20201213 are available in the diffs/ subdirectory.

When a particular snapshot is ready for public consumption the LATEST-11
link is updated and a message is sent to the gcc list.  Please do not use
a snapshot before it has been announced that way.