I have a complex smart contract which I want to deploy in test net (then main net).
When I deploy the contract in rinkeby using remix (enabled optimization) It only cost round 3 millions gas.
but When I use truffle to deploy it in rinkeby (also enabled optimization), It takes way more gas for that smart contract (around 5.2 millions).
I am talking about gas used to deploy contract. not gas sent by truffle.
If truffle naturally takes more gas to deploy contract, what is the reason people use it to deploy contracts?