aboutsummaryrefslogtreecommitdiff
path: root/gcc/config
diff options
context:
space:
mode:
authorKai Tietz <kai.tietz@onevision.com>2010-05-31 14:06:41 +0000
committerKai Tietz <ktietz@gcc.gnu.org>2010-05-31 16:06:41 +0200
commit877a19bfb8f34344702b206a549c61f7466fdf01 (patch)
tree5992ffe81b6e7facb8772cf3768b0500320e4126 /gcc/config
parentc5d01958a7b919d0407e8982d70e52fafa8588d2 (diff)
downloadgcc-877a19bfb8f34344702b206a549c61f7466fdf01.zip
gcc-877a19bfb8f34344702b206a549c61f7466fdf01.tar.gz
gcc-877a19bfb8f34344702b206a549c61f7466fdf01.tar.bz2
re PR target/44161 (__attribute__((__target__)) resets pic flag causing spurious warnings)
2010-05-31 Kai Tietz <kai.tietz@onevision.com> PR target/44161 * config/i386/cygming.h (SUBTARGET_OVERRIDE_OPTIONS): Handle flag_pic. From-SVN: r160070
Diffstat (limited to 'gcc/config')
-rw-r--r--gcc/config/i386/cygming.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/gcc/config/i386/cygming.h b/gcc/config/i386/cygming.h
index 71a5d8d..999cb6e 100644
--- a/gcc/config/i386/cygming.h
+++ b/gcc/config/i386/cygming.h
@@ -152,7 +152,15 @@ union tree_node;
#undef SUBTARGET_OVERRIDE_OPTIONS
#define SUBTARGET_OVERRIDE_OPTIONS \
do { \
- if (flag_pic) \
+ if (TARGET_64BIT && flag_pic != 1) \
+ { \
+ if (flag_pic > 1) \
+ warning (0, \
+ "-fPIC ignored for target (all code is position independent)"\
+ ); \
+ flag_pic = 1; \
+ } \
+ else if (!TARGET_64BIT && flag_pic) \
{ \
warning (0, "-f%s ignored for target (all code is position independent)",\
(flag_pic > 1) ? "PIC" : "pic"); \