The default bug view has changed. See this FAQ.

IonMonkey: Refactor MCallOptimize.cpp

RESOLVED FIXED

Status

()

Core
JavaScript Engine
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: sstangl, Assigned: sstangl)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Assignee)

Description

5 years ago
File is large and mostly comprised of a single function with oodles of indentation. Should be prettified.
(Assignee)

Comment 1

5 years ago
Created attachment 636889 [details] [diff] [review]
Refactor MCallOptimize.
Attachment #636889 - Flags: review?(dvander)
Comment on attachment 636889 [details] [diff] [review]
Refactor MCallOptimize.

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

Thanks for doing this, it's about a trillion times more readable now.

::: js/src/ion/CodeGenerator.cpp
@@ +990,4 @@
>      types::TypeObject *typeObj = lir->mir()->type();
>      uint32 count = lir->mir()->count();
>  
> +    JS_ASSERT((int32_t)count >= 0);

whoops
Attachment #636889 - Flags: review?(dvander) → review+
(Assignee)

Comment 3

5 years ago
http://hg.mozilla.org/projects/ionmonkey/rev/54c888b66524
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
Thanks for refactoring MCallOptimize function :)

This was on my todo list but I did not found a good way to split on discardCallArgs such as we can split the original function in 2 pieces only returning boolean values — the first being the ability to split, and the second the ability to compile.

The current method first select base on the native function before extracting any argument info in each specialized function.  This duplication does not seems to be armful as only function calls are duplicated.
You need to log in before you can comment on or make changes to this bug.