Closed Bug 1061229 Opened 7 years ago Closed 7 years ago

SIMD (interpreter): Add coercive calls

Categories

(Core :: JavaScript: Standard Library, defect)

x86_64
Linux
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla35

People

(Reporter: bbouvier, Assigned: bbouvier)

Details

Attachments

(1 file, 1 obsolete file)

Coercive calls (with the form x=SIMD.int32x4(x)) shouldn't be only a part of asm.js, but should be implemented in the interpreter as well. That will also allow us to compare asm.js and non-asmjs (interpreter only) variants of the demos.
Attached patch bug1061229.patch (obsolete) — Splinter Review
Steve, mrgiggles told you can review SIMD.cpp :) That should be a really easy review, and hopefully we'd land this before the end of the week.
Attachment #8482301 - Flags: review?(sphink)
Attached patch bug1061229.patchSplinter Review
Hannes proposed to review this one :)
Attachment #8482301 - Attachment is obsolete: true
Attachment #8482301 - Flags: review?(sphink)
Attachment #8482614 - Flags: review?(hv1989)
Comment on attachment 8482614 [details] [diff] [review]
bug1061229.patch

Review of attachment 8482614 [details] [diff] [review]:
-----------------------------------------------------------------

Lgtm

::: js/src/builtin/SIMD.cpp
@@ +307,5 @@
>      const unsigned LANES = 4;
>  
> +    if (args.length() == 1) {
> +        // X4 type used as a coercion
> +        if (!CheckVectorObject(args[0], args.callee().as<X4TypeDescr>().type())) {

You can move the declaration of descr[0] above here. So you can just use "descr.type()" instead.

[0] http://dxr.mozilla.org/mozilla-central/source/js/src/builtin/SIMD.cpp?from=simd.cpp&case=true#315"
Attachment #8482614 - Flags: review?(hv1989) → review+
https://hg.mozilla.org/mozilla-central/rev/2cd12da0c4e6
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla35
You need to log in before you can comment on or make changes to this bug.