On Mon, Aug 04, 2008 at 11:03:34AM +0200, Petter Reinholdtsen wrote: > > On m68k, some bits of memory must be aligned on a 2-byte boundary. The > > above makes that impossible. > > I notice all the other architectures handled this code. This make me > wonder if this could be seen as a bug in the compiler on m68k. Why > does it not calculate the required 2-byte alignment if it need the > data to be aligned on 2-byte boundaries?
If you explicitly specify alignment like that, you disable any automatic stuff the compiler might otherwise want to perform. If you do not specify an explicit alignment requirement, the compiler will happily align everything on 2-byte boundaries when it needs to, no problem. The bug is not in the compiler. > Note, I am not against changing the code of insserv to get it working > on m68k, but I want to understand why the correct fix is in that code, > and not in the compiler on m68k, when the code work on all other > architectures. It is definately not a bug in the compiler to attempt to follow the programmer's directives and to barf out if that is impossible... > What is the value of sizeof(regex_t) on m68k? What is the alignment > calculated for the struct? > > Happy hacking, > -- > Petter Reinholdtsen > -- <Lo-lan-do> Home is where you have to wash the dishes. -- #debian-devel, Freenode, 2004-09-22 -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

