Skip to content
This repository has been archived by the owner on Jul 11, 2023. It is now read-only.

Change helper return values from i32 to i64 #169

Merged
merged 2 commits into from
Aug 22, 2021
Merged

Change helper return values from i32 to i64 #169

merged 2 commits into from
Aug 22, 2021

Conversation

rhdxmr
Copy link
Collaborator

@rhdxmr rhdxmr commented Aug 22, 2021

Follow up libbpf's 6f8e021c commit

Signed-off-by: Junyeong Jeong [email protected]

This resolves #145

  • redbpf_probes::helpers::bpf_probe_read
  • redbpf_probes::helpers::bpf_perf_event_output
  • redbpf_probes::maps::StackTrace::stack_id
  • redbpf_probes::maps::ProgramArray::tail_call

and

  • redbpf::StackTrace::get, delete

Follow up libbpf's 6f8e021c commit

Signed-off-by: Junyeong Jeong <[email protected]>
Signed-off-by: Junyeong Jeong <[email protected]>
@rsdy
Copy link
Collaborator

rsdy commented Aug 22, 2021

This looks good, albeit i'm slightly concerned changing c_int to i64 indiscriminately because on arm64 a lot of amd64 i64's are u64's in this context.

Since it looks like GitHub Actions can't run ARM64 builders right now without extra magic (actions/runner-images#2552), I think we can drop arm64 verification for 2.0 and roll with it.

@rsdy rsdy merged commit 65a0915 into main Aug 22, 2021
@rsdy rsdy deleted the helpers-return-long branch August 22, 2021 10:41
@rhdxmr
Copy link
Collaborator Author

rhdxmr commented Aug 22, 2021

@rsdy

on arm64 a lot of amd64 i64's are u64's in this context.

what does that mean? I am not familiar with arm64 so I don't get it.

@rsdy
Copy link
Collaborator

rsdy commented Aug 22, 2021

A fair amount of places where Linux on x86 uses unsigned types, arm64 uses unsigned ones, and it's not always straightforward, where. I don't think it's practically an issue now, as I don't expect many arm64 users.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Change return type of functions which expose return of bpf helpers
2 participants