Skip to content

cmd/go: TestScript/cover_atomic_pkgall broken on riscv64 #81175

Open

Description

@matloob

Here's an example of the failure:

   > env GO111MODULE=off
        > go test -coverpkg=all -covermode=atomic x
        [stdout]
        FAIL	x [build failed]
        FAIL
        [stderr]
        # x.test
        internal/goarch.init: cannot encode J-type instruction relocation offset for runtime.morestack_noctxt: signed immediate 0x129c58 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.init: cannot encode J-type instruction relocation offset for runtime.morestack_noctxt: signed immediate 0x129b88 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.BoundsDecode: cannot encode J-type instruction relocation offset for runtime.morestack_noctxt: signed immediate 0x129ab6 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.BoundsDecode: cannot encode J-type instruction relocation offset for runtime.gopanic: signed immediate 0x120504 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.Kind.String: cannot encode J-type instruction relocation offset for runtime.morestack_noctxt: signed immediate 0x12993c must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.Kind.String: cannot encode J-type instruction relocation offset for runtime.panicBounds: signed immediate 0x12b110 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.Kind.String: cannot encode J-type instruction relocation offset for runtime.panicBounds: signed immediate 0x12b10c must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.(*Type).NumMethod: cannot encode J-type instruction relocation offset for runtime.morestack_noctxt: signed immediate 0x1293b6 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.Name.IsBlank: cannot encode J-type instruction relocation offset for runtime.morestack_noctxt: signed immediate 0x1292ae must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.Name.Name: cannot encode J-type instruction relocation offset for runtime.morestack_noctxt: signed immediate 0x1290ae must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.Name.Name: cannot encode J-type instruction relocation offset for runtime.panicunsafestringlen: signed immediate 0x10cae2 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.Name.Name: cannot encode J-type instruction relocation offset for runtime.panicunsafestringlen: signed immediate 0x10cade must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.Name.Tag: cannot encode J-type instruction relocation offset for runtime.morestack_noctxt: signed immediate 0x128ec6 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.Name.Tag: cannot encode J-type instruction relocation offset for runtime.panicunsafestringlen: signed immediate 0x10c824 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.Name.Tag: cannot encode J-type instruction relocation offset for runtime.panicunsafestringlen: signed immediate 0x10c820 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.NewName: cannot encode J-type instruction relocation offset for runtime.morestack_noctxt: signed immediate 0x128bf4 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.NewName: cannot encode J-type instruction relocation offset for runtime.makeslice: signed immediate 0x123748 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.NewName: cannot encode J-type instruction relocation offset for runtime.memmove: signed immediate 0x12a2be must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.NewName: cannot encode J-type instruction relocation offset for runtime.memmove: signed immediate 0x12a284 must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.NewName: cannot encode J-type instruction relocation offset for runtime.memmove: signed immediate 0x12a21e must be in range [-0x100000, 0xfffff] (21 bits)
        internal/abi.NewName: cannot encode J-type instruction relocation offset for runtime.memmove: signed immediate 0x12a1da must be in range [-0x100000, 0xfffff] (21 bits)
        /home/swarming/.swarming/w/ir/x/w/goroot/pkg/tool/linux_riscv64/link: too many errors
    script_test.go:165: FAIL: testdata/script/cover_atomic_pkgall.txt:3: go test -coverpkg=all -covermode=atomic x: exit status 1

Activity

  1. gopherbot commented on Aug 27, 2026

    @gopherbot
    Contributor

    Change https://go.dev/cl/823284 mentions this issue: cmd/go: disable tests broken on certain platforms

  2. added
    NeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.
    arch-riscvIssues solely affecting the riscv64 architecture.
    on Aug 27, 2026
  3. added this to the Backlog milestone on Aug 27, 2026
  4. dmitshur commented on Aug 27, 2026

    @dmitshur
    Member

    CC @golang/riscv64.

  5. HeliC829 commented on Aug 28, 2026

    @HeliC829
    Contributor

    It seems a duplicate of #79275. Let me take a look.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    NeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.arch-riscvIssues solely affecting the riscv64 architecture.

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions