3 msgcfg representation

need help with builtin function prototypes
\ DJ Delorie (9 Aug 2007)
. \ Ian Lance Taylor (9 Aug 2007)
. . \ DJ Delorie (9 Aug 2007)
. \ Kaveh R. GHAZI (10 Aug 2007)
. . \ DJ Delorie (10 Aug 2007)

7 msgmips gcc -O1: Address exception error on store ...
2 msgcan't bootstrap current trunk on cygwin: tree.c...
3 msgcan't bootstrap current trunk: internal compile...
2 msgBootstrap failure on i386-pc-linux-gnu
1 msgbootstrap failure on hppa-unknown-linux-gnu
1 msgZdenek Dvorak appointed loop infrastructure mai...
4 msgFixed function compilation order
2 msgx86_64 ABI
1 msg[tuples] gimplification of other FEs and platforms
22 msg[RFC] Migrate pointers to members to the middle...
10 msgBootstrap failed on i386-pc-solaris2.10
2 msgSpeedup area - Strings/Identifiers
3 msgAltiVec stack boundary
2 msgWhat 64-bit CPU targets dominate in the future?
1 msgQuestion about PR tree-optimization/32941, boot...
1 msggcc-4.1-20070806 is now available
5 msgGCC Testsuite question (C checks in Fortran suite)
2 msgx64_64-elf support
Subject:need help with builtin function prototypes
Group:Gcc
From:DJ Delorie
Date:9 Aug 2007



Could someone provide a hint for me? I'm trying to put in "real"
prototypes for a builtin function where the arguments don't follow the
default promotion rules. Specifically, one of the arguments is a
reference type (like C++'s "int&"). However, I'm bumping into two
problems:

1. The compiler emits a compatibility warning:

dj.c:4: warning: incompatible implicit declaration of built-in function 'mep_and'

2. The compiler seems to be using the implicit declaration instead of
the builtin one, resulting in the builtin's arguments being
incorrect, especially when optimizing:

dj.c:4: error: non-lvalue passed to argument 1 of `mep_and'

Is there a trick to this? I need this type of functionality because
some builtins modify multiple values, so a simple return value is
insufficient, plus this worked with older versions of gcc so our users
are used to it syntax-wise.

Parameters:

<reference_type 0xb7ee3680
type <integer_type 0xb7e922d8 int public SI
size <integer_cst 0xb7e82228 constant invariant 32>
unit size <integer_cst 0xb7e82060 constant invariant 4>
align 32 symtab 0 alias set -1 canonical type 0xb7e922d8 precision 32 min <integer_cst 0xb7e821e0 -2147483648> max <integer_cst 0xb7e821f8 2147483647>
pointer_to_this <pointer_type 0xb7e9b9c0> reference_to_this <reference_type 0xb7ee3680>>
unsigned SI size <integer_cst 0xb7e82228 32> unit size <integer_cst 0xb7e82060 4>
align 32 symtab 0 alias set -1 canonical type 0xb7ee3680>

<integer_type 0xb7e922d8 int public SI
size <integer_cst 0xb7e82228 type <integer_type 0xb7e92068 bit_size_type> constant invariant 32>
unit size <integer_cst 0xb7e82060 type <integer_type 0xb7e92000 unsigned int> constant invariant 4>
align 32 symtab 0 alias set -1 canonical type 0xb7e922d8 precision 32 min <integer_cst 0xb7e821e0 -2147483648> max <integer_cst 0xb7e821f8 2147483647>
pointer_to_this <pointer_type 0xb7e9b9c0>>

Implicit function:

<function_type 0xb7eec618
type <integer_type 0xb7ee02d8 int public SI
size <integer_cst 0xb7ed0228 constant invariant 32>
unit size <integer_cst 0xb7ed0060 constant invariant 4>
align 32 symtab 0 alias set -1 canonical type 0xb7ee02d8 precision 32 min <integer_cst 0xb7ed01e0 -2147483648> max <integer_cst 0xb7ed01f8 2147483647>
pointer_to_this <pointer_type 0xb7ee99c0> reference_to_this <reference_type 0xb7f31680>>
HI
size <integer_cst 0xb7ed0198 type <integer_type 0xb7ee0068 bit_size_type> constant invariant 16>
unit size <integer_cst 0xb7ed01b0 type <integer_type 0xb7ee0000 unsigned int> constant invariant 2>
align 16 symtab 0 alias set -1 structural equality>

Explicit function:

<function_type 0xb7f316e8
type <void_type 0xb7ee95b0 void VOID
align 8 symtab 0 alias set -1 canonical type 0xb7ee95b0
pointer_to_this <pointer_type 0xb7ee9618>>
HI
size <integer_cst 0xb7ed0198 type <integer_type 0xb7ee0068 bit_size_type> constant invariant 16>
unit size <integer_cst 0xb7ed01b0 type <integer_type 0xb7ee0000 unsigned int> constant invariant 2>
align 16 symtab 0 alias set -1 structural equality
arg-types <tree_list 0xb7f34870
value <reference_type 0xb7f31680 type <integer_type 0xb7ee02d8 int>
unsigned SI
size <integer_cst 0xb7ed0228 constant invariant 32>
unit size <integer_cst 0xb7ed0060 constant invariant 4>
align 32 symtab 0 alias set -1 canonical type 0xb7f31680>
chain <tree_list 0xb7f34858 value <integer_type 0xb7ee02d8 int>>>>



© 2004-2008 readlist.com