diff --git a/libevmjit/GasMeter.cpp b/libevmjit/GasMeter.cpp index ac7f47d19..6eb8eb6eb 100644 --- a/libevmjit/GasMeter.cpp +++ b/libevmjit/GasMeter.cpp @@ -30,26 +30,26 @@ uint64_t getStepCost(Instruction inst) // TODO: Add this function to FeeSructure return 0; case Instruction::SSTORE: - return static_cast(FeeStructure::c_sstoreGas); + return static_cast(c_sstoreGas); case Instruction::SLOAD: - return static_cast(FeeStructure::c_sloadGas); + return static_cast(c_sloadGas); case Instruction::SHA3: - return static_cast(FeeStructure::c_sha3Gas); + return static_cast(c_sha3Gas); case Instruction::BALANCE: - return static_cast(FeeStructure::c_sha3Gas); + return static_cast(c_sha3Gas); case Instruction::CALL: case Instruction::CALLCODE: - return static_cast(FeeStructure::c_callGas); + return static_cast(c_callGas); case Instruction::CREATE: - return static_cast(FeeStructure::c_createGas); + return static_cast(c_createGas); default: // Assumes instruction code is valid - return static_cast(FeeStructure::c_stepGas); + return static_cast(c_stepGas); } } @@ -134,7 +134,7 @@ void GasMeter::countSStore(Ext& _ext, llvm::Value* _index, llvm::Value* _newValu { assert(!m_checkCall); // Everything should've been commited before - static const auto sstoreCost = static_cast(FeeStructure::c_sstoreGas); + static const auto sstoreCost = static_cast(c_sstoreGas); // [ADD] if oldValue == 0 and newValue != 0 => 2*cost // [DEL] if oldValue != 0 and newValue == 0 => 0 @@ -187,7 +187,7 @@ void GasMeter::commitCostBlock(llvm::Value* _additionalCost) void GasMeter::checkMemory(llvm::Value* _additionalMemoryInWords, llvm::IRBuilder<>& _builder) { // Memory uses other builder, but that can be changes later - auto cost = _builder.CreateMul(_additionalMemoryInWords, Constant::get(static_cast(FeeStructure::c_memoryGas)), "memcost"); + auto cost = _builder.CreateMul(_additionalMemoryInWords, Constant::get(static_cast(c_memoryGas)), "memcost"); _builder.CreateCall(m_gasCheckFunc, cost); }