public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/55192] New: bfin generates invalid assembly
@ 2012-11-03 16:23 joel at gcc dot gnu.org
  2012-11-04  3:55 ` [Bug target/55192] " joel at gcc dot gnu.org
  2015-01-03 19:23 ` joel at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: joel at gcc dot gnu.org @ 2012-11-03 16:23 UTC (permalink / raw)
  To: gcc-bugs


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55192

             Bug #: 55192
           Summary: bfin generates invalid assembly
    Classification: Unclassified
           Product: gcc
           Version: 4.8.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: joel@gcc.gnu.org


Created attachment 28602
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28602
Tarball of preprocessed C and generated assembly

When building newlib using the gcc-svn head, the compiler generates assembly
language that cannot be assembled by the binutils cvs head or 2.22

xgcc (GCC) 4.8.0 20121103 (experimental) [trunk revision 193124]

Attached are the preprocessed C code and generated assembly.

This is sufficient to trip the issue:

/home/joel/v850/tools/b-gcc-svn/./gcc/xgcc
-B/home/joel/v850/tools/b-gcc-svn/./gcc/  -c  -fno-builtin      -g -O2
-fshort-enums  bfin_test.c 

/opt/rtems-4.11/bin/bfin-rtems4.11-as bfin_test.s
bfin_test.s: Assembler messages:
bfin_test.s:416: Error: syntax error. Input text was .LBE54.
bfin_test.s:416: Error: 

The original command was:

/home/joel/v850/tools/b-gcc-svn/./gcc/xgcc
-B/home/joel/v850/tools/b-gcc-svn/./gcc/ -nostdinc
-B/home/joel/v850/tools/b-gcc-svn/bfin-rtems4.11/newlib/ -isystem
/home/joel/v850/tools/b-gcc-svn/bfin-rtems4.11/newlib/targ-include -isystem
/home/joel/v850/tools/gcc-svn/newlib/libc/include
-B/home/joel/v850/install/bfin-rtems4.11/bin/
-B/home/joel/v850/install/bfin-rtems4.11/lib/ -isystem
/home/joel/v850/install/bfin-rtems4.11/include -isystem
/home/joel/v850/install/bfin-rtems4.11/sys-include    -DPACKAGE_NAME=\"newlib\"
-DPACKAGE_TARNAME=\"newlib\" -DPACKAGE_VERSION=\"1.20.0\"
-DPACKAGE_STRING=\"newlib\ 1.20.0\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\"
-I. -I../../../../../gcc-svn/newlib/libc/stdio -D_COMPILING_NEWLIB
-DMALLOC_PROVIDED -DEXIT_PROVIDED -DSIGNAL_PROVIDED
-DREENTRANT_SYSCALLS_PROVIDED -DHAVE_NANOSLEEP -DHAVE_BLKSIZE -DHAVE_FCNTL
-DHAVE_ASSERT_FUNC -D_NO_GETLOGIN -D_NO_GETPWENT -D_NO_GETUT -D_NO_GETPASS
-D_NO_SIGSET -D_NO_WORDEXP -D_NO_POPEN -Wall -fno-builtin      -g -O2
-fshort-enums -DINTEGER_ONLY -c
../../../../../gcc-svn/newlib/libc/stdio/vfprintf.c -E >bfin_test.c


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

* [Bug target/55192] bfin generates invalid assembly
  2012-11-03 16:23 [Bug c/55192] New: bfin generates invalid assembly joel at gcc dot gnu.org
@ 2012-11-04  3:55 ` joel at gcc dot gnu.org
  2015-01-03 19:23 ` joel at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: joel at gcc dot gnu.org @ 2012-11-04  3:55 UTC (permalink / raw)
  To: gcc-bugs


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55192

--- Comment #1 from Joel Sherrill <joel at gcc dot gnu.org> 2012-11-04 03:55:28 UTC ---
Output of git bisect

[joel@baltimore gcc]$ git bisect good
Bisecting: 3 revisions left to test after this (roughly 2 steps)
[5169661db3501031dfeb1971582809a702d6cebe] Integrate lexical block into
source_location.
[joel@baltimore gcc]$ git bisect bad
Bisecting: 0 revisions left to test after this (roughly 1 step)
[d452a16984ecc2f20644649f33c8ee38b246cbf0]     * dbgcnt.def (sched_breakdep):
New counter.     * haifa-sched.c (update_insn_after_change): New static
function,     broken out of haifa_change_pattern.     (haifa_change_pattern):
Call it.     (dep_t heap vecs): Declare.     (INSN_COST): Define earlier.    
(next_cycle_replace_deps, next_cycle_apply): New static     variables.    
(apply_replacement): New static function.     (recompute_todo_spec): New
argument FOR_BACKTRACK.  All callers     changed.  Handle DEP_REPLACE deps.    
(contributes_to_priority_p): False for replaceable deps.    
(must_restore_pattern_p, restore_pattern): New static functions.    
(schedule_insn): Use them.  Apply replacements for broken deps.     (struct
haifa_saved_data): Add new fields to keep track of     replacements.    
(save_backtrack_point): Initialize them.     (undo_replacements_for_backtrack):
New static function.     (restore_last_backtrack_point,
free_topmost_backtrack_point):     Use it and keep track of replacements.    
(perform_replacements_new_cycle, undo_all_replacements): New static    
functions.     (schedule_block): Call these two as necessary.  Call    
find_modifiable_mems.     (try_ready): Tweak the assert.  Check for
DEP_POSTPONED.     * sched-deps.c: Include "emit-rtl.h".     (init_dep_1):
Initialize DEP_NONREG, DEP_MULTIPLE and DEP_REPLACE.     (dep_spec_p): True for
DEP_REPLACE deps.     (mark_as_hard): New static variable.     (update_dep):
Update DEP_NONREG and DEP_MULTIPLE.     (add_dependence_list): New argument
hard.  All callers changed.  Set     and clear mark_as_hard around function
body.     (add_dependence_list_and_free): Likewise.     (haifa_note_mem_dep):
Set DEP_NONREG.     (haifa_note_dep): Likewise if mark_as_hard is true.    
(sched_analyze_insn): Switch loop with if statement testing for    
sel_sched_p.     (struct mem_inc_info): New.     (attempt_change,
parse_add_or_inc, find_inc, find_mem): New static     functions.    
(find_modifiable_mems): New function.     * sched-int.h (struct
dep_replacement): New.     (struct _dep): Add replace, nonreg and multiple
fields.  Make type and     cost bitfields.     (UNKNOWN_DEP_COST): Change to
match the bitfield.     (DEP_NONREG, DEP_MULTIPLE, DEP_REPLACE): New macros.   
 (DEP_POSTPONED): New macro.     (DEP_CANCELLED): Renumber.    
(find_modifiable_mems): Declare.     (enum SCHED_FLAGS): Add
DONT_BREAK_DEPENDENCIES.     * sched-rgn.c (init_ready_list): Set TODO_SPEC
here.     (new_ready): Don't set HARD_DEP, use DEP_POSTPONED.    
(debug_dependencies): Dump DEP_NONREG and DEP_MULTIPLE. * Makefile.in
(sched-deps.o): Update dependencies.     * config/c6x/c6x.c (in_hwloop): New
static variable.     (c6x_set_sched_flags): If it is true, add
DONT_BREAK_DEPENDENCIES.     (hwloop_optimize): Set and clear it around
preliminary scheduling     pass.
[joel@baltimore gcc]$ 
***** I think this might be too far since this appears to be powerpc specific.
[joel@baltimore gcc]$ git bisect bad
Bisecting: 0 revisions left to test after this (roughly 0 steps)
[77ff7cbfe77156dc41943effa80948572fe383fa] 2012-09-19  Tulio Magno Quites
Machado Filho  <tuliom@linux.vnet.ibm.com>
[joel@baltimore gcc]$


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

* [Bug target/55192] bfin generates invalid assembly
  2012-11-03 16:23 [Bug c/55192] New: bfin generates invalid assembly joel at gcc dot gnu.org
  2012-11-04  3:55 ` [Bug target/55192] " joel at gcc dot gnu.org
@ 2015-01-03 19:23 ` joel at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: joel at gcc dot gnu.org @ 2015-01-03 19:23 UTC (permalink / raw)
  To: gcc-bugs

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

Joel Sherrill <joel at gcc dot gnu.org> changed:

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

--- Comment #2 from Joel Sherrill <joel at gcc dot gnu.org> ---
I have an installed bfin-rtems 4.8.3 so I am going to assume this has been
fixed and close it.


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

end of thread, other threads:[~2015-01-03 19:23 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-11-03 16:23 [Bug c/55192] New: bfin generates invalid assembly joel at gcc dot gnu.org
2012-11-04  3:55 ` [Bug target/55192] " joel at gcc dot gnu.org
2015-01-03 19:23 ` joel 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).