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

image/draw: linux/arm64 segfault #10304

Closed
crawshaw opened this issue Mar 31, 2015 · 3 comments
Closed

image/draw: linux/arm64 segfault #10304

crawshaw opened this issue Mar 31, 2015 · 3 comments
Milestone

Comments

@crawshaw
Copy link
Member

The builder has little to say:

signal: segmentation fault (core dumped)
FAIL    image/draw  0.367s

Appears to be independent of other failures, will investigate tomorrow.

@crawshaw
Copy link
Member Author

crawshaw commented Apr 2, 2015

@4ad are you planning on looking at this? If so, I'll avoid duplicating your work. :-)

@4ad
Copy link
Member

4ad commented Apr 2, 2015

I can take a look, but only on Saturday, so if you want to look into it sooner, go ahead.

@crawshaw
Copy link
Member Author

crawshaw commented Apr 2, 2015

This is the simplest reproduction I could come up with without digging into compiler diagnostics. It prints signal: segmentation fault on linux/arm64, running from tip.

package main

var ch  = make(chan bool)

func main() {
    f()
    go g()
    <-ch
}

func g() {
    defer func() {
        r := recover()
        if r != nil {
            panic(r)
        }
        close(ch)
    }()
    f()
}

func f() {
    i1 := 8
    srcb := make([]byte, i1)
    dstb := make([]byte, i1)
    d0 := 0
    s0 := 0
    ddelta := 1
    sdelta := 1
    idelta := 1
    i0 := 0
    for dy := 1; dy > 0; dy-- {
        dpix := dstb[d0:]
        spix := srcb[s0:]
        for i := i0; i != i1; i += idelta {
            var sr, sg, sb, sa byte

            var dr, dg, db, da byte

            _ = spix[i]
            _ = dpix[i]
            _ = sa
            _ = dr
            _ = sr
            _ = dg
            _ = sg
            _ = db
            _ = sb
            _ = da
            _ = sa
        }
    }

    _ = ddelta
    _ = sdelta
}

@crawshaw crawshaw self-assigned this Apr 3, 2015
@golang golang locked and limited conversation to collaborators Jun 25, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants