bigfft
bigfft copied to clipboard
ARM support, for EdgeX Foundry and gollvm
I am trying to use gollvm for building device-virtual-go - and it would require cross-compiling capabilities, if building under x86_64 (Ubuntu 20, in my case).
Looks like 3rd party assembler tool has to be called:
~/device-virtual-go$ make CGO_ENABLED=0 GO111MODULE=on go build -ldflags "-X github.com/edgexfoundry/device-virtual-go.Version=0.0.0" -o cmd/device-virtual ./cmd go build: when using gccgo toolchain, please pass linker flags using -gccgoflags, not -ldflags
github.com/remyoudompheng/bigfft
vendor/github.com/remyoudompheng/bigfft/arith_amd64.s: Assembler messages: vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:6: Error: no such instruction:
text ·addVV(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:7: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:11: Error: no such instruction:text ·subVV(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:12: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:15: Error: no such instruction:text ·addVW(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:16: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:20: Error: no such instruction:text ·subVW(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:21: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:24: Error: no such instruction:text ·shlVU(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:25: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:28: Error: no such instruction:text ·shrVU(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:29: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:32: Error: no such instruction:text ·mulAddVWW(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:33: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:36: Error: no such instruction:text ·addMulVVW(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:37: Error: junk
(SB)' after expression make: *** [Makefile:20: cmd/device-virtual] Error 2
Somewhat more verbosity here:
$ make GOFLAGS=' -i -v -x ' CGO_ENABLED=0 GO111MODULE=on go build -i -v -x -o cmd/device-virtual ./cmd WORK=/tmp/go-build256936414 github.com/remyoudompheng/bigfft mkdir -p $WORK/b131/ cd $WORK /usr/local/bin/llvm-goc -fgo-importcfg=/dev/null -c -x c - -o /dev/null || true cd /home/oceanfish81/device-virtual-go/vendor/github.com/remyoudompheng/bigfft /usr/local/bin/llvm-goc -c -O2 -g -m64 -fdebug-prefix-map=$WORK=/tmp/go-build -gno-record-gcc-switches -fgo-pkgpath=github.com/remyoudompheng/bigfft -o $WORK/b131/go.o -I $WORK/b131/importcfgroot ./arith_decl.go ./fermat.go ./fft.go ./scan.go /usr/local/bin/llvm-goc -xassembler-with-cpp -I $WORK/b131/ -c -o $WORK/b131/arith_amd64.o -D GOOS_linux -D GOARCH_amd64 -D GOPKGPATH=github.x2ecom..z2fremyoudompheng..z2fbigfft -m64 ./arith_amd64.s
github.com/remyoudompheng/bigfft
vendor/github.com/remyoudompheng/bigfft/arith_amd64.s: Assembler messages: vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:6: Error: no such instruction:
text ·addVV(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:7: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:11: Error: no such instruction:text ·subVV(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:12: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:15: Error: no such instruction:text ·addVW(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:16: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:20: Error: no such instruction:text ·subVW(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:21: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:24: Error: no such instruction:text ·shlVU(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:25: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:28: Error: no such instruction:text ·shrVU(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:29: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:32: Error: no such instruction:text ·mulAddVWW(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:33: Error: junk
(SB)' after expression vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:36: Error: no such instruction:text ·addMulVVW(SB),NOSPLIT,$0' vendor/github.com/remyoudompheng/bigfft/arith_amd64.s:37: Error: junk
(SB)' after expression make: *** [Makefile:20: cmd/device-virtual] Error 2
Build under such env.:
$ go env && go version GO111MODULE="" GOARCH="amd64" GOBIN="" GOCACHE="/home/oceanfish81/.cache/go-build" GOENV="/home/oceanfish81/.config/go/env" GOEXE="" GOFLAGS="" GOHOSTARCH="amd64" GOHOSTOS="linux" GOINSECURE="" GOMODCACHE="/home/oceanfish81/go/pkg/mod" GONOPROXY="" GONOSUMDB="" GOOS="linux" GOPATH="/home/oceanfish81/go" GOPRIVATE="" GOPROXY="https://proxy.golang.org,direct" GOROOT="/usr/local" GOSUMDB="sum.golang.org" GOTMPDIR="" GOTOOLDIR="/usr/local/tools" GCCGO="/usr/local/bin/llvm-goc" AR="ar" CC="/usr/bin/clang" CXX="/usr/bin/clang++" CGO_ENABLED="1" GOMOD="/home/oceanfish81/device-virtual-go/go.mod" CGO_CFLAGS="-g -O2" CGO_CPPFLAGS="" CGO_CXXFLAGS="-g -O2" CGO_FFLAGS="-g -O2" CGO_LDFLAGS="-g -O2" PKG_CONFIG="pkg-config" GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build099959315=/tmp/go-build -gno-record-gcc-switches -funwind-tables" go version go1.15rc2 gollvm LLVM 12.0.0git linux/amd64
@erifan, any suggestions/propositions?
@jpwhitemn, is this project to be built under ARM port of Linux? Or any brave people tried to cross-compile?
CC @remyoudompheng BCC @erifan @thanm @cherrymui
Ivan
Hi Ivan - we do support ARM. At this time, there is no support for LLVM and to be honest, you are the first that has brought this to our attention. Should others start to ask for it, we may put it on the roadmap. Otherwise, we welcome contributions from the LLVM community to assist EdgeX if there are specific actions/changes we can make (depending on their impacts) to help support.
Hi Ivan - we do support ARM. At this time, there is no support for LLVM and to be honest, you are the first that has brought this to our attention. Should others start to ask for it, we may put it on the roadmap. Otherwise, we welcome contributions from the LLVM community to assist EdgeX if there are specific actions/changes we can make (depending on their impacts) to help support.
Please explain the specifics of the above device-virtual-go package. If the community would know what is expected from remyoudompheng/bigfft - it would allow ARM's people to provide a roadmap, for hardware support. And then we could use LLVM's back-end capabilities, to provide some end-user support.