public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug sanitizer/64170] New: [5 Regression] ICE compiling Linux Kernel drivers/media/rc/imon.c in imon_incoming_packet
@ 2014-12-03 18:05 sasha.levin at oracle dot com
  2014-12-03 18:59 ` [Bug sanitizer/64170] " jakub at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: sasha.levin at oracle dot com @ 2014-12-03 18:05 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64170

            Bug ID: 64170
           Summary: [5 Regression] ICE compiling Linux Kernel
                    drivers/media/rc/imon.c in imon_incoming_packet
           Product: gcc
           Version: 5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: sanitizer
          Assignee: unassigned at gcc dot gnu.org
          Reporter: sasha.levin at oracle dot com
                CC: dodji at gcc dot gnu.org, dvyukov at gcc dot gnu.org,
                    jakub at gcc dot gnu.org, kcc at gcc dot gnu.org,
                    y.gribov at samsung dot com, ygribov at gcc dot gnu.org

Created attachment 34180
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=34180&action=edit
Preprocessed source

I'm seeing the following failure:

$ gcc -v -Wp,-MD,drivers/media/rc/.imon.o.d  -nostdinc -isystem
/home/sasha/gcc-inst/lib/gcc/x86_64-unknown-linux-gnu/5.0.0/include
-I./arch/x86/include -Iarch/x86/include/generated  -Iinclude
-I./arch/x86/include/uapi -Iarch/x86/include/generated/uapi -I./include/uapi
-Iinclude/generated/uapi -include ./include/linux/kconfig.h -D__KERNEL__ -Wall
-Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common
-Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -m64
-mno-80387 -mno-fp-ret-in-387 -march=native -mno-red-zone -mcmodel=kernel
-funit-at-a-time -maccumulate-outgoing-args -DCONFIG_X86_X32_ABI
-DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1
-DCONFIG_AS_FXSAVEQ=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1
-pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -mno-sse -mno-mmx
-mno-sse2 -mno-3dnow -mno-avx -fno-delete-null-pointer-checks -O2
--param=allow-store-data-races=0 -fno-reorder-blocks -fno-ipa-cp-clone
-fno-partial-inlining -Wframe-larger-than=2048 -fstack-protector
-Wno-unused-but-set-variable -fno-omit-frame-pointer
-fno-optimize-sibling-calls -fno-var-tracking-assignments -g -gdwarf-4 -pg
-mfentry -DCC_USING_FENTRY -Wdeclaration-after-statement -Wno-pointer-sign
-fno-strict-overflow -fconserve-stack -Werror=implicit-int
-Werror=strict-prototypes -Werror=date-time -DCC_HAVE_ASM_GOTO   
-fsanitize=kernel-address -fasan-shadow-offset=0xdfffe90000000000 --param
asan-instrumentation-with-call-threshold=10000   -fsanitize=undefined 
-fno-sanitize=unreachable  -fno-sanitize=float-cast-overflow   
-D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(imon)" 
-D"KBUILD_MODNAME=KBUILD_STR(imon)" -c -o drivers/media/rc/.tmp_imon.o
drivers/media/rc/imon.c

Using built-in specs.
COLLECT_GCC=gcc
Target: x86_64-unknown-linux-gnu
Configured with: ../configure --prefix=/home/sasha/gcc-inst/ --with-arch=native
--with-tune=native --enable-languages=c --enable-lto --enable-gold
--enable-stage1-languages=c
Thread model: posix
gcc version 5.0.0 20141203 (experimental) (GCC) 

COLLECT_GCC_OPTIONS='-v' '-nostdinc' '-isystem'
'/home/sasha/gcc-inst/lib/gcc/x86_64-unknown-linux-gnu/5.0.0/include' '-I'
'./arch/x86/include' '-I' 'arch/x86/include/generated' '-I' 'include' '-I'
'./arch/x86/include/uapi' '-I' 'arch/x86/include/generated/uapi' '-I'
'./include/uapi' '-I' 'include/generated/uapi' '-include'
'./include/linux/kconfig.h' '-D' '__KERNEL__' '-Wall' '-Wundef'
'-Wstrict-prototypes' '-Wno-trigraphs' '-fno-strict-aliasing' '-fno-common'
'-Werror=implicit-function-declaration' '-Wno-format-security' '-std=gnu90'
'-m64' '-mno-80387' '-mno-fp-ret-in-387' '-march=native' '-mno-red-zone'
'-mcmodel=kernel' '-funit-at-a-time' '-maccumulate-outgoing-args' '-D'
'CONFIG_X86_X32_ABI' '-D' 'CONFIG_AS_CFI=1' '-D' 'CONFIG_AS_CFI_SIGNAL_FRAME=1'
'-D' 'CONFIG_AS_CFI_SECTIONS=1' '-D' 'CONFIG_AS_FXSAVEQ=1' '-D'
'CONFIG_AS_CRC32=1' '-D' 'CONFIG_AS_AVX=1' '-D' 'CONFIG_AS_AVX2=1' '-pipe'
'-Wno-sign-compare' '-fno-asynchronous-unwind-tables' '-mno-sse' '-mno-mmx'
'-mno-sse2' '-mno-3dnow' '-mno-avx' '-fno-delete-null-pointer-checks' '-O2'
'--param' 'allow-store-data-races=0' '-fno-reorder-blocks' '-fno-ipa-cp-clone'
'-fno-partial-inlining' '-Wframe-larger-than=2048' '-fstack-protector'
'-Wno-unused-but-set-variable' '-fno-omit-frame-pointer'
'-fno-optimize-sibling-calls' '-fno-var-tracking-assignments' '-g' '-gdwarf-4'
'-pg' '-mfentry' '-D' 'CC_USING_FENTRY' '-Wdeclaration-after-statement'
'-Wno-pointer-sign' '-fno-strict-overflow' '-fconserve-stack'
'-Werror=implicit-int' '-Werror=strict-prototypes' '-Werror=date-time' '-D'
'CC_HAVE_ASM_GOTO' '-fsanitize=kernel-address'
'-fasan-shadow-offset=0xdfffe90000000000' '--param'
'asan-instrumentation-with-call-threshold=10000' '-fsanitize=undefined'
'-fno-sanitize=unreachable' '-fno-sanitize=float-cast-overflow' '-D'
'KBUILD_STR(s)=#s' '-D' 'KBUILD_BASENAME=KBUILD_STR(imon)' '-D'
'KBUILD_MODNAME=KBUILD_STR(imon)' '-c' '-o' 'drivers/media/rc/.tmp_imon.o'
 /home/sasha/gcc-inst/libexec/gcc/x86_64-unknown-linux-gnu/5.0.0/cc1 -quiet
-nostdinc -v -I ./arch/x86/include -I arch/x86/include/generated -I include -I
./arch/x86/include/uapi -I arch/x86/include/generated/uapi -I ./include/uapi -I
include/generated/uapi -imultiarch x86_64-linux-gnu -D __KERNEL__ -D
CONFIG_X86_X32_ABI -D CONFIG_AS_CFI=1 -D CONFIG_AS_CFI_SIGNAL_FRAME=1 -D
CONFIG_AS_CFI_SECTIONS=1 -D CONFIG_AS_FXSAVEQ=1 -D CONFIG_AS_CRC32=1 -D
CONFIG_AS_AVX=1 -D CONFIG_AS_AVX2=1 -D CC_USING_FENTRY -D CC_HAVE_ASM_GOTO -D
KBUILD_STR(s)=#s -D KBUILD_BASENAME=KBUILD_STR(imon) -D
KBUILD_MODNAME=KBUILD_STR(imon) -isystem
/home/sasha/gcc-inst/lib/gcc/x86_64-unknown-linux-gnu/5.0.0/include -include
./include/linux/kconfig.h -MD drivers/media/rc/.imon.o.d
drivers/media/rc/imon.c -march=nehalem -mmmx -mno-3dnow -msse -msse2 -msse3
-mssse3 -mno-sse4a -mcx16 -msahf -mno-movbe -mno-aes -mno-sha -mno-pclmul
-mpopcnt -mno-abm -mno-lwp -mno-fma -mno-fma4 -mno-xop -mno-bmi -mno-bmi2
-mno-tbm -mno-avx -mno-avx2 -msse4.2 -msse4.1 -mno-lzcnt -mno-rtm -mno-hle
-mno-rdrnd -mno-f16c -mno-fsgsbase -mno-rdseed -mno-prfchw -mno-adx -mfxsr
-mno-xsave -mno-xsaveopt -mno-avx512f -mno-avx512er -mno-avx512cd -mno-avx512pf
-mno-prefetchwt1 -mno-clflushopt -mno-xsavec -mno-xsaves -mno-avx512dq
-mno-avx512bw -mno-avx512vl -mno-avx512ifma -mno-avx512vbmi -mno-clwb
-mno-pcommit --param l1-cache-size=32 --param l1-cache-line-size=64 --param
l2-cache-size=24576 -mtune=nehalem -quiet -dumpbase imon.c -m64 -mno-80387
-mno-fp-ret-in-387 -mno-red-zone -mcmodel=kernel -maccumulate-outgoing-args
-mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -mfentry -auxbase-strip
drivers/media/rc/.tmp_imon.o -g -gdwarf-4 -O2 -Wall -Wundef -Wstrict-prototypes
-Wno-trigraphs -Werror=implicit-function-declaration -Wno-format-security
-Wno-sign-compare -Wframe-larger-than=2048 -Wno-unused-but-set-variable
-Wdeclaration-after-statement -Wno-pointer-sign -Werror=implicit-int
-Werror=strict-prototypes -Werror=date-time -std=gnu90 -version -p
-fno-strict-aliasing -fno-common -funit-at-a-time
-fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks
-fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -fstack-protector
-fno-omit-frame-pointer -fno-optimize-sibling-calls
-fno-var-tracking-assignments -fno-strict-overflow -fconserve-stack
-fsanitize=kernel-address -fasan-shadow-offset=0xdfffe90000000000
-fsanitize=undefined -fno-sanitize=unreachable
-fno-sanitize=float-cast-overflow --param allow-store-data-races=0 --param
asan-instrumentation-with-call-threshold=10000 -o - |
 as -v -I ./arch/x86/include -I arch/x86/include/generated -I include -I
./arch/x86/include/uapi -I arch/x86/include/generated/uapi -I ./include/uapi -I
include/generated/uapi --64 -o drivers/media/rc/.tmp_imon.o
GNU assembler version 2.24 (x86_64-linux-gnu) using BFD version (GNU Binutils
for Debian) 2.24
GNU C89 (GCC) version 5.0.0 20141203 (experimental) (x86_64-unknown-linux-gnu)
    compiled by GNU C version 5.0.0 20141203 (experimental), GMP version 5.0.5,
MPFR version 3.1.0-p10, MPC version 0.9
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
#include "..." search starts here:
#include <...> search starts here:
 ./arch/x86/include
 arch/x86/include/generated
 include
 ./arch/x86/include/uapi
 arch/x86/include/generated/uapi
 ./include/uapi
 include/generated/uapi
 /home/sasha/gcc-inst/lib/gcc/x86_64-unknown-linux-gnu/5.0.0/include
End of search list.
GNU C89 (GCC) version 5.0.0 20141203 (experimental) (x86_64-unknown-linux-gnu)
    compiled by GNU C version 5.0.0 20141203 (experimental), GMP version 5.0.5,
MPFR version 3.1.0-p10, MPC version 0.9
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
Compiler executable checksum: b5ec4e8b98e67ea0af021f7c5845f9e4
drivers/media/rc/imon.c: In function ‘imon_incoming_packet’:
drivers/media/rc/imon.c:1588:13: internal compiler error: in
can_remove_asan_check, at sanopt.c:351
 static void imon_incoming_packet(struct imon_context *ictx,
             ^
0xaf7830 can_remove_asan_check
    ../../gcc/sanopt.c:351
0xaf85df maybe_optimize_asan_check_ifn
    ../../gcc/sanopt.c:433
0xaf85df sanopt_optimize_walker
    ../../gcc/sanopt.c:493
0xaf793a sanopt_optimize_walker
    ../../gcc/sanopt.c:526
0xaf793a sanopt_optimize_walker
    ../../gcc/sanopt.c:526
0xaf793a sanopt_optimize_walker
    ../../gcc/sanopt.c:526
0xaf9431 sanopt_optimize
    ../../gcc/sanopt.c:549
0xaf9431 execute
    ../../gcc/sanopt.c:596
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.


Bisected down to:


commit 977a4cdff6ddcd6d890d45b81c1a1b8fa92f6d54
Author: ygribov <ygribov@138bc75d-0d04-0410-961f-82ee72b054a4>
Date:   Wed Dec 3 09:23:28 2014 +0000

    Improve optimization of ASan checks.

    2014-12-03  Yury Gribov  <y.gribov@samsung.com>

    gcc/
        * sanopt.c (maybe_get_single_definition): New function.
        (maybe_get_dominating_check): Ditto.
        (can_remove_asan_check): Ditto.
        (struct tree_map_traits): New struct.
        (struct sanopt_ctx): Use custom traits for asan_check_map.
        (maybe_optimize_ubsan_null_ifn): Move code to
        maybe_get_dominating_check.
        (maybe_optimize_asan_check_ifn): Move code and take non-SSA expressions
        into account when optimizing.
        (sanopt_optimize_walker): Optimize ASan checks even when
        recovering.


    git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@218304
138bc75d-0d04-0410-961f-82ee72b054a4


Preprocessed source attached.
>From gcc-bugs-return-469390-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Wed Dec 03 18:15:01 2014
Return-Path: <gcc-bugs-return-469390-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 8836 invoked by alias); 3 Dec 2014 18:15:01 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 8426 invoked by uid 48); 3 Dec 2014 18:14:56 -0000
From: "ian at airs dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug go/63731] Fallback to netgo does not work
Date: Wed, 03 Dec 2014 18:15:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: go
X-Bugzilla-Version: 5.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ian at airs dot com
X-Bugzilla-Status: NEW
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: ian at airs dot com
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-63731-4-cv6TJRfe2G@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-63731-4@http.gcc.gnu.org/bugzilla/>
References: <bug-63731-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2014-12/txt/msg00397.txt.bz2
Content-length: 346

https://gcc.gnu.org/bugzilla/show_bug.cgi?idc731

--- Comment #22 from Ian Lance Taylor <ian at airs dot com> ---
I'm not sure why you say that it must not be the way it works.  It is the way
it works.

The recent change to Go 1.4 is that the -a option does not apply to the
standard library.  I don't know whether that is a good idea or not.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug sanitizer/64170] [5 Regression] ICE compiling Linux Kernel drivers/media/rc/imon.c in imon_incoming_packet
  2014-12-03 18:05 [Bug sanitizer/64170] New: [5 Regression] ICE compiling Linux Kernel drivers/media/rc/imon.c in imon_incoming_packet sasha.levin at oracle dot com
@ 2014-12-03 18:59 ` jakub at gcc dot gnu.org
  2014-12-05 23:00 ` jakub at gcc dot gnu.org
  2014-12-05 23:56 ` jakub at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: jakub at gcc dot gnu.org @ 2014-12-03 18:59 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64170

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2014-12-03
   Target Milestone|---                         |5.0
     Ever confirmed|0                           |1

--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Reduced testcase with -O2 -fsanitize=address,null :

int a, *b, c;
void bar (int);

void
foo (void)
{
  char *d = b;
  if (d[0] && d[1])
    return;
  if (c)
    a = *(int *) d;
  bar (*(int *) d);
}


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug sanitizer/64170] [5 Regression] ICE compiling Linux Kernel drivers/media/rc/imon.c in imon_incoming_packet
  2014-12-03 18:05 [Bug sanitizer/64170] New: [5 Regression] ICE compiling Linux Kernel drivers/media/rc/imon.c in imon_incoming_packet sasha.levin at oracle dot com
  2014-12-03 18:59 ` [Bug sanitizer/64170] " jakub at gcc dot gnu.org
@ 2014-12-05 23:00 ` jakub at gcc dot gnu.org
  2014-12-05 23:56 ` jakub at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: jakub at gcc dot gnu.org @ 2014-12-05 23:00 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64170

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Author: jakub
Date: Fri Dec  5 23:00:09 2014
New Revision: 218440

URL: https://gcc.gnu.org/viewcvs?rev=218440&root=gcc&view=rev
Log:
    PR sanitizer/64170
    * sanopt.c (maybe_optimize_asan_check_ifn): If base_checks is
    non-NULL, call maybe_get_dominating_check on it even if g is
    non-NULL.

    * gcc.dg/asan/pr64170.c: New test.

Added:
    trunk/gcc/testsuite/gcc.dg/asan/pr64170.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/sanopt.c
    trunk/gcc/testsuite/ChangeLog


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug sanitizer/64170] [5 Regression] ICE compiling Linux Kernel drivers/media/rc/imon.c in imon_incoming_packet
  2014-12-03 18:05 [Bug sanitizer/64170] New: [5 Regression] ICE compiling Linux Kernel drivers/media/rc/imon.c in imon_incoming_packet sasha.levin at oracle dot com
  2014-12-03 18:59 ` [Bug sanitizer/64170] " jakub at gcc dot gnu.org
  2014-12-05 23:00 ` jakub at gcc dot gnu.org
@ 2014-12-05 23:56 ` jakub at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: jakub at gcc dot gnu.org @ 2014-12-05 23:56 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64170

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|---                         |FIXED

--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Fixed.


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-12-05 23:56 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-12-03 18:05 [Bug sanitizer/64170] New: [5 Regression] ICE compiling Linux Kernel drivers/media/rc/imon.c in imon_incoming_packet sasha.levin at oracle dot com
2014-12-03 18:59 ` [Bug sanitizer/64170] " jakub at gcc dot gnu.org
2014-12-05 23:00 ` jakub at gcc dot gnu.org
2014-12-05 23:56 ` jakub at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).