Skip to content

Commit

Permalink
Merge pull request #6 from parca-dev/extract_offsets_from_dwarf
Browse files Browse the repository at this point in the history
Extract Offsets From the DWARF data
  • Loading branch information
kakkoyun authored Feb 12, 2024
2 parents f7f3986 + e464c35 commit 2e7fb73
Show file tree
Hide file tree
Showing 89 changed files with 3,620 additions and 1,707 deletions.
7 changes: 7 additions & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Automatically sets up your devbox environment whenever you cd into this
# directory via our direnv integration:

eval "$(devbox generate direnv --print-envrc)"

# check out https://www.jetpack.io/devbox/docs/ide_configuration/direnv/
# for more details
43 changes: 43 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
---
name: Build
'on':
workflow_call: null
push:
branches:
- main
- release-*
pull_request:
branches:
- main
- release-*
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Check out the code
uses: actions/[email protected]
- name: Install devbox
uses: jetpack-io/[email protected]
with:
enable-cache: true
- name: Setup devbox
run: devbox run -- echo "done!"
- name: Load devbox shellenv
uses: HatsuneMiku3939/direnv-action@v1
with:
direnvVersion: 2.32.3
- name: Set up Go tool cache
uses: actions/[email protected]
with:
path: |
~/.devbox/go
key: devbox-go-tools.cache-${{ runner.arch }}-${{ hashFiles('Makefile') }}
- name: Check
run: make check
- name: Format
run: make format
- name: Build
run: make build
255 changes: 255 additions & 0 deletions .github/workflows/generate-python.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,255 @@
---
name: Generate Python
'on':
workflow_call: null
push:
branches:
- main
paths:
- .github/workflows/generate-ruby.yml
permissions:
contents: write
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true
jobs:
generate:
runs-on: ubuntu-latest
timeout-minutes: 20
strategy:
fail-fast: false
matrix:
python-version:
- 2.7.0
- 2.7.1
- 2.7.2
- 2.7.3
-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 3.9.15
- 3.9.16
- 3.9.17
- 3.9.18
- 3.10.0
- 3.10.1
- 3.10.2
- 3.10.3
- 3.10.4
- 3.10.5
- 3.10.6
- 3.10.7
- 3.10.8
- 3.10.9
- 3.10.10
- 3.10.11
- 3.10.12
- 3.10.13
- 3.11.0
- 3.11.1
- 3.11.2
- 3.11.3
- 3.11.4
- 3.11.5
- 3.11.6
- 3.11.7
- 3.11.8
steps:
- name: Check out the code
uses: actions/[email protected]
- name: Install devbox
uses: jetpack-io/[email protected]
with:
enable-cache: true
- name: Setup devbox
run: devbox run -- echo "done!"
- name: Load devbox shellenv
uses: HatsuneMiku3939/direnv-action@v1
with:
direnvVersion: 2.32.3
- name: Set up Go tool cache
uses: actions/[email protected]
with:
path: |
~/.devbox/go
key: devbox-go-tools.cache-${{ runner.arch }}-${{ hashFiles('Makefile') }}
- name: Build
run: make build
- name: Generate python Offsets for ${{ matrix.python-version }}
run: >-
|-
| export python_version="${{ matrix.python-version }}" docker run --rm -v "${PWD}"/python-binaries:/tmp -w /tmp python:${{ matrix.python-version }} bash -c 'cp /usr/local/lib/libpython"${python_version%.*}"*.so.1.0 /tmp' ./structlayout -r python -v ${{ matrix.python-version }} -o offsets-python python-binaries/libpython"${python_version%.*}"*.so.1.0 git add offsets-python cp $(git diff --name-only --staged | xargs) offsets-python || echo "No new or modified files - offsets
are up to date"
- name: Upload Offsets
uses: actions/upload-artifact@v3
with:
if-no-files-found: ignore
name: python-${{ matrix.python-version }}
path: offsets-python
create-branch:
runs-on: ubuntu-latest
needs: generate
steps:
- name: Check out the code
uses: actions/[email protected]
- name: Install devbox
uses: jetpack-io/[email protected]
with:
enable-cache: true
- name: Setup devbox
run: devbox run -- echo "done!"
- name: Load devbox shellenv
uses: HatsuneMiku3939/direnv-action@v1
with:
direnvVersion: 2.32.3
- name: Set up Go tool cache
uses: actions/[email protected]
with:
path: |
~/.devbox/go
key: devbox-go-tools.cache-${{ runner.arch }}-${{ hashFiles('Makefile') }}
- name: Build
run: make build
- uses: actions/download-artifact@v3
with:
name: offsets-${{ matrix.python-version }}
path: offsets-staging
- name: Merge offsets
run: ./mergelayout -o pkg/python/versions offsets-python
- name: Create a pull-request
uses: peter-evans/create-pull-request@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: 'chore: update python layout'
title: 'chore: update python layout'
body: This PR updates the python layout.
branch: update-python-offsets-${{ github.run_number }}
base: main
labels: chore
draft: false
maintainer-can-modify: true
Loading

0 comments on commit 2e7fb73

Please sign in to comment.