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

cmd/internal/obj/arm64: assembling TSTW $1689262177517664, R3 fails #30334

Closed
eclipseo opened this issue Feb 20, 2019 · 10 comments
Closed

cmd/internal/obj/arm64: assembling TSTW $1689262177517664, R3 fails #30334

eclipseo opened this issue Feb 20, 2019 · 10 comments
Labels
FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. release-blocker
Milestone

Comments

@eclipseo
Copy link

eclipseo commented Feb 20, 2019

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

1.12 rc1

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

Fedora Rawhide aarch64

Micro (https://github.com/zyedidia/micro ) 1.4.1 compilation fails with 1.12 rc1 on aarch64 while it was working on 1.11. The error message is cryptic to me and I didn't find any info ducking it:

BUILDSTDERR: cd /builddir/build/BUILD/micro-1.4.1/_build/src/github.com/zyedidia/micro/cmd/micro
BUILDSTDERR: /usr/lib/golang/pkg/tool/linux_arm64/compile -o $WORK/b001/_pkg_.a -trimpath $WORK/b001 -shared -p main -complete -installsuffix shared -buildid yOmOqxe3SyScT76ADNYq/yOmOqxe3SyScT76ADNYq -goversion go1.12rc1 -D "" -importcfg $WORK/b001/importcfg -pack ./actions.go ./actions_posix.go ./autocomplete.go ./bindings.go ./buffer.go ./cellview.go ./colorscheme.go ./command.go ./cursor.go ./eventhandler.go ./highlighter.go ./job.go ./keymenu.go ./lineArray.go ./loc.go ./lua.go ./messenger.go ./micro.go ./plugin.go ./pluginmanager.go ./rtfiles.go ./runtime.go ./scrollbar.go ./search.go ./settings.go ./shell.go ./shell_supported.go ./split_tree.go ./stack.go ./statusline.go ./tab.go ./terminal.go ./util.go ./view.go
BUILDSTDERR: # github.com/zyedidia/micro/cmd/micro
BUILDSTDERR: cmd/micro/terminal.go:150:25: illegal combination: 00560 (/builddir/build/BUILD/micro-1.4.1/_build/src/github.com/zyedidia/micro/cmd/micro/terminal.go:125)	TSTW	$1689262177517664, R3
BUILDSTDERR: error: Bad exit status from /var/tmp/rpm-tmp.N9zjPx (%build)

I don't have access to the build system so I can't give more infos than this. It seems to me it's a regression since 1.11 was building fine.

@dmitshur dmitshur added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Feb 21, 2019
@dmitshur dmitshur added this to the Go1.12 milestone Feb 21, 2019
@dmitshur
Copy link
Contributor

dmitshur commented Feb 21, 2019

Thanks for the report. Can you provide the full output from go env? It would be helpful in narrowing this down.

Edit: I see you said "I don't have access to the build system so I can't give more infos than this." If go env is hard to come by, can you at least clarify which exact values of GOOS and GOARCH were used for compilation? Was it GOOS=linux GOARCH=arm64 or something else?

@dmitshur dmitshur added WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. and removed NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. labels Feb 21, 2019
@dmitshur dmitshur changed the title Possible regression: illegal combination: 00560 TSTW $1689262177517664, R3 on aarch64 cmd/compile: Possible regression: illegal combination: 00560 TSTW $1689262177517664, R3 on aarch64 Feb 21, 2019
@eclipseo
Copy link
Author

eclipseo commented Feb 21, 2019

Thanks for the report. Can you provide the full output from go env? It would be helpful in narrowing this down.

I managed to get it:

GOARCH="arm64"
GOBIN=""
GOCACHE="/builddir/.cache/go-build"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="arm64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/builddir/build/BUILD/micro-1.4.1/_build:/usr/share/gocode"
GOPROXY=""
GORACE=""
GOROOT="/usr/lib/golang"
GOTMPDIR=""
GOTOOLDIR="/usr/lib/golang/pkg/tool/linux_arm64"
GCCGO="gccgo"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build446101992=/tmp/go-build -gno-record-gcc-switches"

@cherrymui
Copy link
Member

I can confirm this. Simply assembling TSTW $1689262177517664, R3 now fails. It seems it starts to fail since CL https://go-review.googlesource.com/c/go/+/118796 (86ce1cb). I'll take a look tomorrow.

cc @zhangfannie

@dmitshur
Copy link
Contributor

dmitshur commented Feb 21, 2019

Thanks for that!

I can reproduce this by cross-compiling on my Mac:

$ export GOPATH=/tmp/empty
$ go get -d github.com/zyedidia/micro/cmd/micro
$ cd $GOPATH/src/github.com/zyedidia/micro/cmd/micro
$ git checkout v1.4.1
$ GOOS=linux GOARCH=arm64 go1.11.5 install
$ GOOS=linux GOARCH=arm64 go1.12rc1 install
# github.com/zyedidia/micro/cmd/micro
<autogenerated>:1: illegal combination: 00560 (/tmp/empty/src/github.com/zyedidia/micro/cmd/micro/terminal.go:125)	TSTW	$1689262177517664, R3

It is a regression compared to Go 1.11.5, so marking as release-blocker for 1.12 for now.

/cc @cherrymui Who would be good to ping about this? Edit: You beat me to it. :)

@dmitshur dmitshur added NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. and removed WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. labels Feb 21, 2019
@dmitshur dmitshur changed the title cmd/compile: Possible regression: illegal combination: 00560 TSTW $1689262177517664, R3 on aarch64 cmd/internal/obj/arm64: assembling TSTW $1689262177517664, R3 fails Feb 21, 2019
@zhangfannie
Copy link
Contributor

@cherrymui I am looking into it. Thank you.

@zhangfannie
Copy link
Contributor

@cherrymui I figured out the cause of the failure, it is indeed caused by my patch https://go-review.googlesource.com/c/go/+/118796。 This CL did not correctly consider the ADDCON2 class correctly causint this issue. Fix CL is ready, I will submit it ASAP. Thank you.

@gopherbot
Copy link

Change https://golang.org/cl/163259 mentions this issue: cmd/internal/obj/arm64: fix the bug assembling TSTW

@eclipseo
Copy link
Author

Man, you guys rock!

@gopherbot
Copy link

Change https://golang.org/cl/163419 mentions this issue: [release-branch.go1.12] cmd/internal/obj/arm64: fix the bug assembling TSTW

@ianlancetaylor
Copy link
Contributor

Well, the fix didn't make it into 1.12, but it will be in 1.12.1.

gopherbot pushed a commit that referenced this issue Feb 26, 2019
…g TSTW

Current assembler reports error when it assembles
"TSTW $1689262177517664, R3", but go1.11 was building
fine.

Fixes #30334

Change-Id: I9c16d36717cd05df2134e8eb5b17edc385aff0a9
Reviewed-on: https://go-review.googlesource.com/c/163259
Run-TryBot: Ben Shi <powerman1st@163.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ben Shi <powerman1st@163.com>
(cherry picked from commit 2ef8abb)
Reviewed-on: https://go-review.googlesource.com/c/163419
Run-TryBot: Cherry Zhang <cherryyz@google.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
@golang golang locked and limited conversation to collaborators Feb 26, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. release-blocker
Projects
None yet
Development

No branches or pull requests

6 participants