Changeset 229506 in webkit


Ignore:
Timestamp:
Mar 10, 2018, 12:13:03 PM (7 years ago)
Author:
mark.lam@apple.com
Message:

offlineasm should reset the Assembler's working state before doing another pass for a new target.
https://bugs.webkit.org/show_bug.cgi?id=183538
<rdar://problem/38325955>

Reviewed by Michael Saboff.

  • llint/LowLevelInterpreter.cpp:
  • offlineasm/asm.rb:
  • offlineasm/cloop.rb:
Location:
trunk/Source/JavaScriptCore
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/ChangeLog

    r229493 r229506  
     12018-03-09  Mark Lam  <mark.lam@apple.com>
     2
     3        offlineasm should reset the Assembler's working state before doing another pass for a new target.
     4        https://bugs.webkit.org/show_bug.cgi?id=183538
     5        <rdar://problem/38325955>
     6
     7        Reviewed by Michael Saboff.
     8
     9        * llint/LowLevelInterpreter.cpp:
     10        * offlineasm/asm.rb:
     11        * offlineasm/cloop.rb:
     12
    1132018-03-09  Brian Burg  <bburg@apple.com>
    214
  • trunk/Source/JavaScriptCore/llint/LowLevelInterpreter.cpp

    r225140 r229506  
    3131
    3232#if !ENABLE(JIT)
     33#include "Bytecodes.h"
    3334#include "CLoopStackInlines.h"
    3435#include "CodeBlock.h"
  • trunk/Source/JavaScriptCore/offlineasm/asm.rb

    r223239 r229506  
    4040        @outp = outp
    4141        @state = :cpp
     42        resetAsm
     43    end
     44
     45    def resetAsm
    4246        @commentState = :none
    4347        @comment = nil
     
    9498   
    9599    def inAsm
     100        resetAsm
    96101        enterAsm
    97102        yield
  • trunk/Source/JavaScriptCore/offlineasm/cloop.rb

    r229287 r229506  
    520520
    521521class Instruction
    522     @@didReturnFromJSLabelCounter = 0
    523 
    524522    def lowerC_LOOP
    525523        case opcode
     
    10791077        # as an opcode dispatch.
    10801078        when "cloopCallJSFunction"
    1081             @@didReturnFromJSLabelCounter += 1
    1082             $asm.putc "lr.opcode = getOpcode(llint_cloop_did_return_from_js_#{@@didReturnFromJSLabelCounter});"
     1079            uid = $asm.newUID
     1080            $asm.putc "lr.opcode = getOpcode(llint_cloop_did_return_from_js_#{uid});"
    10831081            $asm.putc "opcode = #{operands[0].clValue(:opcode)};"
    10841082            $asm.putc "DISPATCH_OPCODE();"
    1085             $asm.putsLabel("llint_cloop_did_return_from_js_#{@@didReturnFromJSLabelCounter}", false)
     1083            $asm.putsLabel("llint_cloop_did_return_from_js_#{uid}", false)
    10861084
    10871085        # We can't do generic function calls with an arbitrary set of args, but
Note: See TracChangeset for help on using the changeset viewer.