[Bug target/55712] cpuinfo.c doesn't compile for x86-64 with medium memory model

2013-01-06 Thread ubizjak at gmail dot com


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



Uros Bizjak  changed:



   What|Removed |Added



 Status|ASSIGNED|RESOLVED

URL|http://gcc.gnu.org/ml/gcc-p |http://gcc.gnu.org/ml/gcc-p

   |atches/2012-12/msg01391.htm |atches/2012-12/msg01484.htm

   |l   |l

 Resolution||FIXED

   Target Milestone|4.8.0   |4.7.3



--- Comment #10 from Uros Bizjak  2013-01-06 09:15:43 
UTC ---

Fixed.


[Bug target/55712] cpuinfo.c doesn't compile for x86-64 with medium memory model

2013-01-06 Thread uros at gcc dot gnu.org


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



--- Comment #9 from uros at gcc dot gnu.org 2013-01-06 08:45:48 UTC ---

Author: uros

Date: Sun Jan  6 08:45:43 2013

New Revision: 194937



URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=194937

Log:

Backport from mainline

2013-01-03  Uros Bizjak  



PR target/55712

* config/i386/i386-c.c (ix86_target_macros_internal): Depending on

selected code model, define __code_mode_small__, __code_model_medium__,

__code_model_large__, __code_model_32__ or __code_model_kernel__.

* config/i386/cpuid.h (__cpuid, __cpuid_count) [__i386__]: Prefix

xchg temporary register with %k.  Declare temporary register as

early clobbered.

[__x86_64__]: For medium and large code models, preserve %rbx register.





Modified:

branches/gcc-4_7-branch/gcc/ChangeLog

branches/gcc-4_7-branch/gcc/config/i386/cpuid.h

branches/gcc-4_7-branch/gcc/config/i386/i386-c.c


[Bug target/55712] cpuinfo.c doesn't compile for x86-64 with medium memory model

2013-01-03 Thread uros at gcc dot gnu.org


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



--- Comment #8 from uros at gcc dot gnu.org 2013-01-03 17:16:30 UTC ---

Author: uros

Date: Thu Jan  3 17:16:08 2013

New Revision: 194862



URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=194862

Log:

PR target/55712

* config/i386/i386-c.c (ix86_target_macros_internal): Depending on

selected code model, define __code_mode_small__, __code_model_medium__,

__code_model_large__, __code_model_32__ or __code_model_kernel__.

* config/i386/cpuid.h (__cpuid, __cpuid_count) [__i386__]: Prefix

xchg temporary register with %k.  Declare temporary register as

early clobbered.

[__x86_64__]: For medium and large code models, preserve %rbx register.





Modified:

trunk/gcc/ChangeLog

trunk/gcc/config/i386/cpuid.h

trunk/gcc/config/i386/i386-c.c


[Bug target/55712] cpuinfo.c doesn't compile for x86-64 with medium memory model

2012-12-27 Thread ubizjak at gmail dot com


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



Uros Bizjak  changed:



   What|Removed |Added



  Attachment #29039|0   |1

is obsolete||



--- Comment #7 from Uros Bizjak  2012-12-27 08:11:40 
UTC ---

Created attachment 29053

  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=29053

Patch that preserves %rbx over cpuid insn



Alternative patch that avoids changing %rbx PIC register.


[Bug target/55712] cpuinfo.c doesn't compile for x86-64 with medium memory model

2012-12-24 Thread leif at rdos dot net


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



--- Comment #6 from Leif Ekblad  2012-12-24 17:53:00 UTC 
---

Confirmed to work with medium memory model (x86_64-pc-rdos).


[Bug target/55712] cpuinfo.c doesn't compile for x86-64 with medium memory model

2012-12-24 Thread ubizjak at gmail dot com


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



Uros Bizjak  changed:



   What|Removed |Added



 Status|UNCONFIRMED |ASSIGNED

URL||http://gcc.gnu.org/ml/gcc-p

   ||atches/2012-12/msg01391.htm

   ||l

   Keywords|ra  |

   Last reconfirmed||2012-12-24

  Component|libgcc  |target

 AssignedTo|unassigned at gcc dot   |ubizjak at gmail dot com

   |gnu.org |

 Ever Confirmed|0   |1

   Target Milestone|--- |4.8.0



--- Comment #5 from Uros Bizjak  2012-12-24 15:43:02 
UTC ---

Please try patch at [1]



[1] http://gcc.gnu.org/ml/gcc-patches/2012-12/msg01391.html