This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

snapshot 20010514: -fno-vtable-thunks


Support for -fno-vtable-thunks seems to have been partially removed:

- DEFAULT_VTABLE_THUNK is no longer used, but it's still defined (even
  as zero) for some targets and it is still documented

- A comment in cp/decl2.c contradicts the code (the default is *on*):

	/* True if we want to implement vtables using "thunks".
	   The default is off.  */
	
	int flag_vtable_thunks = 1;

- And finally, the implementation of -fno-vtable-thunks is
  broken:

  ////////////////////////////////////////////////////////////////////////////
  struct foo
  {
    virtual void bar ();
  };
  ////////////////////////////////////////////////////////////////////////////
  
  <internal>:0: the ABI requires vtable thunks
  foo.cc:2: cannot convert `void*' to `int' in initialization
  foo.cc:2: cannot convert `const __vtbl_ptr_type' to `int' in initialization

If -fno-vtable-thunks is supposed to have been removed, the current
behavior and documentation is confusing.

If -fno-vtable-thunks is supposed to still work, it needs fixing.

-- 
  Eberhard Mattes


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]