[llvm-bugs] [Bug 40718] New: error in backend: Segmented stacks do not support vararg functions.

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Feb 13 06:27:40 PST 2019


https://bugs.llvm.org/show_bug.cgi?id=40718

            Bug ID: 40718
           Summary: error in backend: Segmented stacks do not support
                    vararg functions.
           Product: clang
           Version: 8.0
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: -New Bugs
          Assignee: unassignedclangbugs at nondot.org
          Reporter: benjima at gmail.com
                CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org,
                    neeilans at live.com, richard-llvm at metafoo.co.uk

Created attachment 21473
  --> https://bugs.llvm.org/attachment.cgi?id=21473&action=edit
packed cgo-gcc-input-266913532-73e194.c and cgo-gcc-input-266913532-73e194.sh

Hi!

I'm not really sure what the problem with the code is, but I've attached the
files mentioned by clang. 

Some background: I'm working with gollvm to compile C code that is being used
in Go. 

Hopefully this can shed some light on a workaround, as I would like to be able
to compile. Could it be, that the "-fsplit-stack" invokation leads to this?

CGO_LDFLAGS='"-g" "-O2" "-lrt"' /root/llvm-install/tools/cgo -objdir
$WORK/b002/ -importpath karalabe-hid/karalabe/hid -gccgo
-gccgopkgpath=karalabe-hid/karalabe/hid -exportheader=$WORK/b002/_cgo_install.h
-- -fsanitize=fuzzer,memory -I $WORK/b002/ -g -O2
-I/root/go/src/karalabe-hid/karalabe/hid/hidapi/hidapi
-I/root/go/src/karalabe-hid/karalabe/hid/libusb/libusb -DDEFAULT_VISIBILITY=
-DOS_LINUX -D_GNU_SOURCE -DPOLL_NFDS_TYPE=int -fsplit-stack ./hid_enabled.go
./wchar.go
# karalabe-hid/karalabe/hid
fatal error: error in backend: Segmented stacks do not support vararg
functions.
clang-8: error: clang frontend command failed with exit code 70 (use -v to see
invocation)
clang version 8.0.0
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /usr/bin
clang-8: note: diagnostic msg: PLEASE submit a bug report to
https://bugs.llvm.org/ and include the crash backtrace, preprocessed source,
and associated run script.
clang-8: note: diagnostic msg:
********************

PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang-8: note: diagnostic msg: /tmp/cgo-gcc-input-266913532-73e194.c
clang-8: note: diagnostic msg: /tmp/cgo-gcc-input-266913532-73e194.sh
clang-8: note: diagnostic msg:

********************

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20190213/32f9b295/attachment.html>


More information about the llvm-bugs mailing list