Skip to content

Navigation Menu

Sign in
Sign up

[Performance] Reduce unnecessary copying of strings and objects - #129

Open
marcomagdy wants to merge 1 commit into
aws:main from
marcomagdy:recude-copying
Open

[Performance] Reduce unnecessary copying of strings and objects #129
marcomagdy wants to merge 1 commit into
aws:main from
marcomagdy:recude-copying

Conversation

@marcomagdy

@marcomagdy marcomagdy commented Nov 28, 2023

Copy link
Copy Markdown

Description of changes:

This patch attempts to improve performance by doing the following:

  1. Remove an extra getenv call, which internally involve a bunch of string copying.
  2. Avoid default constructing the invocation_request object only to overwrite it later with the actual request. Instead use a reference.
  3. Avoid copying the request string when we can pass it by reference

Testing:

  • make test
  • make test-integ

Target (OCI, Managed Runtime, both):

Both

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

This patch attempts to improve performance by doing the following:
1. Remove an extra `getenv` call, which internally involve a bunch of
 string copying.
2. Avoid default constructing the `invocation_request` object only to
 overwrite it later with the actual request. Instead use a reference.
3. Avoid copying the request string when we can pass it by reference
Testing:
- make test
- make test-integ
marcomagdy marked this pull request as ready for review November 28, 2023 20:05

Copy link
Copy Markdown
Author

FWIW, I wrote the native the client.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

AltStyle によって変換されたページ (->オリジナル) /