Yes.
EIP-3529 reduced refund amounts because those amounts were exploited to create a parallel mechanism of managing GAS out of the initial EF's intents (i.e., the GasToken project, which allowed storing GAS when prices were low and using it when prices were high).
The reduction introduced by the EIP killed that technique, and now, the only reason for refunds is to incentivize people to clean the state. How? By reducing the costs of normal function calls if they do it. And that cost reduction is something you always want to apply.
So, if, for example, while executing your function, you are sure a value will never be used again (e.g., it's a nonce, OTP, or something similar), you can set it to 0 to reduce the overall cost of that function.
Without that set to 0 operation, the overall cost of your function would have been higher.
Because saving GAS while preserving the same behavior is always a good thing, removing unused entries can still be a viable technique for achieving that goal.
To be clearer, below is a code example.
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.2 <0.9.0;
contract leveraging_EIP_3529 {
mapping(uint256 => address) public list;
uint256 public counter = 0;
address public FAKE_ADDRESS = 0x1212121212121212121212121212121212121212;
event addressReadEvent(address indexed myAddress);
constructor() {
list[0] = FAKE_ADDRESS;
}
/**
* This function costs 52,572 GAS.
* If you remove the set to 0 line, the cost of this function INCREASES to 54,170 GAS.
*/
function saveNewValueAndCleanThePreviousState() public payable {
// Important: read/use the value you want to clean, or there's not gain in cleaning the state
emit addressReadEvent(list[counter]);
//Clean the state
list[counter] = 0x0000000000000000000000000000000000000000;
counter++;
list[counter] = FAKE_ADDRESS;
}
}
There is a single function that costs 52,572
GAS.
If you remove line 25 (set to 0x0), you are no longer cleaning the state, and the cost of the function increases to 54,170
GAS.
It's important to note that while the function's execution cost increases the more operations you do - it's 36,308
GAS with line 25 vs. 33,106
GAS if you remove it - cleaning the state grants you a refund at the end of the execution - 4800
GAS in this case. This refund reduces the overall transaction cost.
Here is the cost breakdown.
> Without cleaning the state:
base: 21000
calldata: + 64
execution: + 33160 <-- cheaper execution
refund: - 0 <-- no refund
total: = 54170
> Cleaning the state:
base: 21000
calldata: + 64
execution: + 36308 <-- more costly execution
refund: - 4800 <-- refund
total: = 52572 <-- overall cheaper tx