1. 05 Jul, 2016 8 commits
    • zhengxing.li's avatar
      X87: disable test-gap-resolver/FuzzResolver test case for x87. · bf4ef548
      zhengxing.li authored
        The reason:
        In CreateRandomOperand(), It used the register index 1 for ExplicitOperand(LocationOperand::REGISTER, rep,
        GetRegisterCode(rep, 1)).
      
        For x87 turbofan compiler, there's only 1 allocatable Float/Double register, i.e.: register index 0. the
        GetRegisterCode(rep, 1) in ExplicitOperand() always return false when rep is MachineRepresentation::kFloat32/kFloat64.
      
        It caused the test-gap-resolver/FuzzResolver failed at DCHECK_IMPLIES(kind == REGISTER && rep == MachineRepresentation::kFloat32,
        FloatRegister::from_code(index).IsAllocatable(RegisterConfiguration::TURBOFAN)), src/compiler/instruction.cc, line 259, under
        debug mode.
      
        This CL disable test-gap-resolver/FuzzResolver test case for x87.
      
      BUG=
      
      Review-Url: https://codereview.chromium.org/2120203002
      Cr-Commit-Position: refs/heads/master@{#37515}
      bf4ef548
    • machenbach's avatar
      Revert of [intrinsic] Drop the %_ValueOf intrinsic. (patchset #2 id:20001 of... · 0960beb0
      machenbach authored
      Revert of [intrinsic] Drop the %_ValueOf intrinsic. (patchset #2 id:20001 of https://codereview.chromium.org/2126453002/ )
      
      Reason for revert:
      [Sheriff] Breaks without i18n:
      https://build.chromium.org/p/client.v8/builders/V8%20Linux%20-%20noi18n%20-%20debug/builds/8466
      
      Original issue's description:
      > [intrinsic] Drop the %_ValueOf intrinsic.
      >
      > This drops the %_ValueOf intrinsic, but keeps the runtime entry
      > %ValueOf for now, by either migrating the functionality (mostly
      > Debug mirror or toString/valueOf methods) to C++ or TurboFan
      > builtins, or switching to the %ValueOf runtime call when it's
      > not performance critical anyways.
      >
      > The %_ValueOf intrinsic was one of the last blockers for fixing
      > the unsound machine operator typing in TurboFan.
      >
      > R=yangguo@chromium.org
      > BUG=v8:5049
      >
      > Committed: https://crrev.com/293bd7882987f00e465710ce468bfb1eaa7d3fa2
      > Cr-Commit-Position: refs/heads/master@{#37512}
      
      TBR=yangguo@chromium.org,bmeurer@chromium.org
      # Skipping CQ checks because original CL landed less than 1 days ago.
      NOPRESUBMIT=true
      NOTREECHECKS=true
      NOTRY=true
      BUG=v8:5049
      
      Review-Url: https://codereview.chromium.org/2117273002
      Cr-Commit-Position: refs/heads/master@{#37514}
      0960beb0
    • jgruber's avatar
      Use toString tag to format receiver in stack traces · 97146803
      jgruber authored
      This concerns formatting of calls to, e.g., Math.acos in stack traces,
      in which the receiver is an object with an attached toString tag. If
      such a tag exists, use it to format the receiver typename to ensure that
      the stack trace includes 'Math.acos' instead of 'Object.acos'.
      
      R=yangguo@chromium.org
      BUG=
      
      Review-Url: https://codereview.chromium.org/2110683007
      Cr-Commit-Position: refs/heads/master@{#37513}
      97146803
    • bmeurer's avatar
      [intrinsic] Drop the %_ValueOf intrinsic. · 293bd788
      bmeurer authored
      This drops the %_ValueOf intrinsic, but keeps the runtime entry
      %ValueOf for now, by either migrating the functionality (mostly
      Debug mirror or toString/valueOf methods) to C++ or TurboFan
      builtins, or switching to the %ValueOf runtime call when it's
      not performance critical anyways.
      
      The %_ValueOf intrinsic was one of the last blockers for fixing
      the unsound machine operator typing in TurboFan.
      
      R=yangguo@chromium.org
      BUG=v8:5049
      
      Review-Url: https://codereview.chromium.org/2126453002
      Cr-Commit-Position: refs/heads/master@{#37512}
      293bd788
    • zhengxing.li's avatar
      X87: [builtins] Add receiver to builtin exit frames. · e043dcb5
      zhengxing.li authored
        port f59a2335 (r37500)
      
        original commit message:
        Stack trace generation requires access to the receiver; and while the
        receiver is already on the stack, we cannot determine its position
        during stack trace generation (it's stored in argv[0], and argc is only
        stored in a callee-saved register).
      
        This patch grants access to the receiver by pushing argc onto builtin
        exit frames as an extra argument. Compared to simply pushing the
        receiver, this requires an additional dereference during stack trace
        generation, but one fewer during builtin calls.
      
      BUG=
      
      Review-Url: https://codereview.chromium.org/2118413002
      Cr-Commit-Position: refs/heads/master@{#37511}
      e043dcb5
    • mvstanton's avatar
      Removed fdlibm.js, as it is now an empty shell. · 47f54330
      mvstanton authored
      BUG=
      
      Review-Url: https://codereview.chromium.org/2106413002
      Cr-Commit-Position: refs/heads/master@{#37510}
      47f54330
    • v8-autoroll's avatar
      Update V8 DEPS. · 12291c54
      v8-autoroll authored
      Rolling v8/build to 536d6fe8a0df34c0c412da483375d71b9b931afa
      
      Rolling v8/buildtools to d2664782a3855d5be8cbbfd3c23b6652926de8cc
      
      TBR=machenbach@chromium.org,vogelheim@chromium.org,hablich@chromium.org
      
      Review-Url: https://codereview.chromium.org/2124673002
      Cr-Commit-Position: refs/heads/master@{#37509}
      12291c54
    • zhengxing.li's avatar
      X87: [turbofan]: Support using push instructions for setting up tail call parameters. · c140a90c
      zhengxing.li authored
        port bd0d9e7d (r37477)
      
        original commit message:
        This optimizes the passing of stack parameters in function calls.
      
        For some architectures (ia32/x64), using pushes when possible instead
        of bumping the stack and then storing parameters generates much
        smaller code, and in some cases is faster (e.g. when a push of a memory
        location can implement a memory-to-memory copy and thus elide an
        intermediate load. On others (e.g. ARM), the benefit is smaller, where
        it's only possible to elide direct stack pointer adjustment in certain cases
        or combine multiple register stores into a single instruction in other limited
        situations. On yet other platforms (ARM64, MIPS), there are no push instructions,
        and this optimization isn't used at all.
      
        Ideally, this mechanism would be used for both tail calls and normal calls,
        but "normal" calls are currently pretty efficient, and tail calls are very
        inefficient, so this CL sets the bar low for building a new mechanism to
        handle parameter pushing that only needs to raise the bar on tail calls for now.
      
        The key aspect of this change is that adjustment to the stack pointer
        for tail calls (and perhaps later real calls) is an explicit step separate from
        instruction selection and gap resolution, but aware of both, making it possible
        to safely recognize gap moves that are actually pushes.
      
      BUG=
      
      Review-Url: https://codereview.chromium.org/2120413002
      Cr-Commit-Position: refs/heads/master@{#37508}
      c140a90c
  2. 04 Jul, 2016 19 commits
  3. 03 Jul, 2016 1 commit
    • honggyu.kp's avatar
      gdb-v8-support.py: Fix old style print statement · c52685a5
      honggyu.kp authored
      Since python3 does not use the old print statement, it may not be able
      to load gdb-v8-support.py script in gdb as below:
      
        (gdb) source tools/gdb-v8-support.py
          File "tools/gdb-v8-support.py", line 170
            print result
                       ^
        SyntaxError: Missing parentheses in call to 'print'
      
      This fixes print statement for both python2 and python3.
      
      R=jochen@chromium.org
      BUG=
      
      Review-Url: https://codereview.chromium.org/2084163004
      Cr-Commit-Position: refs/heads/master@{#37488}
      c52685a5
  4. 02 Jul, 2016 2 commits
  5. 01 Jul, 2016 10 commits
    • caitpotter88's avatar
      [esnext] ship --harmony-object-values-entries · ab529234
      caitpotter88 authored
      BUG=v8:4663
      R=littledan@chromium.org, adamk@chromium.org
      
      Review-Url: https://codereview.chromium.org/2116053003
      Cr-Commit-Position: refs/heads/master@{#37485}
      ab529234
    • caitpotter88's avatar
      [builtins] make AsyncFunction constructor a subclass of Function · cd9e5f30
      caitpotter88 authored
      Corrects a small problem with the current implementation of the AsyncFunction
      constructor.
      
      See https://tc39.github.io/ecmascript-asyncawait/#async-function-constructor for
      details.
      
      BUG=v8:4483
      R=littledan@chromium.org, adamk@chromium.org, jwolfe@igalia.com
      
      Review-Url: https://codereview.chromium.org/2118653004
      Cr-Commit-Position: refs/heads/master@{#37484}
      cd9e5f30
    • bbudge's avatar
      [Turbofan] Add Simd128 regs to InstructionOperandConverter. · 26625644
      bbudge authored
      LOG=N
      BUG=v8:4124
      
      Review-Url: https://codereview.chromium.org/2117703003
      Cr-Commit-Position: refs/heads/master@{#37483}
      26625644
    • littledan's avatar
      Implement immutable prototype chains · 0ff7b483
      littledan authored
      This patch implements "immutable prototype exotic objects" from the ECMAScript
      spec, which are objects whose __proto__ cannot be changed, but are not otherwise
      frozen. They are introduced in order to prevent a Proxy from being introduced
      to the prototype chain of the global object.
      
      The API is extended by a SetImmutablePrototype() call in ObjectTemplate, which
      can be used to vend new immutable prototype objects. Additionally, Object.prototype
      is an immutable prototype object.
      
      In the implementation, a new bit is added to Maps to say whether the prototype is
      immutable, which is read by SetPrototype. Map transitions to the immutable prototype
      state are not saved in the transition tree because the main use case is just for
      the prototype chain of the global object, which there will be only one of per
      Context, so no need to take up the extra word for a pointer in each full transition
      tree.
      
      BUG=v8:5149
      
      Review-Url: https://codereview.chromium.org/2108203002
      Cr-Commit-Position: refs/heads/master@{#37482}
      0ff7b483
    • balazs.kilvady's avatar
      MIPS: [builtins] Fix MathMaxMin. · e65035f2
      balazs.kilvady authored
      Port b86ac0e0
      
      Original commit message:
      Both of these were broken in different ways:
      * On arm, the loop counter was passed as argc on the stack.
      * On arm64, we passed argc + 1 instead of argc.
      
      The result in both cases was an incorrect receiver for the builtin frame
      when generating stack traces.
      
      BUG=v8:4815
      
      Review-Url: https://codereview.chromium.org/2120463002
      Cr-Commit-Position: refs/heads/master@{#37481}
      e65035f2
    • mstarzinger's avatar
      [turbofan] Broaden checkpoint elimination on returns. · a757a62b
      mstarzinger authored
      This makes the elimination of checkpoints flowing effect-wise into nodes
      having the {Return} operator more permissive. We can cut out checkpoints
      even when they are not wholly owned by the return. This also alleviates
      a problem where TCO no longer applies.
      
      R=jarin@chromium.org
      TEST=mjsunit/regress/regress-crbug-624747
      BUG=chromium:624747
      
      Review-Url: https://codereview.chromium.org/2118793002
      Cr-Commit-Position: refs/heads/master@{#37480}
      a757a62b
    • bmeurer's avatar
      [turbofan] Properly lower NumberSinh, NumberCosh and NumberTanh. · 9c281f24
      bmeurer authored
      R=jarin@chromium.org
      BUG=chromium:625121
      
      Review-Url: https://codereview.chromium.org/2116533004
      Cr-Commit-Position: refs/heads/master@{#37479}
      9c281f24
    • titzer's avatar
      [wasm] Dont ship by default. · ac4fdca6
      titzer authored
      R=mstarzinger@chromium.org,bradnelson@chromium.org
      BUG=
      
      Review-Url: https://codereview.chromium.org/2118733003
      Cr-Commit-Position: refs/heads/master@{#37478}
      ac4fdca6
    • danno's avatar
      [turbofan]: Support using push instructions for setting up tail call parameters · bd0d9e7d
      danno authored
      This optimizes the passing of stack parameters in function calls.
      
      For some architectures (ia32/x64), using pushes when possible instead
      of bumping the stack and then storing parameters generates much
      smaller code, and in some cases is faster (e.g. when a push of a memory
      location can implement a memory-to-memory copy and thus elide an
      intermediate load. On others (e.g. ARM), the benefit is smaller, where
      it's only possible to elide direct stack pointer adjustment in certain cases
      or combine multiple register stores into a single instruction in other limited
      situations. On yet other platforms (ARM64, MIPS), there are no push instructions,
      and this optimization isn't used at all.
      
      Ideally, this mechanism would be used for both tail calls and normal calls,
      but "normal" calls are currently pretty efficient, and tail calls are very
      inefficient, so this CL sets the bar low for building a new mechanism to
      handle parameter pushing that only needs to raise the bar on tail calls for now.
      
      The key aspect of this change is that adjustment to the stack pointer
      for tail calls (and perhaps later real calls) is an explicit step separate from
      instruction selection and gap resolution, but aware of both, making it possible
      to safely recognize gap moves that are actually pushes.
      
      Review-Url: https://codereview.chromium.org/2082263002
      Cr-Commit-Position: refs/heads/master@{#37477}
      bd0d9e7d
    • bmeurer's avatar
      [builtins] Unify most of the remaining Math builtins. · 0a0fe8fb
      bmeurer authored
      Import fdlibm versions of acos, acosh, asin and asinh, which are more
      precise and produce the same result across platforms (we were using
      libm versions for asin and acos so far, where both speed and precision
      depended on the operating system so far). Introduce appropriate TurboFan
      operators for these functions and use them both for inlining and for the
      generic builtin.
      
      Also migrate the Math.imul and Math.fround builtins to TurboFan builtins
      to ensure that their behavior is always exactly the same as the inlined
      TurboFan version (i.e. C++ truncation semantics for double to float
      don't necessarily meet the JavaScript semantics).
      
      For completeness, also migrate Math.sign, which can even get some nice
      love in TurboFan.
      
      Drive-by-fix: Some alpha-sorting on the Math related functions, and
      cleanup the list of Math intrinsics that we have to export via the
      native context currently.
      
      BUG=v8:3266,v8:3496,v8:3509,v8:3952,v8:5169,v8:5170,v8:5171,v8:5172
      TBR=rossberg@chromium.org
      R=franzih@chromium.org
      
      Review-Url: https://codereview.chromium.org/2116753002
      Cr-Commit-Position: refs/heads/master@{#37476}
      0a0fe8fb