Re: [RFC] Eliminate NESTED_ATTR_FUNC

2009-09-03 Thread Vladimir 'phcoder' Serbinenko
Hi, Oh, I was wrong previously, gcc does respect __attribute__ ((__regparm__ (3))) flag (I forget to add -Os so it still uses stack to store value). And the bug is still there ! Try this test program: I confirm with gcc-4.4 This is a grave problem then. This check was added by Marco Gerards

Re: [RFC] Eliminate NESTED_ATTR_FUNC

2009-09-03 Thread Paolo Bonzini
#includestdio.h void foo (int a, int b, void (*hook) (int aa, int bb, int cc)) { b += a; hook (a, b, a + b); } void qq (int a) { auto void q1 (int aa, int bb, int cc); void q1 (int aa, int bb, int cc) { printf (%d %d %d\n, a, aa + bb, cc); } foo (a, a + 1, q1); } int

Re: [RFC] Eliminate NESTED_ATTR_FUNC

2009-09-03 Thread Vladimir 'phcoder' Serbinenko
On Thu, Sep 3, 2009 at 5:54 PM, Paolo Bonzinibonz...@gnu.org wrote: #includestdio.h void foo (int a, int b, void (*hook) (int aa, int bb, int cc)) {  b += a;  hook (a, b, a + b); } void qq (int a) {  auto void q1 (int aa, int bb, int cc);  void q1 (int aa, int bb, int cc)    {