I am using Altera FPGA to design some circuits. During synthesis with Quartus, I found that if I give different input signals (my input signal is a .hex file that stored a bunch of instructions), the logic elements consumption is different.
For example, if my instructions require most of modules, the logic consumption is big. However, if I make the .hex file only utilizes a certain module, the logic consumption is much less.
Is that the synthesis tool automatically optimize the module if you didn't plan to use it?
My input signals is actually store in a instruction memory, my processor executes one instruction per clock cycle. I wrote instructions in a .hex file, then in the instruction memory module, I use $readmemh("primenum.hex",Instruction_Memory);
to read instructions from .hex file.