Common Sub-Expression Elimination

Common Sub-Expression Elimination

Hello,

I am aware that some compilers perform CSE Elimination within an expression and within a basic block, while more sophisticated compilers can perform CSE Elimination across basic blocks also on a wide range of operators (e.g. addition, subtraction, and multiplication), data types (int and unsigned int), and storage classes (register and auto).

How do I know that Intel C++ Compiler is performing Common sub-expression elimination (CSE) with above definition?

Could anyone demonstrate with an example distinguishing how Intel C++ Compiler does CSE for a sample of code and it fails to do CSE for other sample of code? (Examples could be using any ICC FLAGS or switch case if any to demonstrate.)

I know that it would annoy some people, but something to know internally, how efficient an Intel C++ Compiler would be for CSE optimization for any code or code passes.

~BR

1 post / 0 new
For more complete information about compiler optimizations, see our Optimization Notice.