Skip to contentSkip to conversation

ARM: VFP: preserve the HW context when calling signal handlers

RFC PATCH New Siarhei Siamashka 3 participants 5 messages Jan 4, 2010 – Jan 13, 2010 5 messages not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): c70d85c1a0b20b5f227f34b32db674c7b362d72d.1242734510.git.imre.deak@nokia.com

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

#3 lore raw

RFC PATCH 2/2 ARM: VFP: preserve the HW context when calling signal handlers

Quoted 5 lines · On Monday 04 January 2010 16:25:49 ext Russell King - ARM Linux wrote:
Quoted 4 lines · Siarhei Siamashka
Quoted 2 lines · On Saturday 13 June 2009 20:04:06 ext Russell King - ARM Linux wrote:

- wait for a new patch which includes these other registers and not have any ABI visible changes to contend with

Quoted 8 lines
Quoted 2 lines

Sorry for bumping this old thread, but what is the current status of these patches?

What happened was that the 2nd option was decided upon, and then the thread died, and probably everyone forgot about it.

So, I'm doing exactly what I said I'd do in the second option. I'm just still waiting some six months on...

OK, it's understandable. The issue just got a bit more popular now than it used to be six months ago.

Quoted 2 lines

If someone comes up with a tested patch, then its something we should sort out.

Thanks for clarifying the situation.

For now I'll keep advising people to use old Imre's patches (1st option) until it is decided who, how, and when is going to fix it in a right way (2nd option).

Signature · 2 lines
Best regards,
Siarhei Siamashka
#4 lore raw

RFC PATCH 2/2 ARM: VFP: preserve the HW context when calling signal handlers

Quoted 15 lines · Siamashka Siarhei (Nokia-D/Helsinki)
Quoted 5 lines · On Monday 04 January 2010 16:25:49 ext Russell King - ARM Linux wrote:
Quoted 4 lines · Siarhei Siamashka
Quoted 2 lines · On Saturday 13 June 2009 20:04:06 ext Russell King - ARM Linux wrote:

- wait for a new patch which includes these other registers and not have any ABI visible changes to contend with

Quoted 8 lines
Quoted 2 lines

Sorry for bumping this old thread, but what is the current status of these patches?

What happened was that the 2nd option was decided upon, and then the thread died, and probably everyone forgot about it.

So, I'm doing exactly what I said I'd do in the second option. I'm just still waiting some six months on...

Quoted 7 lines

OK, it's understandable. The issue just got a bit more popular now than it used to be six months ago.

Quoted 2 lines

If someone comes up with a tested patch, then its something we should sort out.

Thanks for clarifying the situation.

Jamie, you raised the question of FP emulation in user space; could you provide the VFP registers needed for that in addition to the already saved ones? With that info I could update the patch so it's acceptable for everyone.

Thanks,
Imre

#5 lore raw

RFC PATCH 2/2 ARM: VFP: preserve the HW context when callingsignal handlers

Quoted 19 lines · Imre Deak
Quoted 18 lines · Siamashka Siarhei (Nokia-D/Helsinki)
Quoted 5 lines · On Monday 04 January 2010 16:25:49 ext Russell King - ARM Linux wrote:
Quoted 4 lines · Siarhei Siamashka
Quoted 2 lines · On Saturday 13 June 2009 20:04:06 ext Russell King - ARM Linux wrote:

- wait for a new patch which includes these other registers and not have any ABI visible changes to contend with

Quoted 8 lines
Quoted 2 lines

Sorry for bumping this old thread, but what is the current status of these patches?

What happened was that the 2nd option was decided upon, and then the thread died, and probably everyone forgot about it.

So, I'm doing exactly what I said I'd do in the second option. I'm just still waiting some six months on...

OK, it's understandable. The issue just got a bit more popular now than it used to be six months ago.

Quoted 8 lines
Quoted 4 lines
Quoted 2 lines

If someone comes up with a tested patch, then its something we should sort out.

Thanks for clarifying the situation.

Jamie, you raised the question of FP emulation in user space; could you provide the VFP registers needed for that in addition to the already saved ones? With that info I could update the patch so it's acceptable for everyone.

I think you need to save all of FPSCR, FPEXC, FPINST, FPINST2. The information in the latter 2 registers is only relevant if corresponding bits in FPEXC are set (like EX and FP2V). A signal handler could decide whether to use them or not.

Signature · 1 line
Catalin
#6 lore raw

RFC PATCH 2/2 ARM: VFP: preserve the HW context when callingsignal handlers

Quoted 25 lines · ext Catalin Marinas
Quoted 24 lines · Imre Deak
Quoted 22 lines · Siamashka Siarhei (Nokia-D/Helsinki)
Quoted 5 lines · On Monday 04 January 2010 16:25:49 ext Russell King - ARM Linux wrote:
Quoted 4 lines · Siarhei Siamashka
Quoted 2 lines · On Saturday 13 June 2009 20:04:06 ext Russell King - ARM Linux wrote:

- wait for a new patch which includes these other registers and not have any ABI visible changes to contend with

Quoted 8 lines
Quoted 2 lines

Sorry for bumping this old thread, but what is the current status of these patches?

What happened was that the 2nd option was decided upon, and then the thread died, and probably everyone forgot about it.

So, I'm doing exactly what I said I'd do in the second option. I'm just still waiting some six months on...

OK, it's understandable. The issue just got a bit more popular now than it used to be six months ago.

Quoted 2 lines

If someone comes up with a tested patch, then its something we should sort out.

Thanks for clarifying the situation.

Quoted 8 lines
Quoted 3 lines

Jamie, you raised the question of FP emulation in user space; could you provide the VFP registers needed for that in addition to the already saved ones? With that info I could update the patch so it's acceptable for everyone.

I think you need to save all of FPSCR, FPEXC, FPINST, FPINST2. The information in the latter 2 registers is only relevant if corresponding bits in FPEXC are set (like EX and FP2V). A signal handler could decide whether to use them or not.

Thanks for the info, I'll try to update my patches based on this.

--Imre

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

#9 lore raw

RFC PATCH 2/2 ARM: VFP: preserve the HW context when calling signal handlers

Quoted 29 lines · On Saturday 13 June 2009 20:04:06 ext Russell King - ARM Linux wrote:
Quoted 10 lines · Jamie Lokier
Quoted 9 lines · Russell King - ARM Linux

It seems that people do want access to these registers in signal handlers, yet there's still the original set of patches from Imre in the patch system.

I'm been holding off applying them because of this open question.

What am I to do with them? Are people happy with the existing patches?

Quoted 6 lines
Quoted 2 lines

(note that without the patch system, I'd have completely forgotten about those two patches and so would not be sending this chase-up.)

The main thing is that all the machine state which affects user-space which is saved on entering a signal handler, and restored on leaving it, is accessible somehow through the arguments to the signal handler.

I agree that we need something. However, there seemed to be some kind of agreement in this thread that having access to these other registers from signal handlers would be a good thing.

So, what I'm asking is, do I:

- merge the current two patches in the patch system, and then at a later date have to change the layout when someone wants access to these other registers, thereby causing an ABI visible change with all the problems that goes with that

Quoted 4 lines

or

- wait for a new patch which includes these other registers and not have any ABI visible changes to contend with

Sorry for bumping this old thread, but what is the current status of these patches?

This bug shows up as image corruption (typically it looks like short horizontal stripes all over the screen) when using NEON optimized pixman library and scrolling pages in firefox for example.

X server uses signal handlers for processing input, and they corrupt content of NEON registers which are heavily used by pixman to process pixel data.

The problem has been already encountered by the maintainers of several linux distributions (angstrom, ubuntu).

Signature · 2 lines
Best regards,
Siarhei Siamashka