Yes it's synthesizable but not good for timing. Use the method the previous poster suggested. You probably need to use a big case statement to include all the possible shifting values though.
Why? If you are using a variable shift factor, it should be clearly range restricted. But then, a modern design
compiler should be able to minimize the logic. I wouldn't expect different resource requirements for the high level a << n statement versus a fully decoded case construct.
Why? If you are using a variable shift factor, it should be clearly range restricted. But then, a modern design
compiler should be able to minimize the logic. I wouldn't expect different resource requirements for the high level a << n statement versus a fully decoded case construct.