Skip to contentSkip to conversation

.section problems in entry.S

DISCUSSION Kip Walker 5 participants 12 messages Dec 7, 2001 – Dec 14, 2001 MIPS

lore
Share & tools
lore

Kip Walker

author
#0 lore raw

I just investigated assembler warnings coming from arch/mips/kernel/entry.S (checked out as of 12/07 00:00 UTC), and noticed the following. After expanding macros, you get something like:

	.text

	.section ".text.init"   (from __INIT)

	.data			(from PANIC)
	.previous		(from PANIC)
	--> section is now .text.init

	.previous		(from __FINIT)
	--> section is now .data, not .text as intended.

Perhaps .pushsection and .popsection should be used in some or all macros like this?

Or am I smoking crack?

Kip

#1 lore raw
Quoted 15 lines · Kip Walker

I just investigated assembler warnings coming from arch/mips/kernel/entry.S (checked out as of 12/07 00:00 UTC), and noticed the following. After expanding macros, you get something like:

	.text

	.section ".text.init"   (from __INIT)

	.data			(from PANIC)
	.previous		(from PANIC)
	--> section is now .text.init

	.previous		(from __FINIT)
	--> section is now .data, not .text as intended.
Quoted 4 lines

Perhaps .pushsection and .popsection should be used in some or all macros like this?

Or am I smoking crack?

Certainly not. The problem is known and so far I've just hacked around it more or less elegant. But it's a trap and so I think we've got good reasons to force people to upgrade to a newer assembler than the current minimal version. The question is which - I don't like frequent tool upgrades.

Ralf

#2 lore raw
Quoted 5 lines · Ralf Baechle

Certainly not. The problem is known and so far I've just hacked around it more or less elegant. But it's a trap and so I think we've got good reasons to force people to upgrade to a newer assembler than the current minimal version. The question is which - I don't like frequent tool upgrades.

There are no working released binutils for a modern MIPS/Linux system,
AFAIK. However, version 2.11.92 from the CVS seems to work reasonably well now, so chances are the next release will do as well. Maybe 2.12 will be a good candidate then, once it is released and tested a bit.

Signature · 3 lines
+  Maciej W. Rozycki, Technical University of Gdansk, Poland   +
+--------------------------------------------------------------+
+        e-mail: [email protected], PGP key available        +
#3 lore raw
Quoted 10 lines · Maciej W. Rozycki
Quoted 5 lines

Certainly not. The problem is known and so far I've just hacked around it more or less elegant. But it's a trap and so I think we've got good reasons to force people to upgrade to a newer assembler than the current minimal version. The question is which - I don't like frequent tool upgrades.

There are no working released binutils for a modern MIPS/Linux system,
AFAIK. However, version 2.11.92 from the CVS seems to work reasonably well now, so chances are the next release will do as well. Maybe 2.12 will be a good candidate then, once it is released and tested a bit.

What is the schedule for 2.12?

Ralf

#4 lore raw

Ralf Baechle wrote:
[snip]

Quoted 6 lines
Quoted 4 lines

There are no working released binutils for a modern MIPS/Linux system,
AFAIK. However, version 2.11.92 from the CVS seems to work reasonably well now, so chances are the next release will do as well. Maybe 2.12 will be a good candidate then, once it is released and tested a bit.

What is the schedule for 2.12?

AFAIK it is to be done in parallel to the GCC schedule:

  2001-12-15  Functionality freeze.
  2002-02-15  Branch for gcc 3.1 and binutils 2.12.
  2002-04-15  Release.

Thiemo

#5 lore raw
Quoted 7 lines · Thiemo Seufer

Ralf Baechle wrote:
[snip]

Quoted 5 lines
Quoted 4 lines

There are no working released binutils for a modern MIPS/Linux system,
AFAIK. However, version 2.11.92 from the CVS seems to work reasonably well now, so chances are the next release will do as well. Maybe 2.12 will be a good candidate then, once it is released and tested a bit.

Quoted 6 lines
Quoted 1 line

What is the schedule for 2.12?

AFAIK it is to be done in parallel to the GCC schedule:

  2001-12-15  Functionality freeze.
  2002-02-15  Branch for gcc 3.1 and binutils 2.12.
  2002-04-15  Release.

Where did you get this information from?

Signature · 2 lines
Daniel Jacobowitz                           Carnegie Mellon University
MontaVista Software                         Debian GNU/Linux Developer
#6 lore raw
Quoted 8 lines · Daniel Jacobowitz
Quoted 7 lines · Thiemo Seufer

Ralf Baechle wrote:
[snip]

Quoted 5 lines
Quoted 4 lines

There are no working released binutils for a modern MIPS/Linux system,
AFAIK. However, version 2.11.92 from the CVS seems to work reasonably well now, so chances are the next release will do as well. Maybe 2.12 will be a good candidate then, once it is released and tested a bit.

Quoted 8 lines
Quoted 6 lines
Quoted 1 line

What is the schedule for 2.12?

AFAIK it is to be done in parallel to the GCC schedule:

  2001-12-15  Functionality freeze.
  2002-02-15  Branch for gcc 3.1 and binutils 2.12.
  2002-04-15  Release.

Where did you get this information from?

The schedule for GCC can be found at http://gcc.gnu.org/develop.html . For the last binutils release there was some connection to the GCC schedule. I _assume_ the next release will be done in a similiar way due to the dependencies between both projects.

Thiemo

#7 lore raw
Quoted 16 lines · Thiemo Seufer
Quoted 15 lines · Daniel Jacobowitz
Quoted 13 lines · Thiemo Seufer

Ralf Baechle wrote:
[snip]

Quoted 6 lines
Quoted 4 lines

There are no working released binutils for a modern MIPS/Linux system,
AFAIK. However, version 2.11.92 from the CVS seems to work reasonably well now, so chances are the next release will do as well. Maybe 2.12 will be a good candidate then, once it is released and tested a bit.

What is the schedule for 2.12?

AFAIK it is to be done in parallel to the GCC schedule:

  2001-12-15  Functionality freeze.
  2002-02-15  Branch for gcc 3.1 and binutils 2.12.
  2002-04-15  Release.
Quoted 6 lines
Quoted 1 line

Where did you get this information from?

The schedule for GCC can be found at http://gcc.gnu.org/develop.html . For the last binutils release there was some connection to the GCC schedule. I _assume_ the next release will be done in a similiar way due to the dependencies between both projects.

Actually, as far as I know there's never been a coupling between GCC and binutils releases. I'm going to try to get 2.12 out before GCC 3.1, though.

Signature · 2 lines
Daniel Jacobowitz                           Carnegie Mellon University
MontaVista Software                         Debian GNU/Linux Developer
#8 lore raw
In reply to Ralf Baechle
Quoted 8 lines · Ralf Baechle
Quoted 6 lines · Maciej W. Rozycki
Quoted 5 lines

Certainly not. The problem is known and so far I've just hacked around it more or less elegant. But it's a trap and so I think we've got good reasons to force people to upgrade to a newer assembler than the current minimal version. The question is which - I don't like frequent tool upgrades.

Quoted 6 lines
Quoted 4 lines

There are no working released binutils for a modern MIPS/Linux system,
AFAIK. However, version 2.11.92 from the CVS seems to work reasonably well now, so chances are the next release will do as well. Maybe 2.12 will be a good candidate then, once it is released and tested a bit.

What is the schedule for 2.12?

There isn't one yet; I'm hoping within three months. I'm going to try to roll the ball a little this week.

Signature · 2 lines
Daniel Jacobowitz                           Carnegie Mellon University
MontaVista Software                         Debian GNU/Linux Developer
#9 lore raw
Quoted 21 lines · Daniel Jacobowitz

Date: Thu, 13 Dec 2001 16:28:16 -0500
From: Daniel Jacobowitz <[email protected]>
To: Ralf Baechle <[email protected]>
Cc: "Maciej W. Rozycki" <[email protected]>,
Kip Walker <[email protected]>, [email protected]
Subject: Re: .section problems in entry.S

Quoted 13 lines · Ralf Baechle
Quoted 10 lines · Maciej W. Rozycki
Quoted 5 lines

Certainly not. The problem is known and so far I've just hacked around it more or less elegant. But it's a trap and so I think we've got good reasons to force people to upgrade to a newer assembler than the current minimal version. The question is which - I don't like frequent tool upgrades.

There are no working released binutils for a modern MIPS/Linux system,
AFAIK. However, version 2.11.92 from the CVS seems to work reasonably well now, so chances are the next release will do as well. Maybe 2.12 will be a good candidate then, once it is released and tested a bit.

Quoted 4 lines
Quoted 1 line

What is the schedule for 2.12?

There isn't one yet; I'm hoping within three months. I'm going to try to roll the ball a little this week.

Longer than I'd like to see. Anybody got a sufficiently hacked version of ~ 2.11?

Ralf

#10 lore raw
Quoted 2 lines · Ralf Baechle

Longer than I'd like to see. Anybody got a sufficiently hacked version of ~ 2.11?

Once I get a patch negotiated with Eric to make option parsing compatible with how we use it now, you'll be able to use 2.12 snapshots...

Signature · 2 lines
Daniel Jacobowitz                           Carnegie Mellon University
MontaVista Software                         Debian GNU/Linux Developer
#11 lore raw
In reply to Ralf Baechle
Quoted 2 lines · Ralf Baechle

Longer than I'd like to see. Anybody got a sufficiently hacked version of ~ 2.11?

My 2.11.2 appears rock-solid with one exception -- its as mishandles la
when used in a 32-bit source after a 64-bit ISA has been set (with e.g. "set .mips3"). I just haven't bothered myself to fix it and switched to 2.11.92 instead. I have no idea if it works for ELF64, either.

Signature · 3 lines
+  Maciej W. Rozycki, Technical University of Gdansk, Poland   +
+--------------------------------------------------------------+
+        e-mail: [email protected], PGP key available        +