Closed Bug 195736 Opened 22 years ago Closed 22 years ago

Small change to xptcinvoke_gcc_x86_unix.cpp

Categories

(Core :: XPConnect, defect, P3)

x86
Linux
defect

Tracking

()

VERIFIED FIXED
mozilla1.5alpha

People

(Reporter: tenthumbs, Assigned: dbradley)

Details

Attachments

(1 file, 1 obsolete file)

I was going over some old notes for bug 140412 and bug 168508 and i found that I had forgotten a change to make xptcinvoke use the regparm calling convention just as xptcstubs does. As I looked at it, I noticed that mozilla can theoretically pass 64-bit quantities, like doubles, which work better if they're properly aligned. While the rest of mozilla doesn't know about such things, it's easy to align the data block created in XPTC_InvokeByIndex. I'll attach a patch. Since it saves a few instructions there is some minuscule performance improvement. :-)
Attached patch xptcall patch (obsolete) — Splinter Review
Switches from stdcall to regparm calling convention internally and marks wher alignment may be useful.
Comment on attachment 116091 [details] [diff] [review] xptcall patch r=dbradley I don't have any way to verify this patch. I assume you ran TestXPTCInvoke and it didn't report any additional errors.
Attachment #116091 - Flags: superreview?(shaver)
Attachment #116091 - Flags: review+
Status: NEW → ASSIGNED
Priority: -- → P3
Target Milestone: --- → mozilla1.5alpha
Yes, I tested it. I have to update the patch. Stand by for a new version.
Attachment #116091 - Flags: superreview?(shaver)
dbradley's review is enough for me, on the new patch.
Attached patch revised patchSplinter Review
This should do it. It works on my tree form a few days ago. I'm updating and rebuilding but there shouldn't be any problem. There are some comments about alignment. It would be interesting to see if they make any perceptible difference. Also note that gcc 3.2.2 tries hard to maintain stack alignment but xptcinvoke messes it up and there's no way at the moment to fix that. It may be a prblem down the road.
Attachment #116091 - Attachment is obsolete: true
Comment on attachment 120581 [details] [diff] [review] revised patch r=dbradley
Attachment #120581 - Flags: review+
Patch checked in
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Checkin verified -
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: