Hi! I need some clearification concerning the responsibilities of Middle End, Back End, the generation of the control flow graph (CFG) and RTL. I looked at several articles about the internal structure of the GCC and looked at the internals documentation. However, I would like to have a second opinion about this matter.
One of my professors stated that a GCC Back End uses the Control Flow Graph as its input and that generation of RTL expressions occurs later on. What roles do Back and Middle End play in generation of RTL? Would you consider the CFG or RTL expressions as the input for a GCC Back End? I also remembered having read the following line from the gcc internals documentation. However, I'm still not sure how to interpret this: "A control flow graph (CFG) is a data structure built on top of the intermediate code representation (the RTL or tree instruction stream) abstracting the control flow behavior of a function that is being compiled" Does that mean that a control flow graph is built after rtl has been generated or that information about that information about the control flow is incorporated into the RTL data structures? Could somebody clearify this, please? Cheers, Frank