Closed Bug 1134359 Opened 5 years ago Closed 5 years ago

Remove maybeStrSpecial

Categories

(Core :: JavaScript Engine, defect)

x86_64
Linux
defect
Not set

Tracking

()

RESOLVED FIXED
mozilla38
Tracking Status
firefox38 --- fixed

People

(Reporter: sstangl, Assigned: sstangl)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

Similar to Bug 1118040, maybeStrSpecial no longer has any performance impact and can be removed to reduce an indentation level in some hairy code. Also cleaned up some other things around it while I was there.
Attachment #8566187 - Flags: review?(evilpies)
Comment on attachment 8566187 [details] [diff] [review]
0001-Remove-maybeStrSpecial.patch

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

I trust you that really makes no difference in performance.

::: js/src/frontend/TokenStream.cpp
@@ +1709,4 @@
>                      }
> +
> +                    c = char16_t(val);
> +                } else if (c == 'u') {

Seems to me like u and x could be handled in the switch. We could even add '0' .. '7', but that seems slightly worse.
Attachment #8566187 - Flags: review?(evilpies) → review+
Blocks: 1135259
https://hg.mozilla.org/mozilla-central/rev/b6372c9513ef
Assignee: nobody → sstangl
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla38
You need to log in before you can comment on or make changes to this bug.