cockroachdb / cockroachdb/cockroach

geoindex: produces different result on arm64

Open
#106,954 0 comments 0 reactions 0 assignees View on GitHub
C-bug
Dominant language
Go
Stars
32.5k
Forks
4.1k
PR merge metrics
PR metrics pending

Description

When running `geoindex` tests on the M1, you get a different result on [GEOS 3.11](https://github.com/cockroachdb/cockroach/pull/106642#pullrequestreview-1533070628):

```
./dev test pkg/geo/geoindex
$ bazel test pkg/geo/geoindex:all --test_env=GOTRACEBACK=all --test_output errors
INFO: Invocation ID: 28a1dbda-ba3c-469a-9108-1a33b359c55d
INFO: Analyzed 4 targets (2 packages loaded, 451 targets configured).
INFO: Found 3 targets and 1 test target...
FAIL: //pkg/geo/geoindex:geoindex_test (see /private/var/tmp/_bazel_otan/d84c8263fef9b9141e9bd680cf5147cb/execroot/com_github_cockroachdb_cockroach/bazel-out/darwin_arm64-fastbuild/testlogs/pkg/geo/geoindex/geoindex_test/test.log)
INFO: From Testing //pkg/geo/geoindex:geoindex_test:
==================== Test output for //pkg/geo/geoindex:geoindex_test:
--- FAIL: TestS2GeometryIndexBasic (0.52s)
datadriven.go:143:
/private/var/tmp/_bazel_otan/d84c8263fef9b9141e9bd680cf5147cb/sandbox/darwin-sandbox/23/execroot/com_github_cockroachdb_cockroach/bazel-out/darwin_arm64-fastbuild/bin/pkg/geo/geoindex/geoindex_test_/geoindex_test.runfiles/com_github_cockroachdb_cockroach/pkg/geo/geoindex/testdata/s2_geometry:276:

expected:
[F0/L30/000000000000000000000000000000, F0/L30/033333333333333333333333333333],
F0/L0/, F0/L1/2, F0/L2/22, [F0/L30/222000000000000000000000000000, F0/L30/222333333333333333333333333333],
spilled

found:
[F0/L30/000000000000000000000000000000, F0/L30/333333333333333333333333333333],
spilled
FAIL
2023/07/16 13:24:41 Test //pkg/geo/geoindex:geoindex_test exited with error code 1
================================================================================
```

## Visualisations
[From here](https://codesandbox.io/s/s2-visualizer-2cr40?file=/index.js)

### Expected
```
[F0/L30/000000000000000000000000000000, F0/L30/033333333333333333333333333333],
F0/L0/, F0/L1/2, F0/L2/22, [F0/L30/222000000000000000000000000000, F0/L30/222333333333333333333333333333],
```
image

### Actual
```
[F0/L30/000000000000000000000000000000, F0/L30/333333333333333333333333333333],
```
image

Jira issue: CRDB-29775

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.