0

I can't determine properly whether higher price of ETH means smart contracts will also cost higher(in fiat not eth) and is it reciprocal, like if we have a SC deployed and eth price raises 10x, will execution of this SC also be 10x higher?

I know about opcodes and that each has some price in gas, I am not sure I understand is there some mechanics between that will mitigate this (maybe I dont understand clearly eth/gas relationship) or is it just 1:1?

1

The cost of executing a smart contract is measured in Gas. The units of Gas consumed during an execution is paid for using ether by multiplying units consumed with GAS_PRICE. GAS_PRICE is set in the transaction.

Suppose an execution costed 1000 units of GAS and the account that submitted the transaction had set 1 Wei as the GAS_PRICE, then the total cost of Execution is 1000 Wei. Assuming GAS_PRICE is constant, the total cost in ether will be constant. This means that if the cost of ether in terms of a fiat currency is increasing then the cost of execution in terms of that currency is also increasing.

GAS_PRICE is in reality not a constant and is market determined(demand-supply). Since we are assuming that Ether Price is going up, I also assume that the demand for submitting transactions is also moving up. In that case GAS_PRICE can go down only as a result of large number of miners who are ready to mine at cheaper GAS_PRICE joining the network. This is not a possible scenario.

Since Ethereum is a non discriminatory network with the vision of universality, there is no argument of regulating gas price. So I guess in short, if Ethereum price with respect to a currency is going up, it will be costly in that currency to execute transactions in Ethereum.

You can read more about Gas here

0

Gas system is created, because if the costs for smart contract movements were calculated straight in ethers the fee for contract creation today can cost 0.05$, but tomorrow it might be 50$, because ethers are traded on the exchange markets and the price cannot be stable any given time. With the gas system issues like your example are covered - if today we deploy contract costing us 0.1$ fee and on the next day eth price raise 10x the cost for contract deploy should be the same as yesterday. I hope this answers your question why the relationship between gas and ether is not 1:1.

  • Would like to have a bit more info. Your answer doesn't explain to me how is this solved and I would like to understand :) – Marko Blazekovic Jul 11 at 11:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.