Need info on GIMPLE

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello every one

I am doing some analysis on GIMPLE intermediate representation and I
have some questions.

I need to count the number of labels present in the representation
such as after optimized pass, but
I dont know why I don't encounter label statement in my switch
statement's case clause even though
there are some labels present. I am using iterators over basic blocks
and statement to determine how many
statement are there and which type.

 FOR_EACH_BB(bb)
  {
   for (gsi = gsi_start_bb (bb); !gsi_end_p (gsi); gsi_next (&gsi))
      {

	switch(gimple_code(stmt))
	  {
	    case GIMPLE_NOP:
	    printf("NOP : ");
	    break;
	  case GIMPLE_COND:
	    printf("COND_STMT / ");
	    break;
	  case GIMPLE_LABEL:
	    printf("LABEL / ");
	    break;
        }
    }
}

Other cases are being matched such as GIMPLE_COND but not
GIMPLE_LABEL. Is there anything I am missing.

Regards

Abdul


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux