Assignment for GIMPLE Manipulation
Problem statement
- Add a pass to the GCC pass list that performs GIMPLE Manipulation for you. In the pass, do the following:
- - Count the number of local variables in a program.
- - Count the number of global variables in a program.
- - Count the number of pointer variables in a program.
Patch Provided
The patch provided implements adding an empty Interprocedural pass to GCC 4.5.0.
Hints
- Global variables will obviously be stored in a global data structure. Find the data structure that stores the linked list of global variables.
- Local variables will obviously be stored within the function that is being compiled. Which field of the function data structure holds the local variables?