Skip to content

cmd/compile: <autogenerated>:1:0: invalid instruction: 00000 (/home/xxx/main.go:8) MOVQ $0, "".n+2147483680(SP) #25507

@limpo1989

Description

@limpo1989

What version of Go are you using (go version)?

go version go1.10.2 linux/amd64

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

linux/amd64

What did you do?

go build main.go

What did you see instead?

# command-line-arguments
<autogenerated>:1:0: invalid instruction: 00000 (/home/xxx/main.go:8) MOVQ    $0, "".n+2147483680(SP)
<autogenerated>:1:0: invalid instruction: 00003 (/home/xxx/main.go:8) MOVUPS  X0, "".err+2147483688(SP)

cat main.go

package main

type aa struct {
        // 1024 * 1024 * 255 is ok.
        I [1024 * 1024 * 256]int
}

// change to pointer receiver is no compiler error.
// func(a *aa) Write(p []byte) (n int, err error) 
func (a aa) Write(p []byte) (n int, err error) {
        return
}

func main() {
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    FrozenDueToAgeNeedsFixThe path to resolution is known, but the work has not been done.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions