Bug 153226 - [mips] Unaligned halfword load is not handled properly in macro assembler
Summary: [mips] Unaligned halfword load is not handled properly in macro assembler
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-01-19 01:02 PST by Julien Brianceau
Modified: 2016-07-14 10:39 PDT (History)
8 users (show)

See Also:


Attachments
Provide a load16Unaligned implementation in mips macro assembler (3.86 KB, patch)
2016-01-19 01:16 PST, Julien Brianceau
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Julien Brianceau 2016-01-19 01:02:06 PST
In mips macro assembler, the load16Unaligned(BaseIndex address, RegisterID dest) implementation is not efficient.
Comment 1 Julien Brianceau 2016-01-19 01:16:27 PST
Created attachment 269259 [details]
Provide a load16Unaligned implementation in mips macro assembler

Note: already contributed in qtwekbit http://code.qt.io/cgit/qt/qtwebkit.git/commit/?id=ea22657d17a934b04c8621dc8891a1d4d80510e3
Comment 2 Julien Brianceau 2016-01-19 01:19:08 PST
SunSpider's regexp-dna results on my mips board:

- without patch

    ============================================
    RESULTS (means and 95% confidence intervals)
    --------------------------------------------
    Total:     353.9ms +/- 0.5%
    --------------------------------------------

      regexp:  353.9ms +/- 0.5%
        dna:   353.9ms +/- 0.5%

- with patch

    ============================================
    RESULTS (means and 95% confidence intervals)
    --------------------------------------------
    Total:     136.5ms +/- 2.6%
    --------------------------------------------

      regexp:  136.5ms +/- 2.6%
        dna:   136.5ms +/- 2.6%
Comment 3 Julien Brianceau 2016-04-12 06:39:14 PDT
Guillaume, do you have any feedback on this one ?
Comment 4 Guillaume Emont 2016-04-12 16:24:58 PDT
(In reply to comment #3)
> Guillaume, do you have any feedback on this one ?

I couldn't say whether this is the fastest solution, though it might well be. It looks correct to me, and it runs well on my device.
Comment 5 Michael Catanzaro 2016-07-14 05:37:58 PDT
Comment on attachment 269259 [details]
Provide a load16Unaligned implementation in mips macro assembler

rs=me. I don't understand all the code, but any error here would clearly be isolated to the MIPS platform, Guillaume has given his unofficial r+, it's been used in QtWebKit for almost two years, and no reviewer is working on MIPS.
Comment 6 Konstantin Tokarev 2016-07-14 10:17:56 PDT
Comment on attachment 269259 [details]
Provide a load16Unaligned implementation in mips macro assembler

Works fine here and improves benchmark results. cq+
Comment 7 WebKit Commit Bot 2016-07-14 10:39:04 PDT
Comment on attachment 269259 [details]
Provide a load16Unaligned implementation in mips macro assembler

Clearing flags on attachment: 269259

Committed r203226: <http://trac.webkit.org/changeset/203226>
Comment 8 WebKit Commit Bot 2016-07-14 10:39:07 PDT
All reviewed patches have been landed.  Closing bug.