Repository navigation
perf(osgo): keep message-call scopes as values and omit empty maps - #707
Conversation
The supplied TS-HA profile spends 44% of process CPU in traced GC and 54% in the sampled allocation/GC bucket, with roughly 24,000 generated scope sites. The sXML map/scope stack union has a roughly 48-50% ceiling. These calls should not allocate records that carry no exception codes. Keep every immediate-caller masking scope, including recursive calls without EXCEPTIONS. Store its state as a session value and defer a Restore method with the previous value instead of returning a restore closure. Preserve an inactive zero state and panic unwinding. Emit nil for absent and OTHERS-only exception maps in method, native FM and lock calls. Nonempty exception maps remain allocated because active calls need their assigned codes; actual exceptions, parameter copies and persistent object/session storage keep their existing semantics and allocations. Document the five added runtime lines in the size budgets. Pin nested classic exceptions, named zero/OTHERS mappings (error_message is listed in the fixture but not exercised by it: its RAISE is caught by OTHERS -- critic round 1), class CATCH, recursive MESSAGE RAISING masking, restored caller mappings, sy-subrc, panic unwinding and session isolation. In an isolated copy, skipping an unmapped scope fails the recursive fixture; restoration passes. The JS backend's existing MESSAGE RAISING refusal remains explicitly pinned. Checks: semantics.mjs 398 ok / 0 FAIL (Go and JS); go test ./abap/...; size budget --changed origin/main exit 0; changed-file leak scan exit 0. Generated 100-call benchmark: 200 allocs/op / 8000 B/op -> 0 / 0; median 7810 -> 871.5 ns/op. Escape analysis confirms the old empty map and call record escape, while the new generated call wrapper does not. The old inlined restore closure already stayed on the stack in this fixture. Build both versions from the same read-only native input against origin/main 023b823. Both copied-kit checks equal Node: clean 0, seeded 5. Three clean --times runs each, GOGC=400 with gctrace, nice and resource gates: wall 25.03/24.12/24.32 -> 16.55/16.88/15.47 s; medians 24.32 -> 16.55 s (31.95% faster). Median traced GC CPU share 45.84% -> 13.40%; median aggregate GC CPU 16.834 -> 2.460 s; collections 22/23/22 -> 7/7/7. Shared-host measurements, not a controlled hardware regression. Keep all raw logs, fixture sources and the report outside the repo in alloc-out. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01VUy1x5QYimNEytFZpg7t7S
|
Preview: open the launchpad - the OData gateway, the demo and Zork run in your browser, no server. Screenshots - built from |
PR tests: 🟢 passCommit:
ADT lifecycle: PASSCommit: 3bca525 · SDK 8.4.3 · VSP baac6f4c97fb3ea1dee9b7772e24d52855af2985 124 PASS, 4 N/A, 3 MISSING Functional operations, active readback, cleanup and warm-swap checks determine the required gate. Timing advisory:
|
| Client/type/operation | Median ms | Samples ms | main ms (raw median) | Current/reference | main normalized median | Ratio | Main runs | Timing |
|---|---|---|---|---|---|---|---|---|
| ABAP-FS/CLAS/edit | 148 | 148, 194, 66 | 130 | 3.116 | 2.263 | 1.377x | 2 | above margin |
| ABAP-FS/CLAS/check | 1811 | 1508, 2006, 1811 | 2672 | 38.126 | 48.330 | 0.789x | 2 | quiet |
| ABAP-FS/CLAS/activate-edit | 3121 | 2590, 3121, 3273 | 4100 | 65.705 | 73.971 | 0.888x | 2 | quiet |
| ABAP-FS/CLAS/readback-active | 23 | 71, 21, 23 | 29 | 0.484 | 0.506 | 0.956x | 2 | quiet |
| ABAP-FS/INTF/edit | 72 | 62, 72, 175 | 84 | 1.516 | 1.494 | 1.015x | 2 | quiet |
| ABAP-FS/INTF/check | 1912 | 1992, 1912, 1730 | 2731 | 40.253 | 49.189 | 0.818x | 2 | quiet |
| ABAP-FS/INTF/activate-edit | 3108 | 3129, 3108, 2865 | 4171 | 65.432 | 75.253 | 0.869x | 2 | quiet |
| ABAP-FS/INTF/readback-active | 15 | 14, 15, 17 | 25 | 0.316 | 0.443 | 0.713x | 2 | quiet |
| ABAP-FS/PROG/edit | 97 | 76, 129, 97 | 127 | 2.042 | 2.267 | 0.901x | 2 | quiet |
| ABAP-FS/PROG/check | 5586 | 5664, 5586, 4572 | 5952 | 117.600 | 105.670 | 1.113x | 2 | quiet |
| ABAP-FS/PROG/activate-edit | 52490 | 52490, 52879, 44734 | 58545 | 1105.053 | 1052.429 | 1.050x | 2 | quiet |
| ABAP-FS/PROG/readback-active | 81 | 84, 81, 80 | 97 | 1.705 | 1.758 | 0.970x | 2 | quiet |
| ABAP-FS/INCL/edit | 96 | 96, 255, 75 | 108 | 2.021 | 1.942 | 1.041x | 2 | quiet |
| ABAP-FS/INCL/check | 1706 | 1481, 1756, 1706 | 2640 | 35.916 | 47.386 | 0.758x | 2 | quiet |
| ABAP-FS/INCL/activate-edit | 2904 | 3100, 2904, 2838 | 4004 | 61.137 | 72.095 | 0.848x | 2 | quiet |
| ABAP-FS/INCL/readback-active | 27 | 105, 23, 27 | 38 | 0.568 | 0.680 | 0.836x | 2 | quiet |
| ABAP-FS/DDLS/edit | 101 | 81, 110, 101 | 115 | 2.126 | 2.051 | 1.037x | 2 | quiet |
| ABAP-FS/DDLS/check | 9516 | 10269, 9516, 7858 | 9111 | 200.337 | 163.742 | 1.223x | 2 | quiet |
| ABAP-FS/DDLS/activate-edit | 51736 | 52943, 51736, 49311 | 61208 | 1089.179 | 1098.697 | 0.991x | 2 | quiet |
| ABAP-FS/DDLS/readback-active | 236 | 522, 77, 236 | 104 | 4.968 | 1.835 | 2.707x | 2 | large |
| VSP/CLAS/edit+check+activate | 4994 | 4759, 5050, 4994 | 6988 | 105.137 | 126.378 | 0.832x | 2 | quiet |
| VSP/INTF/edit+check+activate | 5329 | 5685, 5329, 4800 | 7934 | 112.189 | 144.565 | 0.776x | 2 | quiet |
| VSP/PROG/edit+check+activate | 50188 | 50152, 50188, 51035 | 62600 | 1056.589 | 1125.286 | 0.939x | 2 | quiet |
| VSP/INCL/edit+check+activate | 4941 | 4352, 5281, 4941 | 8088 | 104.021 | 145.398 | 0.715x | 2 | quiet |
| VSP/DDLS/edit+check+activate | 59553 | 59553, 58857, 61424 | 72118 | 1253.747 | 1294.436 | 0.969x | 2 | quiet |
| Client | Type | Operation | Result | ms | Note |
|---|---|---|---|---|---|
| ABAP-FS | DEVC | validate | PASS | 27 | |
| ABAP-FS | DEVC | create | PASS | 113 | |
| ABAP-FS | DEVC | edit | N/A | Package metadata update has no SDK/VSP source operation | |
| ABAP-FS | DEVC | activate | N/A | Package is created active; no source activation | |
| ABAP-FS | CLAS | validate | PASS | 14 | |
| ABAP-FS | CLAS | create | PASS | 62 | |
| ABAP-FS | CLAS | write-initial | PASS | 81 | |
| ABAP-FS | INTF | validate | PASS | 18 | |
| ABAP-FS | INTF | create | PASS | 37 | |
| ABAP-FS | INTF | write-initial | PASS | 65 | |
| ABAP-FS | PROG | validate | MISSING | 9 | /sap/bc/adt/programs/validation is not served by OSD |
| ABAP-FS | PROG | create | PASS | 48 | |
| ABAP-FS | PROG | write-initial | PASS | 69 | |
| ABAP-FS | INCL | validate | MISSING | 9 | /sap/bc/adt/includes/validation is not served by OSD |
| ABAP-FS | INCL | create | PASS | 8076 | |
| ABAP-FS | INCL | write-initial | PASS | 403 | |
| ABAP-FS | DDLS | validate | MISSING | 9 | /sap/bc/adt/ddic/ddl/validation is not served by OSD |
| ABAP-FS | DDLS | create | PASS | 41 | |
| ABAP-FS | DDLS | write-initial | PASS | 66 | |
| ABAP-FS | ALL5 | activate-initial | PASS | 44311 | |
| ABAP-FS | CLAS | edit #1 | PASS | 148 | |
| ABAP-FS | CLAS | check #1 | PASS | 1508 | |
| ABAP-FS | CLAS | activate-edit #1 | PASS | 2590 | |
| ABAP-FS | CLAS | readback-active #1 | PASS | 71 | |
| ABAP-FS | CLAS | edit #2 | PASS | 194 | |
| ABAP-FS | CLAS | check #2 | PASS | 2006 | |
| ABAP-FS | CLAS | activate-edit #2 | PASS | 3121 | |
| ABAP-FS | CLAS | readback-active #2 | PASS | 21 | |
| ABAP-FS | CLAS | edit #3 | PASS | 66 | |
| ABAP-FS | CLAS | check #3 | PASS | 1811 | |
| ABAP-FS | CLAS | activate-edit #3 | PASS | 3273 | |
| ABAP-FS | CLAS | readback-active #3 | PASS | 23 | |
| ABAP-FS | INTF | edit #1 | PASS | 62 | |
| ABAP-FS | INTF | check #1 | PASS | 1992 | |
| ABAP-FS | INTF | activate-edit #1 | PASS | 3129 | |
| ABAP-FS | INTF | readback-active #1 | PASS | 14 | |
| ABAP-FS | INTF | edit #2 | PASS | 72 | |
| ABAP-FS | INTF | check #2 | PASS | 1912 | |
| ABAP-FS | INTF | activate-edit #2 | PASS | 3108 | |
| ABAP-FS | INTF | readback-active #2 | PASS | 15 | |
| ABAP-FS | INTF | prepare-baseline | PASS | 27456 | |
| ABAP-FS | INTF | edit #3 | PASS | 175 | |
| ABAP-FS | INTF | check #3 | PASS | 1730 | |
| ABAP-FS | INTF | activate-edit #3 | PASS | 2865 | |
| ABAP-FS | INTF | readback-active #3 | PASS | 17 | |
| ABAP-FS | PROG | edit #1 | PASS | 76 | |
| ABAP-FS | PROG | check #1 | PASS | 5664 | |
| ABAP-FS | PROG | activate-edit #1 | PASS | 52490 | |
| ABAP-FS | PROG | readback-active #1 | PASS | 84 | |
| ABAP-FS | PROG | edit #2 | PASS | 129 | |
| ABAP-FS | PROG | check #2 | PASS | 5586 | |
| ABAP-FS | PROG | activate-edit #2 | PASS | 52879 | |
| ABAP-FS | PROG | readback-active #2 | PASS | 81 | |
| ABAP-FS | PROG | edit #3 | PASS | 97 | |
| ABAP-FS | PROG | check #3 | PASS | 4572 | |
| ABAP-FS | PROG | activate-edit #3 | PASS | 44734 | |
| ABAP-FS | PROG | readback-active #3 | PASS | 80 | |
| ABAP-FS | INCL | edit #1 | PASS | 96 | |
| ABAP-FS | INCL | check #1 | PASS | 1481 | |
| ABAP-FS | INCL | activate-edit #1 | PASS | 3100 | |
| ABAP-FS | INCL | readback-active #1 | PASS | 105 | |
| ABAP-FS | INCL | edit #2 | PASS | 255 | |
| ABAP-FS | INCL | check #2 | PASS | 1756 | |
| ABAP-FS | INCL | activate-edit #2 | PASS | 2904 | |
| ABAP-FS | INCL | readback-active #2 | PASS | 23 | |
| ABAP-FS | INCL | edit #3 | PASS | 75 | |
| ABAP-FS | INCL | check #3 | PASS | 1706 | |
| ABAP-FS | INCL | activate-edit #3 | PASS | 2838 | |
| ABAP-FS | INCL | readback-active #3 | PASS | 27 | |
| ABAP-FS | DDLS | edit #1 | PASS | 81 | |
| ABAP-FS | DDLS | check #1 | PASS | 10269 | |
| ABAP-FS | DDLS | activate-edit #1 | PASS | 52943 | |
| ABAP-FS | DDLS | readback-active #1 | PASS | 522 | |
| ABAP-FS | DDLS | edit #2 | PASS | 110 | |
| ABAP-FS | DDLS | check #2 | PASS | 9516 | |
| ABAP-FS | DDLS | activate-edit #2 | PASS | 51736 | |
| ABAP-FS | DDLS | readback-active #2 | PASS | 77 | |
| ABAP-FS | DDLS | edit #3 | PASS | 101 | |
| ABAP-FS | DDLS | check #3 | PASS | 7858 | |
| ABAP-FS | DDLS | activate-edit #3 | PASS | 49311 | |
| ABAP-FS | DDLS | readback-active #3 | PASS | 236 | |
| VSP | DEVC | create | PASS | 138 | |
| VSP | DEVC | edit | N/A | VSP has CreatePackage; no package metadata update tool | |
| VSP | DEVC | activate | N/A | Created active | |
| VSP | CLAS | create+write+activate | PASS | 42629 | |
| VSP | CLAS | edit+check+activate #1 | PASS | 4759 | |
| VSP | CLAS | edit+check+activate #2 | PASS | 5050 | |
| VSP | CLAS | edit+check+activate #3 | PASS | 4994 | |
| VSP | CLAS | check-explicit | PASS | 1999 | |
| VSP | CLAS | activate-explicit | PASS | 2715 | |
| VSP | CLAS | readback-vsp | PASS | 26 | |
| VSP | INTF | create+write+activate | PASS | 56834 | |
| VSP | INTF | edit+check+activate #1 | PASS | 5685 | |
| VSP | INTF | edit+check+activate #2 | PASS | 5329 | |
| VSP | INTF | edit+check+activate #3 | PASS | 4800 | |
| VSP | INTF | check-explicit | PASS | 1632 | |
| VSP | INTF | activate-explicit | PASS | 2129 | |
| VSP | INTF | readback-vsp | PASS | 26 | |
| VSP | PROG | create+write+activate | PASS | 55657 | |
| VSP | PROG | edit+check+activate #1 | PASS | 50152 | |
| VSP | PROG | edit+check+activate #2 | PASS | 50188 | |
| VSP | PROG | edit+check+activate #3 | PASS | 51035 | |
| VSP | PROG | check-explicit | PASS | 2261 | |
| VSP | PROG | activate-explicit | PASS | 25156 | |
| VSP | PROG | readback-vsp | PASS | 20 | |
| VSP | INCL | create+write+activate | PASS | 52053 | |
| VSP | INCL | edit+check+activate #1 | PASS | 4352 | |
| VSP | INCL | edit+check+activate #2 | PASS | 5281 | |
| VSP | INCL | edit+check+activate #3 | PASS | 4941 | |
| VSP | INCL | check-explicit | PASS | 2064 | |
| VSP | INCL | activate-explicit | PASS | 2164 | |
| VSP | INCL | readback-vsp | PASS | 17 | |
| VSP | DDLS | create+write+activate | PASS | 60821 | |
| VSP | DDLS | edit+check+activate #1 | PASS | 59553 | |
| VSP | DDLS | edit+check+activate #2 | PASS | 58857 | |
| VSP | DDLS | edit+check+activate #3 | PASS | 61424 | |
| VSP | DDLS | check-explicit | PASS | 4882 | |
| VSP | DDLS | activate-explicit | PASS | 24878 | |
| VSP | DDLS | readback-vsp | PASS | 21 | |
| VSP | DDLS | delete+confirmed-404 | PASS | 80 | |
| VSP | INCL | delete+confirmed-404 | PASS | 2591 | |
| VSP | PROG | delete+confirmed-404 | PASS | 55 | |
| VSP | INTF | delete+confirmed-404 | PASS | 56 | |
| VSP | CLAS | delete+confirmed-404 | PASS | 53 | |
| VSP | DEVC | delete+confirmed-404 | PASS | 57 | |
| ABAP-FS | DDLS | delete+confirmed-404 | PASS | 60 | |
| ABAP-FS | INCL | delete+confirmed-404 | PASS | 2306 | |
| ABAP-FS | PROG | delete+confirmed-404 | PASS | 59 | |
| ABAP-FS | INTF | delete+confirmed-404 | PASS | 49 | |
| ABAP-FS | CLAS | delete+confirmed-404 | PASS | 51 | |
| ABAP-FS | DEVC | delete+confirmed-404 | PASS | 48 |
Required merge checks: test + scan. ADT lifecycle timing, Docker, gogen, preview, size and queue are advisory on PRs; lifecycle functional checks remain required (Alice, 2026-10-07).
The supplied TS-HA profile spends 44% of process CPU in traced GC and
54% in the sampled allocation/GC bucket, with roughly 24,000 generated
scope sites. The sXML map/scope stack union has a roughly 48-50% ceiling.
These calls should not allocate records that carry no exception codes.
Keep every immediate-caller masking scope, including recursive calls
without EXCEPTIONS. Store its state as a session value and defer a Restore
method with the previous value instead of returning a restore closure.
Preserve an inactive zero state and panic unwinding. Emit nil for absent
and OTHERS-only exception maps in method, native FM and lock calls.
Nonempty exception maps remain allocated because active calls need their
assigned codes; actual exceptions, parameter copies and persistent
object/session storage keep their existing semantics and allocations.
Document the five added runtime lines in the size budgets.
Pin nested classic exceptions, named zero/OTHERS mappings (error_message is
listed in the fixture but not exercised by it: its RAISE is caught by
OTHERS -- critic round 1),
class CATCH, recursive MESSAGE RAISING masking, restored caller mappings,
sy-subrc, panic unwinding and session isolation. In an isolated copy,
skipping an unmapped scope fails the recursive fixture; restoration passes.
The JS backend's existing MESSAGE RAISING refusal remains explicitly pinned.
Checks: semantics.mjs 398 ok / 0 FAIL (Go and JS); go test ./abap/...;
size budget --changed origin/main exit 0; changed-file leak scan exit 0.
Generated 100-call benchmark: 200 allocs/op / 8000 B/op -> 0 / 0;
median 7810 -> 871.5 ns/op. Escape analysis confirms the old empty map
and call record escape, while the new generated call wrapper does not.
The old inlined restore closure already stayed on the stack in this fixture.
Build both versions from the same read-only native input against
origin/main 023b823. Both copied-kit checks equal Node: clean 0, seeded 5.
Three clean --times runs each, GOGC=400 with gctrace, nice and resource gates:
wall 25.03/24.12/24.32 -> 16.55/16.88/15.47 s; medians 24.32 -> 16.55 s
(31.95% faster). Median traced GC CPU share 45.84% -> 13.40%; median
aggregate GC CPU 16.834 -> 2.460 s; collections 22/23/22 -> 7/7/7.
Shared-host measurements, not a controlled hardware regression. Keep all
raw logs, fixture sources and the report outside the repo in alloc-out.
Codex worker; codex critic one round (high effort): MERGE, no runtime defect; its one note (error_message coverage overstated) is corrected in the message.
🤖 Generated with Claude Code
https://claude.ai/code/session_01VUy1x5QYimNEytFZpg7t7S