-
Notifications
You must be signed in to change notification settings - Fork 40
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
WIP | Intel Vtune tracing integration #341
Conversation
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #341 +/- ##
==========================================
+ Coverage 89.52% 89.53% +0.01%
==========================================
Files 17 17
Lines 4897 4903 +6
==========================================
+ Hits 4384 4390 +6
Misses 513 513
|
@@ -5,6 +5,7 @@ | |||
|
|||
#include <aws/s3/s3.h> | |||
|
|||
#include "aws/s3/private/s3_tracing.h" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
trivial: we usually include with brackets
#include "aws/s3/private/s3_tracing.h" | |
#include <aws/s3/private/s3_tracing.h> |
include/aws/s3/private/s3_tracing.h
Outdated
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. | ||
* SPDX-License-Identifier: Apache-2.0. | ||
*/ | ||
#include <aws/common/_ittnotify_private.h> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
make sure we end up including common/config.h before the ittnotify.h
we could do this:
#include <aws/common/_ittnotify_private.h> | |
#include <aws/s3/s3.h> | |
#include <aws/common/_ittnotify_private.h> |
or have a tracing file in common we include, that includes config.h before ittnotify.h
@@ -94,7 +95,7 @@ static struct aws_hash_table s_compute_platform_info_table; | |||
|
|||
static bool s_library_initialized = false; | |||
static struct aws_allocator *s_library_allocator = NULL; | |||
|
|||
__itt_domain *s3_domain; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
__itt_domain *s3_domain; | |
__itt_domain *s3_domain = NULL; |
@@ -1592,13 +1593,16 @@ void aws_s3_meta_request_finish_default(struct aws_s3_meta_request *meta_request | |||
struct aws_future_bool *aws_s3_meta_request_read_body( | |||
struct aws_s3_meta_request *meta_request, | |||
struct aws_byte_buf *buffer) { | |||
|
|||
__itt_task_begin(s3_domain, __itt_null, __itt_null, __itt_string_handle_create("read")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
possibly worth the optimization?
__itt_task_begin(s3_domain, __itt_null, __itt_null, __itt_string_handle_create("read")); | |
static __itt_string_handle *itt_name = __itt_string_handle_create("read"); | |
__itt_task_begin(s3_domain, __itt_null, __itt_null, itt_name); |
return aws_async_input_stream_read_to_fill(meta_request->request_body_async_stream, buffer); | ||
struct aws_future_bool *result = | ||
aws_async_input_stream_read_to_fill(meta_request->request_body_async_stream, buffer); | ||
__itt_task_end(s3_domain); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should probably mark up the implementation of aws_input_stream_read()
, begin/end task right around the vtable call
it wil be a lot harder to mark up the async stream :|
Issue #, if available:
Description of changes:
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.