public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/40722] [4.5/4.6 Regression] ia32intrin.h defines of _rotl, _rotr conflict with target stdlib.h  decls
       [not found] <bug-40722-4@http.gcc.gnu.org/bugzilla/>
@ 2010-12-16 13:23 ` rguenth at gcc dot gnu.org
  2011-02-03  9:07 ` jakub at gcc dot gnu.org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu.org @ 2010-12-16 13:23 UTC (permalink / raw)
  To: gcc-bugs

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

Richard Guenther <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.5.2                       |4.5.3

--- Comment #17 from Richard Guenther <rguenth at gcc dot gnu.org> 2010-12-16 13:03:28 UTC ---
GCC 4.5.2 is being released, adjusting target milestone.


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

* [Bug target/40722] [4.5/4.6 Regression] ia32intrin.h defines of _rotl, _rotr conflict with target stdlib.h  decls
       [not found] <bug-40722-4@http.gcc.gnu.org/bugzilla/>
  2010-12-16 13:23 ` [Bug target/40722] [4.5/4.6 Regression] ia32intrin.h defines of _rotl, _rotr conflict with target stdlib.h decls rguenth at gcc dot gnu.org
@ 2011-02-03  9:07 ` jakub at gcc dot gnu.org
  2011-02-03 10:06 ` jakub at gcc dot gnu.org
  2011-02-03 12:29 ` ktietz at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: jakub at gcc dot gnu.org @ 2011-02-03  9:07 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org

--- Comment #18 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-02-03 09:07:12 UTC ---
(In reply to comment #8)
> (In reply to comment #7)
> > An updated patch is at
> > 
> > http://gcc.gnu.org/ml/gcc-patches/2010-03/msg00937.html
> > 
> 
> Patch is fine. It is absolutely necessary to support gcc's intrinsic headers
> for mingw. The fixinclude approach is one way to solve it and I am fine by it.
> For mingw-w64 we used the #pragma push/pop_macro feature to make sure we
> declare function without getting problems by this define in ia32intrin.h.
> 
> Kai

Why can't you just
_CRTIMP unsigned int __cdecl __MINGW_NOTHROW (_rotl)(unsigned int, int)
__MINGW_ATTRIB_CONST;
?
_rotl etc. from ia32intrin.h is a function-like macro, so the above prevents
the expansion.
Is this still a problem on *mingw and *mingw64?  I mean, if x86intrin.h can't
be included, it sounds like a serious problem for those that use this arch, and
it is open for more than a year.
I guess H.J.'s patch is just too dangerous, it assumes that _rotl is the first
declaration and _lrotr is the last one, I guess much better would be to ifdef
out
each declaration separately, then there wouldn't be issues with unmatched
#if/#endif.


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

* [Bug target/40722] [4.5/4.6 Regression] ia32intrin.h defines of _rotl, _rotr conflict with target stdlib.h  decls
       [not found] <bug-40722-4@http.gcc.gnu.org/bugzilla/>
  2010-12-16 13:23 ` [Bug target/40722] [4.5/4.6 Regression] ia32intrin.h defines of _rotl, _rotr conflict with target stdlib.h decls rguenth at gcc dot gnu.org
  2011-02-03  9:07 ` jakub at gcc dot gnu.org
@ 2011-02-03 10:06 ` jakub at gcc dot gnu.org
  2011-02-03 12:29 ` ktietz at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: jakub at gcc dot gnu.org @ 2011-02-03 10:06 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #19 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-02-03 10:05:58 UTC ---
Created attachment 23233
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=23233
gcc46-pr40722.patch

Modified H.J.'s patch which just adds ()s around _rotl/_rotr/_lrotl/_lrotr
names in their prototypes, all I've tested is the sed command on mingw.org and
mingw64 stdlib.h and eyeballed the differences.
Can anyone please test this both with mingw64 and mingw.org stdlib.h?
Thanks.


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

* [Bug target/40722] [4.5/4.6 Regression] ia32intrin.h defines of _rotl, _rotr conflict with target stdlib.h  decls
       [not found] <bug-40722-4@http.gcc.gnu.org/bugzilla/>
                   ` (2 preceding siblings ...)
  2011-02-03 10:06 ` jakub at gcc dot gnu.org
@ 2011-02-03 12:29 ` ktietz at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: ktietz at gcc dot gnu.org @ 2011-02-03 12:29 UTC (permalink / raw)
  To: gcc-bugs

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

Kai Tietz <ktietz at gcc dot gnu.org> changed:

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

--- Comment #20 from Kai Tietz <ktietz at gcc dot gnu.org> 2011-02-03 12:29:18 UTC ---
So, as more as I think about it, come to the point that this fix-include for
stdlib.h isn't something good. The correct solution here is that mingw.org
fixes their stdlib.h header by () (as suggested by this fix-include sed
command, which by the way works as expected without clobbering ifdef/else
blocks).
The issue I see here is, that the local include directory (LOCAL_INCLUDE_DIR)
comes before fix-include in include order. So for a native configuration, this
won't solve anything as it won't be used at all.

So IMHO, this problem should be closed as invalid.


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

* [Bug target/40722] [4.5/4.6 Regression] ia32intrin.h defines of _rotl, _rotr conflict with target stdlib.h  decls
  2009-07-11 22:07 [Bug target/40722] New: ia32intrin.h defines of _rotl, _rotr conflict with target stdlib.h decls.h dannysmith at users dot sourceforge dot net
@ 2010-07-31  9:35 ` rguenth at gcc dot gnu dot org
  0 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-07-31  9:35 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #16 from rguenth at gcc dot gnu dot org  2010-07-31 09:29 -------
GCC 4.5.1 is being released, adjusting target milestone.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.5.1                       |4.5.2


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


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

end of thread, other threads:[~2011-02-03 12:29 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-40722-4@http.gcc.gnu.org/bugzilla/>
2010-12-16 13:23 ` [Bug target/40722] [4.5/4.6 Regression] ia32intrin.h defines of _rotl, _rotr conflict with target stdlib.h decls rguenth at gcc dot gnu.org
2011-02-03  9:07 ` jakub at gcc dot gnu.org
2011-02-03 10:06 ` jakub at gcc dot gnu.org
2011-02-03 12:29 ` ktietz at gcc dot gnu.org
2009-07-11 22:07 [Bug target/40722] New: ia32intrin.h defines of _rotl, _rotr conflict with target stdlib.h decls.h dannysmith at users dot sourceforge dot net
2010-07-31  9:35 ` [Bug target/40722] [4.5/4.6 Regression] ia32intrin.h defines of _rotl, _rotr conflict with target stdlib.h decls rguenth at gcc dot gnu dot 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).