Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 1518823 - gcc: -fstack-clash-protection failure with calls with many arguments on aarch64
Summary: gcc: -fstack-clash-protection failure with calls with many arguments on aarch64
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: gcc
Version: 27
Hardware: aarch64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Jeff Law
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 1519165
Blocks: 1512531
TreeView+ depends on / blocked
 
Reported: 2017-11-29 15:44 UTC by Florian Weimer
Modified: 2018-02-06 15:32 UTC (History)
7 users (show)

Fixed In Version: gcc-7.2.1-4.fc27, gcc-7.2.1-4.fc28 gcc-7.3.1-2.fc26 gcc-7.3.1-2.fc27
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-02-06 10:50:09 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
tst-printf-bz18872.c (159.38 KB, text/plain)
2017-11-29 15:44 UTC, Florian Weimer
no flags Details
tst-printf-bz18872.c (159.22 KB, text/plain)
2017-11-29 17:16 UTC, Florian Weimer
no flags Details

Description Florian Weimer 2017-11-29 15:44:48 UTC
Created attachment 1360420 [details]
tst-printf-bz18872.c

This is a special printf function test which uses many, many arguments to exercise the vararg processing in printf.

I'm attaching the generated output from stdio-common/tst-printf-bz18872.sh, slightly edited to compile outside of the glibc test environment (hopefully this does not invalidate the test itself).  I will submit preprocessed sources once I gained access to a suitable aarch64 machine (which could take a while).

gcc /builddir/build/BUILD/glibc-2.26.9000-853-ga55430cb0e/build-aarch64-redhat-linux/stdio-common/tst-printf-bz18872.c -c -std=gnu11 -fgnu89-inline  -O2 -Wall -Werror -Wundef -Wwrite-strings -fmerge-all-constants -fno-asynchronous-unwind-tables -frounding-math -fstack-clash-protection -fstack-protector-strong -g -Wstrict-prototypes -Wold-style-definition           -I../include -I/builddir/build/BUILD/glibc-2.26.9000-853-ga55430cb0e/build-aarch64-redhat-linux/stdio-common  -I/builddir/build/BUILD/glibc-2.26.9000-853-ga55430cb0e/build-aarch64-redhat-linux  -I../sysdeps/unix/sysv/linux/aarch64  -I../sysdeps/aarch64/nptl  -I../sysdeps/unix/sysv/linux/generic  -I../sysdeps/unix/sysv/linux/wordsize-64  -I../sysdeps/unix/sysv/linux/include -I../sysdeps/unix/sysv/linux  -I../sysdeps/nptl  -I../sysdeps/pthread  -I../sysdeps/gnu  -I../sysdeps/unix/inet  -I../sysdeps/unix/sysv  -I../sysdeps/unix  -I../sysdeps/posix  -I../sysdeps/aarch64/fpu  -I../sysdeps/aarch64/multiarch  -I../sysdeps/aarch64  -I../sysdeps/wordsize-64  -I../sysdeps/ieee754/ldbl-128  -I../sysdeps/ieee754/dbl-64/wordsize-64  -I../sysdeps/ieee754/dbl-64  -I../sysdeps/ieee754/flt-32  -I../sysdeps/aarch64/soft-fp  -I../sysdeps/ieee754  -I../sysdeps/generic  -I.. -I../libio -I. -nostdinc -isystem /usr/lib/gcc/aarch64-redhat-linux/7/include -isystem /usr/include  -D_LIBC_REENTRANT -include /builddir/build/BUILD/glibc-2.26.9000-853-ga55430cb0e/build-aarch64-redhat-linux/libc-modules.h -DMODULE_NAME=testsuite -include ../include/libc-symbols.h       -DTOP_NAMESPACE=glibc -D_IO_MTSAFE_IO -o /builddir/build/BUILD/glibc-2.26.9000-853-ga55430cb0e/build-aarch64-redhat-linux/stdio-common/tst-printf-bz18872.o -MD -MP -MF /builddir/build/BUILD/glibc-2.26.9000-853-ga55430cb0e/build-aarch64-redhat-linux/stdio-common/tst-printf-bz18872.o.dt -MT /builddir/build/BUILD/glibc-2.26.9000-853-ga55430cb0e/build-aarch64-redhat-linux/stdio-common/tst-printf-bz18872.o
/builddir/build/BUILD/glibc-2.26.9000-853-ga55430cb0e/build-aarch64-redhat-linux/stdio-common/tst-printf-bz18872.c: In function 'do_test':
/builddir/build/BUILD/glibc-2.26.9000-853-ga55430cb0e/build-aarch64-redhat-linux/stdio-common/tst-printf-bz18872.c:2016:1: internal compiler error: in dwarf2out_frame_debug_adjust_cfa, at dwarf2cfi.c:1137
 }
 ^
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://bugzilla.redhat.com/bugzilla> for instructions.
Preprocessed source stored into /tmp/ccdfohxH.out file, please attach this to your bugreport.

Comment 2 Florian Weimer 2017-11-29 17:16:34 UTC
Created attachment 1360475 [details]
tst-printf-bz18872.c

Reproducer without #includes

Compile with: gcc -fstack-clash-protection -c tst-printf-bz18872.c

Comment 5 Jeff Law 2017-11-29 19:01:56 UTC
Thanks.  Builds spinning for F27 and F28 with the fix.

Comment 6 Florian Weimer 2017-11-30 10:53:45 UTC
gcc build currently fails due to bug 1519165.

Comment 7 Fedora Update System 2018-01-31 07:49:00 UTC
gcc-7.3.1-2.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2018-75d88970d0

Comment 8 Fedora Update System 2018-01-31 07:55:45 UTC
gcc-7.3.1-2.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2018-aa879be08e

Comment 9 Fedora Update System 2018-01-31 18:42:59 UTC
gcc-7.3.1-2.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-aa879be08e

Comment 10 Fedora Update System 2018-01-31 22:45:56 UTC
gcc-7.3.1-2.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-75d88970d0

Comment 11 Fedora Update System 2018-02-06 10:50:09 UTC
gcc-7.3.1-2.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.

Comment 12 Fedora Update System 2018-02-06 15:32:01 UTC
gcc-7.3.1-2.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.