Solution : https://service.sap.com/sap/support/notes/1489375 (SAP Service marketplace login required)
Summary : 
      SAP Note addresses high memory usage in the ABAP stack during MDX statement execution using the Descendants/Leaves function in SAP Business Planning & Consolidation. This results from data aggregation to a higher hierarchy, despite leaf-level data requests, exacerbated by the 'QueryByMemberSet' set to 'Y'. Solutions include code optimization and importing Support Packages for various SAP NetWeaver BW versions, as detailed in related SAPBINews notes, which describe the Support Packages. Advance corrections via SNOTE are possible following guidance from Note 875986 for urgent implementations.
Key words : 
sap business planning & consolidation, descendants / leaves function preferably, sap netweaver bw 7, sap nw bw 7, high memory consumption, online analytical processing, function descendants / leaves, higher hierarchy level, bpc parameter 'querybymemberset', source code optimization
Related Notes : 
       
| 1471463 | SAPBWNews NW BW 7.01 ABAP SP08 | 
| 1468668 | SAPBWNews NW7.0 BW ABAP Support Package 25 | 
| 1450990 | SAPBWNews NW BW 7.02 ABAP SP05 | 
| 1392433 | SAPBINews NW7.11 BW ABAP Support Package 05 | 
| 1142664 | MDX: Composite SAP note about performance improvements |