In IDA I can easily change the size of the local variables using Alt+P
and then changing the "Local Variables area" field to the desired value.
However, how can I do this with the parameters size? IDA has misanalyzed the function and got the result that it has about 30 kilobytes arguments when it actually just has 30 kilobytes variables.