Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove explicit capture of fields #7282

Merged
merged 2 commits into from
Jul 9, 2024
Merged

Conversation

jpbempel
Copy link
Member

@jpbempel jpbempel commented Jul 5, 2024

What Does This Do

Previously we were capturing directly fields of the current class in a specific way and use them for condition evaluation, while this was captured as argument. Now we only capture this and all evaluations are based on implicit this dereferencing when needed. NB: Serialization of complex classes no longer capture static fields

Motivation

Remove useless captures & performance

Additional Notes

Jira ticket: DEBUG-2399

@jpbempel jpbempel requested a review from a team as a code owner July 5, 2024 09:15
@jpbempel jpbempel requested review from shatzi and removed request for a team July 5, 2024 09:15
@jpbempel jpbempel added the comp: debugger Dynamic Instrumentation label Jul 5, 2024
@jpbempel jpbempel force-pushed the jpbempel/drop-field-capture branch from 0657df9 to 7058cbb Compare July 5, 2024 09:16
@jpbempel jpbempel changed the title Remove explicit capture fo fields Remove explicit capture of fields Jul 5, 2024
@jpbempel jpbempel force-pushed the jpbempel/drop-field-capture branch from 7058cbb to c7b8be2 Compare July 5, 2024 09:42
Previously we were capturing directly fields of the current class in
a specific way and use them for condition evaluation, while this
was captured as argument. Now we only capture this and all evaluations
are based on implicit this dereferencing when needed.
NB: Serialization of complex classes no longer capture static fields
@jpbempel jpbempel force-pushed the jpbempel/drop-field-capture branch from c7b8be2 to 8712cc2 Compare July 5, 2024 15:42
@pr-commenter
Copy link

pr-commenter bot commented Jul 5, 2024

Debugger benchmarks

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
ci_job_date 1720507077 1720507474
end_time 2024-07-09T06:39:11 2024-07-09T06:45:48
git_branch master jpbempel/drop-field-capture
git_commit_sha 5a09529 32bad46
start_time 2024-07-09T06:37:58 2024-07-09T06:44:35
See matching parameters
Baseline Candidate
ci_job_id 566073405 566073405
ci_pipeline_id 38668222 38668222
cpu_model Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
git_commit_date 1720506391 1720506391

Summary

Found 5 performance improvements and 0 performance regressions! Performance is the same for 2 metrics, 8 unstable metrics.

scenario Δ mean agg_http_req_duration_min Δ mean agg_http_req_duration_p50 Δ mean agg_http_req_duration_p75 Δ mean agg_http_req_duration_p99 Δ mean throughput
scenario:loop better
[-482.699µs; -466.491µs] or [-4.290%; -4.146%]
better
[-534.402µs; -447.631µs] or [-4.679%; -3.919%]
better
[-528.936µs; -400.414µs] or [-4.602%; -3.484%]
better
[-861.397µs; -354.201µs] or [-7.182%; -2.953%]
better
[+2.334op/s; +4.686op/s] or [+2.696%; +5.412%]
See unchanged results
scenario Δ mean agg_http_req_duration_min Δ mean agg_http_req_duration_p50 Δ mean agg_http_req_duration_p75 Δ mean agg_http_req_duration_p99 Δ mean throughput
scenario:noprobe unstable
[-40.250µs; +36.288µs] or [-15.122%; +13.633%]
unstable
[-55.977µs; +48.341µs] or [-18.455%; +15.938%]
unstable
[-69.167µs; +61.744µs] or [-21.751%; +19.417%]
unstable
[-134.554µs; +104.001µs] or [-20.168%; +15.589%]
unstable
[-147.446op/s; +147.419op/s] or [-5.456%; +5.455%]
scenario:basic same same unstable
[-15723.819ns; +16646.716ns] or [-5.103%; +5.403%]
unstable
[-56.370µs; +48.470µs] or [-9.518%; +8.184%]
unstable
[-226.183op/s; +226.183op/s] or [-8.821%; +8.821%]
Request duration reports for reports
gantt
    title reports - request duration [CI 0.99] : candidate=None, baseline=None
    dateFormat X
    axisFormat %s
section baseline
noprobe (303.308 µs) : 255, 352
.   : milestone, 303,
basic (298.371 µs) : 286, 310
.   : milestone, 298,
loop (11.421 ms) : 11372, 11470
.   : milestone, 11421,
section candidate
noprobe (299.49 µs) : 248, 351
.   : milestone, 299,
basic (298.073 µs) : 285, 312
.   : milestone, 298,
loop (10.93 ms) : 10901, 10960
.   : milestone, 10930,
Loading
  • baseline results
Scenario Request median duration [CI 0.99]
noprobe 303.308 µs [254.963 µs, 351.653 µs]
basic 298.371 µs [286.273 µs, 310.469 µs]
loop 11.421 ms [11.372 ms, 11.47 ms]
  • candidate results
Scenario Request median duration [CI 0.99]
noprobe 299.49 µs [248.335 µs, 350.646 µs]
basic 298.073 µs [284.556 µs, 311.59 µs]
loop 10.93 ms [10.901 ms, 10.96 ms]

@pr-commenter
Copy link

pr-commenter bot commented Jul 5, 2024

Benchmarks

Startup

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master jpbempel/drop-field-capture
git_commit_date 1720468706 1720506391
git_commit_sha 5a09529 32bad46
release_version 1.38.0-SNAPSHOT~5a09529999 1.38.0-SNAPSHOT~32bad461e7
See matching parameters
Baseline Candidate
application insecure-bank insecure-bank
ci_job_date 1720508892 1720508892
ci_job_id 566073399 566073399
ci_pipeline_id 38668222 38668222
cpu_model Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
module Agent Agent
parent None None
variant iast iast

Summary

Found 0 performance improvements and 0 performance regressions! Performance is the same for 52 metrics, 11 unstable metrics.

Startup time reports for insecure-bank
gantt
    title insecure-bank - global startup overhead: candidate=1.38.0-SNAPSHOT~32bad461e7, baseline=1.38.0-SNAPSHOT~5a09529999

    dateFormat X
    axisFormat %s
section tracing
Agent [baseline] (1.063 s) : 0, 1062750
Total [baseline] (8.504 s) : 0, 8503653
Agent [candidate] (1.065 s) : 0, 1064732
Total [candidate] (8.512 s) : 0, 8512257
section iast
Agent [baseline] (1.179 s) : 0, 1178758
Total [baseline] (8.949 s) : 0, 8949280
Agent [candidate] (1.18 s) : 0, 1180161
Total [candidate] (8.97 s) : 0, 8969635
section iast_HARDCODED_SECRET_DISABLED
Agent [baseline] (1.172 s) : 0, 1172091
Total [baseline] (8.926 s) : 0, 8925530
Agent [candidate] (1.178 s) : 0, 1177518
Total [candidate] (8.94 s) : 0, 8940119
section iast_TELEMETRY_OFF
Agent [baseline] (1.165 s) : 0, 1164872
Total [baseline] (8.918 s) : 0, 8917765
Agent [candidate] (1.164 s) : 0, 1164394
Total [candidate] (8.978 s) : 0, 8977991
Loading
  • baseline results
Module Variant Duration Δ tracing
Agent tracing 1.063 s -
Agent iast 1.179 s 116.009 ms (10.9%)
Agent iast_HARDCODED_SECRET_DISABLED 1.172 s 109.342 ms (10.3%)
Agent iast_TELEMETRY_OFF 1.165 s 102.123 ms (9.6%)
Total tracing 8.504 s -
Total iast 8.949 s 445.627 ms (5.2%)
Total iast_HARDCODED_SECRET_DISABLED 8.926 s 421.877 ms (5.0%)
Total iast_TELEMETRY_OFF 8.918 s 414.112 ms (4.9%)
  • candidate results
Module Variant Duration Δ tracing
Agent tracing 1.065 s -
Agent iast 1.18 s 115.429 ms (10.8%)
Agent iast_HARDCODED_SECRET_DISABLED 1.178 s 112.785 ms (10.6%)
Agent iast_TELEMETRY_OFF 1.164 s 99.662 ms (9.4%)
Total tracing 8.512 s -
Total iast 8.97 s 457.377 ms (5.4%)
Total iast_HARDCODED_SECRET_DISABLED 8.94 s 427.862 ms (5.0%)
Total iast_TELEMETRY_OFF 8.978 s 465.734 ms (5.5%)
gantt
    title insecure-bank - break down per module: candidate=1.38.0-SNAPSHOT~32bad461e7, baseline=1.38.0-SNAPSHOT~5a09529999

    dateFormat X
    axisFormat %s
section tracing
BytebuddyAgent [baseline] (665.339 ms) : 0, 665339
BytebuddyAgent [candidate] (665.963 ms) : 0, 665963
GlobalTracer [baseline] (304.579 ms) : 0, 304579
GlobalTracer [candidate] (305.703 ms) : 0, 305703
AppSec [baseline] (49.935 ms) : 0, 49935
AppSec [candidate] (50.124 ms) : 0, 50124
Remote Config [baseline] (671.577 µs) : 0, 672
Remote Config [candidate] (673.219 µs) : 0, 673
Telemetry [baseline] (7.64 ms) : 0, 7640
Telemetry [candidate] (7.667 ms) : 0, 7667
section iast
BytebuddyAgent [baseline] (785.777 ms) : 0, 785777
BytebuddyAgent [candidate] (786.365 ms) : 0, 786365
GlobalTracer [baseline] (297.858 ms) : 0, 297858
GlobalTracer [candidate] (297.832 ms) : 0, 297832
AppSec [baseline] (47.259 ms) : 0, 47259
AppSec [candidate] (47.929 ms) : 0, 47929
IAST [baseline] (26.762 ms) : 0, 26762
IAST [candidate] (26.867 ms) : 0, 26867
Remote Config [baseline] (564.988 µs) : 0, 565
Remote Config [candidate] (562.487 µs) : 0, 562
Telemetry [baseline] (6.992 ms) : 0, 6992
Telemetry [candidate] (7.0 ms) : 0, 7000
section iast_HARDCODED_SECRET_DISABLED
BytebuddyAgent [baseline] (779.282 ms) : 0, 779282
BytebuddyAgent [candidate] (784.724 ms) : 0, 784724
GlobalTracer [baseline] (295.585 ms) : 0, 295585
GlobalTracer [candidate] (296.58 ms) : 0, 296580
AppSec [baseline] (47.432 ms) : 0, 47432
AppSec [candidate] (47.613 ms) : 0, 47613
IAST [baseline] (27.886 ms) : 0, 27886
IAST [candidate] (26.56 ms) : 0, 26560
Remote Config [baseline] (579.713 µs) : 0, 580
Remote Config [candidate] (590.808 µs) : 0, 591
Telemetry [baseline] (7.8 ms) : 0, 7800
Telemetry [candidate] (7.873 ms) : 0, 7873
section iast_TELEMETRY_OFF
BytebuddyAgent [baseline] (774.882 ms) : 0, 774882
BytebuddyAgent [candidate] (775.492 ms) : 0, 775492
GlobalTracer [baseline] (294.218 ms) : 0, 294218
GlobalTracer [candidate] (294.715 ms) : 0, 294715
AppSec [baseline] (47.157 ms) : 0, 47157
AppSec [candidate] (46.634 ms) : 0, 46634
IAST [baseline] (27.735 ms) : 0, 27735
IAST [candidate] (25.861 ms) : 0, 25861
Remote Config [baseline] (585.78 µs) : 0, 586
Remote Config [candidate] (589.414 µs) : 0, 589
Telemetry [baseline] (6.791 ms) : 0, 6791
Telemetry [candidate] (7.598 ms) : 0, 7598
Loading
Startup time reports for petclinic
gantt
    title petclinic - global startup overhead: candidate=1.38.0-SNAPSHOT~32bad461e7, baseline=1.38.0-SNAPSHOT~5a09529999

    dateFormat X
    axisFormat %s
section tracing
Agent [baseline] (1.065 s) : 0, 1064624
Total [baseline] (10.288 s) : 0, 10288442
Agent [candidate] (1.063 s) : 0, 1062851
Total [candidate] (10.321 s) : 0, 10320806
section appsec
Agent [baseline] (1.184 s) : 0, 1183723
Total [baseline] (10.533 s) : 0, 10532576
Agent [candidate] (1.192 s) : 0, 1191798
Total [candidate] (10.493 s) : 0, 10492546
section iast
Agent [baseline] (1.17 s) : 0, 1169692
Total [baseline] (10.696 s) : 0, 10695804
Agent [candidate] (1.18 s) : 0, 1179539
Total [candidate] (10.78 s) : 0, 10780180
section profiling
Agent [baseline] (1.275 s) : 0, 1275281
Total [baseline] (10.638 s) : 0, 10637970
Agent [candidate] (1.265 s) : 0, 1264841
Total [candidate] (10.626 s) : 0, 10625867
Loading
  • baseline results
Module Variant Duration Δ tracing
Agent tracing 1.065 s -
Agent appsec 1.184 s 119.099 ms (11.2%)
Agent iast 1.17 s 105.068 ms (9.9%)
Agent profiling 1.275 s 210.657 ms (19.8%)
Total tracing 10.288 s -
Total appsec 10.533 s 244.133 ms (2.4%)
Total iast 10.696 s 407.361 ms (4.0%)
Total profiling 10.638 s 349.528 ms (3.4%)
  • candidate results
Module Variant Duration Δ tracing
Agent tracing 1.063 s -
Agent appsec 1.192 s 128.948 ms (12.1%)
Agent iast 1.18 s 116.688 ms (11.0%)
Agent profiling 1.265 s 201.99 ms (19.0%)
Total tracing 10.321 s -
Total appsec 10.493 s 171.74 ms (1.7%)
Total iast 10.78 s 459.374 ms (4.5%)
Total profiling 10.626 s 305.061 ms (3.0%)
gantt
    title petclinic - break down per module: candidate=1.38.0-SNAPSHOT~32bad461e7, baseline=1.38.0-SNAPSHOT~5a09529999

    dateFormat X
    axisFormat %s
section tracing
BytebuddyAgent [baseline] (665.825 ms) : 0, 665825
BytebuddyAgent [candidate] (664.632 ms) : 0, 664632
GlobalTracer [baseline] (305.487 ms) : 0, 305487
GlobalTracer [candidate] (305.353 ms) : 0, 305353
AppSec [baseline] (50.262 ms) : 0, 50262
AppSec [candidate] (50.023 ms) : 0, 50023
Remote Config [baseline] (681.181 µs) : 0, 681
Remote Config [candidate] (663.563 µs) : 0, 664
Telemetry [baseline] (7.684 ms) : 0, 7684
Telemetry [candidate] (7.632 ms) : 0, 7632
section appsec
BytebuddyAgent [baseline] (676.304 ms) : 0, 676304
BytebuddyAgent [candidate] (682.253 ms) : 0, 682253
GlobalTracer [baseline] (298.321 ms) : 0, 298321
GlobalTracer [candidate] (300.449 ms) : 0, 300449
AppSec [baseline] (153.692 ms) : 0, 153692
AppSec [candidate] (154.095 ms) : 0, 154095
IAST [baseline] (20.902 ms) : 0, 20902
IAST [candidate] (20.321 ms) : 0, 20321
Remote Config [baseline] (623.991 µs) : 0, 624
Remote Config [candidate] (627.988 µs) : 0, 628
Telemetry [baseline] (9.605 ms) : 0, 9605
Telemetry [candidate] (9.215 ms) : 0, 9215
section iast
BytebuddyAgent [baseline] (779.518 ms) : 0, 779518
BytebuddyAgent [candidate] (784.539 ms) : 0, 784539
GlobalTracer [baseline] (295.502 ms) : 0, 295502
GlobalTracer [candidate] (297.07 ms) : 0, 297070
AppSec [baseline] (47.171 ms) : 0, 47171
AppSec [candidate] (47.564 ms) : 0, 47564
IAST [baseline] (25.675 ms) : 0, 25675
IAST [candidate] (28.42 ms) : 0, 28420
Remote Config [baseline] (571.71 µs) : 0, 572
Remote Config [candidate] (573.998 µs) : 0, 574
Telemetry [baseline] (7.778 ms) : 0, 7778
Telemetry [candidate] (7.771 ms) : 0, 7771
section profiling
BytebuddyAgent [baseline] (669.059 ms) : 0, 669059
BytebuddyAgent [candidate] (662.545 ms) : 0, 662545
GlobalTracer [baseline] (391.754 ms) : 0, 391754
GlobalTracer [candidate] (389.176 ms) : 0, 389176
AppSec [baseline] (52.085 ms) : 0, 52085
AppSec [candidate] (51.864 ms) : 0, 51864
Remote Config [baseline] (650.664 µs) : 0, 651
Remote Config [candidate] (663.699 µs) : 0, 664
Telemetry [baseline] (7.429 ms) : 0, 7429
Telemetry [candidate] (7.32 ms) : 0, 7320
ProfilingAgent [baseline] (96.564 ms) : 0, 96564
ProfilingAgent [candidate] (96.109 ms) : 0, 96109
Profiling [baseline] (96.589 ms) : 0, 96589
Profiling [candidate] (96.134 ms) : 0, 96134
Loading

Load

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
end_time 2024-07-09T06:39:04 2024-07-09T06:45:51
git_branch master jpbempel/drop-field-capture
git_commit_date 1720468706 1720506391
git_commit_sha 5a09529 32bad46
release_version 1.38.0-SNAPSHOT~5a09529999 1.38.0-SNAPSHOT~32bad461e7
start_time 2024-07-09T06:38:51 2024-07-09T06:45:38
See matching parameters
Baseline Candidate
application insecure-bank insecure-bank
ci_job_date 1720507894 1720507894
ci_job_id 566073400 566073400
ci_pipeline_id 38668222 38668222
cpu_model Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
variant iast iast

Summary

Found 0 performance improvements and 0 performance regressions! Performance is the same for 11 metrics, 17 unstable metrics.

Request duration reports for petclinic
gantt
    title petclinic - request duration [CI 0.99] : candidate=1.38.0-SNAPSHOT~32bad461e7, baseline=1.38.0-SNAPSHOT~5a09529999
    dateFormat X
    axisFormat %s
section baseline
no_agent (1.327 ms) : 1307, 1347
.   : milestone, 1327,
appsec (1.689 ms) : 1665, 1714
.   : milestone, 1689,
appsec_no_iast (1.705 ms) : 1681, 1729
.   : milestone, 1705,
iast (1.475 ms) : 1453, 1498
.   : milestone, 1475,
profiling (1.501 ms) : 1476, 1527
.   : milestone, 1501,
tracing (1.482 ms) : 1458, 1506
.   : milestone, 1482,
section candidate
no_agent (1.35 ms) : 1331, 1369
.   : milestone, 1350,
appsec (1.73 ms) : 1706, 1753
.   : milestone, 1730,
appsec_no_iast (1.713 ms) : 1690, 1736
.   : milestone, 1713,
iast (1.472 ms) : 1449, 1495
.   : milestone, 1472,
profiling (1.488 ms) : 1464, 1513
.   : milestone, 1488,
tracing (1.443 ms) : 1419, 1467
.   : milestone, 1443,
Loading
  • baseline results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 1.327 ms [1.307 ms, 1.347 ms] -
appsec 1.689 ms [1.665 ms, 1.714 ms] 362.381 µs (27.3%)
appsec_no_iast 1.705 ms [1.681 ms, 1.729 ms] 377.917 µs (28.5%)
iast 1.475 ms [1.453 ms, 1.498 ms] 148.539 µs (11.2%)
profiling 1.501 ms [1.476 ms, 1.527 ms] 174.337 µs (13.1%)
tracing 1.482 ms [1.458 ms, 1.506 ms] 155.182 µs (11.7%)
  • candidate results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 1.35 ms [1.331 ms, 1.369 ms] -
appsec 1.73 ms [1.706 ms, 1.753 ms] 379.669 µs (28.1%)
appsec_no_iast 1.713 ms [1.69 ms, 1.736 ms] 363.054 µs (26.9%)
iast 1.472 ms [1.449 ms, 1.495 ms] 122.068 µs (9.0%)
profiling 1.488 ms [1.464 ms, 1.513 ms] 138.367 µs (10.2%)
tracing 1.443 ms [1.419 ms, 1.467 ms] 92.958 µs (6.9%)
Request duration reports for insecure-bank
gantt
    title insecure-bank - request duration [CI 0.99] : candidate=1.38.0-SNAPSHOT~32bad461e7, baseline=1.38.0-SNAPSHOT~5a09529999
    dateFormat X
    axisFormat %s
section baseline
no_agent (366.555 µs) : 347, 386
.   : milestone, 367,
iast (473.432 µs) : 453, 494
.   : milestone, 473,
iast_FULL (545.55 µs) : 524, 567
.   : milestone, 546,
iast_GLOBAL (505.512 µs) : 483, 528
.   : milestone, 506,
iast_HARDCODED_SECRET_DISABLED (478.39 µs) : 456, 500
.   : milestone, 478,
iast_INACTIVE (449.742 µs) : 427, 472
.   : milestone, 450,
iast_TELEMETRY_OFF (468.183 µs) : 447, 490
.   : milestone, 468,
tracing (438.444 µs) : 418, 459
.   : milestone, 438,
section candidate
no_agent (367.746 µs) : 347, 389
.   : milestone, 368,
iast (476.575 µs) : 455, 498
.   : milestone, 477,
iast_FULL (541.098 µs) : 520, 562
.   : milestone, 541,
iast_GLOBAL (507.118 µs) : 485, 529
.   : milestone, 507,
iast_HARDCODED_SECRET_DISABLED (472.553 µs) : 451, 494
.   : milestone, 473,
iast_INACTIVE (448.897 µs) : 427, 470
.   : milestone, 449,
iast_TELEMETRY_OFF (468.47 µs) : 447, 490
.   : milestone, 468,
tracing (435.664 µs) : 415, 456
.   : milestone, 436,
Loading
  • baseline results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 366.555 µs [347.334 µs, 385.775 µs] -
iast 473.432 µs [452.632 µs, 494.232 µs] 106.877 µs (29.2%)
iast_FULL 545.55 µs [524.396 µs, 566.705 µs] 178.996 µs (48.8%)
iast_GLOBAL 505.512 µs [483.438 µs, 527.585 µs] 138.957 µs (37.9%)
iast_HARDCODED_SECRET_DISABLED 478.39 µs [456.401 µs, 500.378 µs] 111.835 µs (30.5%)
iast_INACTIVE 449.742 µs [427.448 µs, 472.035 µs] 83.187 µs (22.7%)
iast_TELEMETRY_OFF 468.183 µs [446.638 µs, 489.728 µs] 101.629 µs (27.7%)
tracing 438.444 µs [417.745 µs, 459.144 µs] 71.89 µs (19.6%)
  • candidate results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 367.746 µs [346.726 µs, 388.765 µs] -
iast 476.575 µs [455.175 µs, 497.974 µs] 108.829 µs (29.6%)
iast_FULL 541.098 µs [520.38 µs, 561.816 µs] 173.352 µs (47.1%)
iast_GLOBAL 507.118 µs [485.181 µs, 529.056 µs] 139.373 µs (37.9%)
iast_HARDCODED_SECRET_DISABLED 472.553 µs [451.31 µs, 493.796 µs] 104.807 µs (28.5%)
iast_INACTIVE 448.897 µs [427.447 µs, 470.346 µs] 81.151 µs (22.1%)
iast_TELEMETRY_OFF 468.47 µs [446.962 µs, 489.979 µs] 100.725 µs (27.4%)
tracing 435.664 µs [415.078 µs, 456.25 µs] 67.918 µs (18.5%)

Dacapo

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master jpbempel/drop-field-capture
git_commit_date 1720468706 1720506391
git_commit_sha 5a09529 32bad46
release_version 1.38.0-SNAPSHOT~5a09529999 1.38.0-SNAPSHOT~32bad461e7
See matching parameters
Baseline Candidate
application biojava biojava
ci_job_date 1720508420 1720508420
ci_job_id 566073401 566073401
ci_pipeline_id 38668222 38668222
cpu_model Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
variant appsec appsec

Summary

Found 0 performance improvements and 0 performance regressions! Performance is the same for 12 metrics, 0 unstable metrics.

Execution time for tomcat
gantt
    title tomcat - execution time [CI 0.99] : candidate=1.38.0-SNAPSHOT~32bad461e7, baseline=1.38.0-SNAPSHOT~5a09529999
    dateFormat X
    axisFormat %s
section baseline
no_agent (1.455 ms) : 1444, 1466
.   : milestone, 1455,
appsec (2.212 ms) : 2177, 2247
.   : milestone, 2212,
iast (1.961 ms) : 1920, 2002
.   : milestone, 1961,
iast_GLOBAL (2.006 ms) : 1965, 2047
.   : milestone, 2006,
profiling (1.846 ms) : 1813, 1880
.   : milestone, 1846,
tracing (1.838 ms) : 1805, 1871
.   : milestone, 1838,
section candidate
no_agent (1.452 ms) : 1441, 1463
.   : milestone, 1452,
appsec (2.203 ms) : 2168, 2237
.   : milestone, 2203,
iast (1.956 ms) : 1915, 1997
.   : milestone, 1956,
iast_GLOBAL (2.002 ms) : 1960, 2045
.   : milestone, 2002,
profiling (1.858 ms) : 1822, 1893
.   : milestone, 1858,
tracing (1.83 ms) : 1798, 1863
.   : milestone, 1830,
Loading
  • baseline results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 1.455 ms [1.444 ms, 1.466 ms] -
appsec 2.212 ms [2.177 ms, 2.247 ms] 757.352 µs (52.0%)
iast 1.961 ms [1.92 ms, 2.002 ms] 505.602 µs (34.7%)
iast_GLOBAL 2.006 ms [1.965 ms, 2.047 ms] 550.933 µs (37.9%)
profiling 1.846 ms [1.813 ms, 1.88 ms] 391.267 µs (26.9%)
tracing 1.838 ms [1.805 ms, 1.871 ms] 383.041 µs (26.3%)
  • candidate results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 1.452 ms [1.441 ms, 1.463 ms] -
appsec 2.203 ms [2.168 ms, 2.237 ms] 750.637 µs (51.7%)
iast 1.956 ms [1.915 ms, 1.997 ms] 503.729 µs (34.7%)
iast_GLOBAL 2.002 ms [1.96 ms, 2.045 ms] 550.272 µs (37.9%)
profiling 1.858 ms [1.822 ms, 1.893 ms] 405.534 µs (27.9%)
tracing 1.83 ms [1.798 ms, 1.863 ms] 378.071 µs (26.0%)
Execution time for biojava
gantt
    title biojava - execution time [CI 0.99] : candidate=1.38.0-SNAPSHOT~32bad461e7, baseline=1.38.0-SNAPSHOT~5a09529999
    dateFormat X
    axisFormat %s
section baseline
no_agent (14.991 s) : 14991000, 14991000
.   : milestone, 14991000,
appsec (15.143 s) : 15143000, 15143000
.   : milestone, 15143000,
iast (18.694 s) : 18694000, 18694000
.   : milestone, 18694000,
iast_GLOBAL (17.638 s) : 17638000, 17638000
.   : milestone, 17638000,
profiling (15.497 s) : 15497000, 15497000
.   : milestone, 15497000,
tracing (15.022 s) : 15022000, 15022000
.   : milestone, 15022000,
section candidate
no_agent (15.065 s) : 15065000, 15065000
.   : milestone, 15065000,
appsec (15.083 s) : 15083000, 15083000
.   : milestone, 15083000,
iast (18.672 s) : 18672000, 18672000
.   : milestone, 18672000,
iast_GLOBAL (17.848 s) : 17848000, 17848000
.   : milestone, 17848000,
profiling (15.877 s) : 15877000, 15877000
.   : milestone, 15877000,
tracing (15.091 s) : 15091000, 15091000
.   : milestone, 15091000,
Loading
  • baseline results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 14.991 s [14.991 s, 14.991 s] -
appsec 15.143 s [15.143 s, 15.143 s] 152.0 ms (1.0%)
iast 18.694 s [18.694 s, 18.694 s] 3.703 s (24.7%)
iast_GLOBAL 17.638 s [17.638 s, 17.638 s] 2.647 s (17.7%)
profiling 15.497 s [15.497 s, 15.497 s] 506.0 ms (3.4%)
tracing 15.022 s [15.022 s, 15.022 s] 31.0 ms (0.2%)
  • candidate results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 15.065 s [15.065 s, 15.065 s] -
appsec 15.083 s [15.083 s, 15.083 s] 18.0 ms (0.1%)
iast 18.672 s [18.672 s, 18.672 s] 3.607 s (23.9%)
iast_GLOBAL 17.848 s [17.848 s, 17.848 s] 2.783 s (18.5%)
profiling 15.877 s [15.877 s, 15.877 s] 812.0 ms (5.4%)
tracing 15.091 s [15.091 s, 15.091 s] 26.0 ms (0.2%)

@@ -377,8 +357,8 @@ public String toString() {
+ locals
+ ", throwable="
+ throwable
+ ", fields="
+ fields
+ ", staticFields="
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good catch

import java.util.*;

public class RefResolverHelper {

public static ValueReferenceResolver createResolver(Object instance) {
/*
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove comment?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

strList.add("foo");
}
}
ValueReferenceResolver ctx =
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why not use createResolver(new Object)? - as it seems to do the same thing...

public static ValueReferenceResolver createResolver(Object instance) { ... }

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • true!

@@ -857,7 +857,7 @@ private void collectStaticFields(InsnList insnList) {
// stack: [capturedcontext]
}

private void collectFields(InsnList insnList) {
private void collectSpecialFields(InsnList insnList) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: rename to collectCorrleationInfo?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

insnList.add(new InsnNode(Opcodes.DUP));
// stack: [capturedcontext, capturedcontext]
ldc(insnList, fieldsToCapture.size());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice!!!

@@ -48,31 +49,23 @@ void testPredicatedRef() {

RuntimeException runtimeException =
assertThrows(RuntimeException.class, () -> isEmptyInvalid.evaluate(ctx));
assertEquals("Cannot find symbol: x", runtimeException.getMessage());
assertEquals("Cannot dereference to field: x", runtimeException.getMessage());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure Cannot dereference to field is right...

I think Cannot dereference field: is better

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

fromJsonFields(jsonReader, capturedContext);
continue;
}
// if ("this".equals(argName)) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove comment

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@@ -234,7 +239,7 @@ private void fromJsonFields(JsonReader jsonReader, CapturedContext capturedConte
}
case FIELDS:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we need this anymore?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no, removed

remote unnecessary comments and dead code
@jpbempel jpbempel merged commit ff9a04a into master Jul 9, 2024
83 checks passed
@jpbempel jpbempel deleted the jpbempel/drop-field-capture branch July 9, 2024 09:14
@github-actions github-actions bot added this to the 1.38.0 milestone Jul 9, 2024
@jpbempel jpbempel added the tag: performance Performance related changes label Jul 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
comp: debugger Dynamic Instrumentation tag: performance Performance related changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants