Skip to content

Commit

Permalink
apacheGH-38824: [Go] Enable GC checks (apache#38826)
Browse files Browse the repository at this point in the history
### What changes are included in this PR?

Our codebase has many uses of `unsafe.Pointer`. It may be a good idea to add debug checks for these uses in CI builds, especially where data crosses C boundaries.

### Are these changes tested?

Yes.

### Are there any user-facing changes?

No.

* Closes: apache#38824

Authored-by: Antoine Pitrou <[email protected]>
Signed-off-by: Antoine Pitrou <[email protected]>
  • Loading branch information
pitrou authored Nov 27, 2023
1 parent 6070815 commit 1cd22df
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ci/scripts/go_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ set -ex

source_dir=${1}/go

# Need "all=" as per https://github.com/golang/go/issues/42131#issuecomment-713917379
export GOFLAGS="${GOFLAGS} -gcflags=all=-d=checkptr"

pushd ${source_dir}/arrow

if [[ -n "${ARROW_GO_TESTCGO}" ]]; then
Expand Down
2 changes: 2 additions & 0 deletions ci/scripts/go_cgo_python_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ set -ex

source_dir=${1}/go

export GOFLAGS="${GOFLAGS} -gcflags=all=-d=checkptr"

pushd ${source_dir}/arrow/cdata/test

case "$(uname)" in
Expand Down
3 changes: 3 additions & 0 deletions dev/tasks/tasks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,9 @@ groups:
ruby:
- test-*ruby*

go:
- test*-go-*

vcpkg:
- test-*vcpkg*

Expand Down

0 comments on commit 1cd22df

Please sign in to comment.