public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/61852] New: Incorrect column number for -Wimplicit-function-declaration
@ 2014-07-19 19:30 chengniansun at gmail dot com
  2014-07-19 21:42 ` [Bug c/61852] " mpolacek at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: chengniansun at gmail dot com @ 2014-07-19 19:30 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="UTF-8", Size: 4982 bytes --]

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

            Bug ID: 61852
           Summary: Incorrect column number for
                    -Wimplicit-function-declaration
           Product: gcc
           Version: 4.10.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: chengniansun at gmail dot com

The current version points to the start of the statement containing the
undeclared function call. 


$: cat t.c
int f (int a) {
  int b = a + a + a + ff(a);
  return b;
}
$: gcc-trunk -Wimplicit-function-declaration -c t.c 
t.c: In function ‘f’:
t.c:2:3: warning: implicit declaration of function ‘ff’
[-Wimplicit-function-declaration]
   int b = a + a + a + ff(a);
   ^
$: clang-trunk -Wimplicit-function-declaration -c t.c 
t.c:2:23: warning: implicit declaration of function 'ff' is invalid in C99
[-Wimplicit-function-declaration]
  int b = a + a + a + ff(a);
                      ^
1 warning generated.
>From gcc-bugs-return-456774-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Sat Jul 19 21:12:38 2014
Return-Path: <gcc-bugs-return-456774-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 30672 invoked by alias); 19 Jul 2014 21:12:37 -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 30408 invoked by uid 48); 19 Jul 2014 21:12:22 -0000
From: "danglin at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/61853] New: [4.9,4.10 Regression] ICE: SIGSEGV in store_field
Date: Sat, 19 Jul 2014 21:12:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 4.9.2
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: danglin at gcc dot gnu.org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter cf_gcchost cf_gcctarget cf_gccbuild
Message-ID: <bug-61853-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-07/txt/msg01365.txt.bz2
Content-length: 2067

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

            Bug ID: 61853
           Summary: [4.9,4.10 Regression] ICE: SIGSEGV in store_field
           Product: gcc
           Version: 4.9.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: middle-end
          Assignee: unassigned at gcc dot gnu.org
          Reporter: danglin at gcc dot gnu.org
              Host: hppa-unknown-linux-gnu
            Target: hppa-unknown-linux-gnu
             Build: hppa-unknown-linux-gnu

(gdb) r
Starting program: /home/dave/gnu/gcc/objdir/stage1-gcc/cc1plus -fpreprocessed
ConstituentParticleData.ii -quiet -dumpbase ConstituentParticleData.cc
-auxbase-strip .libs/ConstituentParticleData.o -g -O2 -Wpedantic -Wall -Wextra
-Wformat=1 -Werror=format-security -ansi -version -fPIC -o
ConstituentParticleData.s
GNU C++ (GCC) version 4.10.0 20140717 (experimental) [trunk revision 212770]
(hppa-linux-gnu)
    compiled by GNU C version 4.9.0, GMP version 6.0.0, MPFR version 3.1.2-p3,
MPC version 1.0.2
GGC heuristics: --param ggc-min-expand0 --param ggc-min-heapsize@96
GNU C++ (GCC) version 4.10.0 20140717 (experimental) [trunk revision 212770]
(hppa-linux-gnu)
    compiled by GNU C version 4.9.0, GMP version 6.0.0, MPFR version 3.1.2-p3,
MPC version 1.0.2
GGC heuristics: --param ggc-min-expand0 --param ggc-min-heapsize@96
Compiler executable checksum: 03431aebbd62606890d51bba87e8825f

Program received signal SIGSEGV, Segmentation fault.
0x00a5870c in store_field (target=0xf7275af0, bitsized, bitpos=0,
    bitregion_start=0, bitregion_endc, modeßmode, exp=0xf6f412d0,
    alias_set=7,
    nontemporal=<error reading variable: can't compute CFA for this frame>)
    at ../../gcc/gcc/expr.c:6493
6493          && ((((MEM_ALIGN (target) < GET_MODE_ALIGNMENT (mode))
(gdb) p debug_rtx (target)
(parallel:BLK [
        (expr_list:REG_DEP_TRUE (reg:DI 101 [ <retval> ])
            (const_int 0 [0]))
    ])
$1 = void

Maybe one can't store into a BLKmode structure?


ICE doesn't occur with 4.8.


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

* [Bug c/61852] Incorrect column number for -Wimplicit-function-declaration
  2014-07-19 19:30 [Bug c/61852] New: Incorrect column number for -Wimplicit-function-declaration chengniansun at gmail dot com
@ 2014-07-19 21:42 ` mpolacek at gcc dot gnu.org
  2014-07-20 10:44 ` mpolacek at gcc dot gnu.org
  2014-07-20 10:45 ` mpolacek at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: mpolacek at gcc dot gnu.org @ 2014-07-19 21:42 UTC (permalink / raw)
  To: gcc-bugs

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

Marek Polacek <mpolacek at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |ASSIGNED
   Last reconfirmed|                            |2014-07-19
                 CC|                            |mpolacek at gcc dot gnu.org
           Assignee|unassigned at gcc dot gnu.org      |mpolacek at gcc dot gnu.org
   Target Milestone|---                         |4.10.0
     Ever confirmed|0                           |1

--- Comment #1 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
Mine.


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

* [Bug c/61852] Incorrect column number for -Wimplicit-function-declaration
  2014-07-19 19:30 [Bug c/61852] New: Incorrect column number for -Wimplicit-function-declaration chengniansun at gmail dot com
  2014-07-19 21:42 ` [Bug c/61852] " mpolacek at gcc dot gnu.org
@ 2014-07-20 10:44 ` mpolacek at gcc dot gnu.org
  2014-07-20 10:45 ` mpolacek at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: mpolacek at gcc dot gnu.org @ 2014-07-20 10:44 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
Author: mpolacek
Date: Sun Jul 20 10:43:26 2014
New Revision: 212865

URL: https://gcc.gnu.org/viewcvs?rev=212865&root=gcc&view=rev
Log:
    PR c/61852
    * c-decl.c (implicit_decl_warning): Add location_t parameter.  Use it.
    (implicitly_declare): Pass location to implicit_decl_warning.

    * gcc.dg/pr61852.c: New test.

Added:
    trunk/gcc/testsuite/gcc.dg/pr61852.c
Modified:
    trunk/gcc/c/ChangeLog
    trunk/gcc/c/c-decl.c
    trunk/gcc/testsuite/ChangeLog


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

* [Bug c/61852] Incorrect column number for -Wimplicit-function-declaration
  2014-07-19 19:30 [Bug c/61852] New: Incorrect column number for -Wimplicit-function-declaration chengniansun at gmail dot com
  2014-07-19 21:42 ` [Bug c/61852] " mpolacek at gcc dot gnu.org
  2014-07-20 10:44 ` mpolacek at gcc dot gnu.org
@ 2014-07-20 10:45 ` mpolacek at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: mpolacek at gcc dot gnu.org @ 2014-07-20 10:45 UTC (permalink / raw)
  To: gcc-bugs

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

Marek Polacek <mpolacek at gcc dot gnu.org> changed:

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

--- Comment #3 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
Fixed.


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

end of thread, other threads:[~2014-07-20 10:45 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-07-19 19:30 [Bug c/61852] New: Incorrect column number for -Wimplicit-function-declaration chengniansun at gmail dot com
2014-07-19 21:42 ` [Bug c/61852] " mpolacek at gcc dot gnu.org
2014-07-20 10:44 ` mpolacek at gcc dot gnu.org
2014-07-20 10:45 ` mpolacek 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).