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

new(ci): add a zig build job plus a composite action to setup zig. #2078

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

FedeDP
Copy link
Contributor

@FedeDP FedeDP commented Sep 20, 2024

What type of PR is this?

/kind feature

Any specific area of the project related to this PR?

/area CI

Does this PR require a change in the driver versions?

What this PR does / why we need it:

This PR adds a composite action to setup zig (stolen by my Falco PR: falcosecurity/falco#3307, that will be of course updated to use the libs provided action once this gets merged), and adds a CI job to test build of sinsp-example with zig.

Which issue(s) this PR fixes:

Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

NONE

@poiana
Copy link
Contributor

poiana commented Sep 20, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: FedeDP

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@FedeDP FedeDP force-pushed the new/zig_action_ci branch 2 times, most recently from e4a7231 to 33e0670 Compare September 20, 2024 14:19
shell: bash
id: zig
env:
ZIG_VERSION: '0.14.0-dev.1588+2111f4c38'
Copy link
Contributor Author

@FedeDP FedeDP Sep 20, 2024

Choose a reason for hiding this comment

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

We need to use a development version of zig since it needs my patch: ziglang/zig#21253
Hopefully they'll release 0.14.0 soon.

Also, keeping this PR wip as master zig artifacts are not kept around, ie: once a new master artifact is released, the old ones get removed.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

As a workaround, i am using actions/cache to cache the zig toolchain.

Copy link

codecov bot commented Sep 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 73.58%. Comparing base (b8c2d0d) to head (0b6cc6a).

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #2078   +/-   ##
=======================================
  Coverage   73.58%   73.58%           
=======================================
  Files         253      253           
  Lines       31867    31867           
  Branches     5640     5627   -13     
=======================================
  Hits        23449    23449           
+ Misses       8414     8403   -11     
- Partials        4       15   +11     
Flag Coverage Δ
libsinsp 73.58% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link

github-actions bot commented Sep 20, 2024

Perf diff from master - unit tests

     1.90%     +1.16%  [.] sinsp_thread_manager::find_thread
     1.27%     +0.94%  [.] std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release
    10.70%     +0.61%  [.] sinsp_parser::reset
     1.32%     -0.60%  [.] sinsp_filter_check::parse_field_name
     7.66%     +0.59%  [.] sinsp::next
     2.47%     -0.57%  [.] scap_event_decode_params
     0.63%     -0.53%  [.] sinsp_evt::is_filtered_out
     0.52%     +0.48%  [.] scap_event_has_large_payload
     3.48%     -0.43%  [.] sinsp_thread_manager::get_thread_ref
     4.59%     -0.40%  [.] sinsp_evt::load_params

Heap diff from master - unit tests

peak heap memory consumption: 0B
peak RSS (including heaptrack overhead): 0B
total memory leaked: 0B

Heap diff from master - scap file

peak heap memory consumption: 0B
peak RSS (including heaptrack overhead): 0B
total memory leaked: 0B

Benchmarks diff from master

Comparing gbench_data.json to /root/actions-runner/_work/libs/libs/build/gbench_data.json
Benchmark                                                         Time             CPU      Time Old      Time New       CPU Old       CPU New
----------------------------------------------------------------------------------------------------------------------------------------------
BM_sinsp_split_mean                                            +0.0096         +0.0096           151           152           151           152
BM_sinsp_split_median                                          +0.0088         +0.0088           151           152           151           152
BM_sinsp_split_stddev                                          +1.0427         +1.0423             1             2             1             2
BM_sinsp_split_cv                                              +1.0233         +1.0229             0             0             0             0
BM_sinsp_concatenate_paths_relative_path_mean                  +0.1291         +0.1291            41            46            41            46
BM_sinsp_concatenate_paths_relative_path_median                +0.1314         +0.1314            41            46            41            46
BM_sinsp_concatenate_paths_relative_path_stddev                +2.7327         +2.7301             0             1             0             1
BM_sinsp_concatenate_paths_relative_path_cv                    +2.3060         +2.3036             0             0             0             0
BM_sinsp_concatenate_paths_empty_path_mean                     +0.0093         +0.0093            17            17            17            17
BM_sinsp_concatenate_paths_empty_path_median                   +0.0137         +0.0137            17            17            17            17
BM_sinsp_concatenate_paths_empty_path_stddev                   -0.5007         -0.5012             0             0             0             0
BM_sinsp_concatenate_paths_empty_path_cv                       -0.5053         -0.5058             0             0             0             0
BM_sinsp_concatenate_paths_absolute_path_mean                  +0.1100         +0.1100            45            50            45            50
BM_sinsp_concatenate_paths_absolute_path_median                +0.1250         +0.1250            45            51            45            51
BM_sinsp_concatenate_paths_absolute_path_stddev                +0.5418         +0.5422             1             2             1             2
BM_sinsp_concatenate_paths_absolute_path_cv                    +0.3891         +0.3894             0             0             0             0
BM_sinsp_split_container_image_mean                            -0.0243         -0.0243           350           341           350           341
BM_sinsp_split_container_image_median                          -0.0245         -0.0245           350           341           350           341
BM_sinsp_split_container_image_stddev                          -0.1835         -0.1844             2             1             2             1
BM_sinsp_split_container_image_cv                              -0.1632         -0.1641             0             0             0             0

Signed-off-by: Federico Di Pierro <nierro92@gmail.com>
Signed-off-by: Federico Di Pierro <nierro92@gmail.com>
@FedeDP FedeDP changed the title wip: new(ci): add a zig build job plus a composite action to setup zig. new(ci): add a zig build job plus a composite action to setup zig. Sep 20, 2024
@FedeDP
Copy link
Contributor Author

FedeDP commented Sep 20, 2024

/milestone 0.19.0

@poiana poiana added this to the 0.19.0 milestone Sep 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants