Closed Bug 1036037 Opened 8 years ago Closed 8 years ago

jsapi-tests for JIT optimizations

Categories

(Core :: JavaScript Engine: JIT, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla33

People

(Reporter: sunfish, Assigned: sunfish)

References

Details

Attachments

(1 file)

While reviewing bug 999764, a way to write unit tests for JIT optimizations was missed. Inspired by js/src/jsapi-tests/testJitRValueAlloc.cpp, it seems we now have a way to add jsapi-tests tests that test JIT features.

Attached is a patch which adds a testcase that tests the feature added in bug 999764. I'm unsure if this is a good approach, but it seems to work.
Attachment #8452596 - Flags: review?(nicolas.b.pierron)
Comment on attachment 8452596 [details] [diff] [review]
div-reciprocal-test.patch

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

::: js/src/jsapi-tests/testJitFoldsTo.cpp
@@ +19,5 @@
> +
> +struct MinimalFunc
> +{
> +    LifoAlloc lifo;
> +    TempAllocator alloc;

Nice :)

Might be worth adding to a new jsapi-tests header dedicated to making Ion tests.
Attachment #8452596 - Flags: review?(nicolas.b.pierron) → review+
https://hg.mozilla.org/integration/mozilla-inbound/rev/a61e96de3acb

A jsapi-tests header for Ion tests is a good idea. We can do that when we add more tests :).
https://hg.mozilla.org/mozilla-central/rev/a61e96de3acb
Assignee: nobody → sunfish
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla33
You need to log in before you can comment on or make changes to this bug.