• bmeurer's avatar
    [builtins] Make Math.ceil, Math.trunc and Math.round optimizable. · 8d20f2fe
    bmeurer authored
    Migrate Math.ceil, Math.round and Math.trunc to TurboFan code stubs,
    similar to what we did with Math.floor, and make these builtins properly
    optimizable in TurboFan via appropriate simplified operators NumberCeil,
    NumberRound and NumberTrunc, which are intended to be reusable for
    ToInteger and ToLength optimizations that will be done in a followup CL.
    
    Also allows us to kill the funky %RoundNumber runtime function, which
    was quite heavy.
    
    Improve test coverage for Math.ceil and Math.trunc a lot, especially
    making sure that we also properly trigger the TurboFan builtin reducer
    case.
    
    R=jarin@chromium.org
    BUG=v8:4059
    LOG=n
    
    Review URL: https://codereview.chromium.org/1841993002
    
    Cr-Commit-Position: refs/heads/master@{#35135}
    8d20f2fe
bootstrapper.cc 150 KB