Skip to content

Avoid Unnecessary Pass-by-Value for Large Tables ​

WarningPerformance & Database#EC SLOW_PARAMRemote Enabled

Overview ​

Slow Parameter Passing.

ATC Finding Message: Avoid pass-by-value for importing method parameters

Rationale ​

Passing a large internal table by VALUE makes a deep copy before the method body starts, costing memory and CPU on every call. ABAP already protects reference parameters when the method only reads them. Use pass-by-reference for large tables and reserve VALUE for small scalars that need a local copy.

Non-Compliant ​

abap
METHODS process
  IMPORTING VALUE(it_items) TYPE ty_items.

Compliant ​

abap
METHODS process
  IMPORTING it_items TYPE ty_items.

Suppression ​

To suppress findings for this rule, append the pseudo-comment to the statement:

abap
" Standard pseudo-comment:
... "#EC SLOW_PARAM

" SAP CI_ prefix format:
... "#EC CI_SLOW_PARAM

Technical Details ​

Released under the MIT License.