Ignore:
Timestamp:
Nov 13, 2014, 3:00:07 PM (11 years ago)
Author:
[email protected]
Message:

Change X86/64 JIT probes to save/restore xmm regs as double instead of m128.
<https://webkit.org/b/138708>

Reviewed by Michael Saboff.

The JIT code only uses the xmm regs as double registers. This patch changes
the storage types of the FP registers in X86Assembler.h to double instead of
m128, and updates the X86 and X86_64 JIT probe implementations accordingly.

Also made some minor cosmetic changes in the output of the probe dump functions.

  • assembler/MacroAssemblerX86Common.cpp:

(JSC::MacroAssemblerX86Common::ProbeContext::dumpCPURegisters):

  • assembler/X86Assembler.h:
  • jit/JITStubsX86.h:
  • jit/JITStubsX86Common.h:
  • jit/JITStubsX86_64.h:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/assembler/MacroAssemblerX86Common.cpp

    r176031 r176095  
    11/*
    2  * Copyright (C) 2013 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013, 2014 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3838    #define DUMP_GPREGISTER(_type, _regName) { \
    3939        int32_t value = reinterpret_cast<int32_t>(cpu._regName); \
    40         dataLogF("%s    %6s: 0x%08x   %d\n", indentation, #_regName, value, value) ; \
     40        dataLogF("%s    %6s: 0x%08x  %d\n", indentation, #_regName, value, value) ; \
    4141    }
    4242#elif CPU(X86_64)
    4343    #define DUMP_GPREGISTER(_type, _regName) { \
    4444        int64_t value = reinterpret_cast<int64_t>(cpu._regName); \
    45         dataLogF("%s    %6s: 0x%016llx   %lld\n", indentation, #_regName, value, value) ; \
     45        dataLogF("%s    %6s: 0x%016llx  %lld\n", indentation, #_regName, value, value) ; \
    4646    }
    4747#endif
     
    5151
    5252    #define DUMP_FPREGISTER(_type, _regName) { \
    53         uint32_t* u = reinterpret_cast<uint32_t*>(&cpu._regName); \
     53        uint64_t* u = reinterpret_cast<uint64_t*>(&cpu._regName); \
    5454        double* d = reinterpret_cast<double*>(&cpu._regName); \
    55         dataLogF("%s    %6s: 0x%08x%08x 0x%08x%08x   %12g %12g\n", \
    56             indentation, #_regName, u[3], u[2], u[1], u[0], d[1], d[0]); \
     55        dataLogF("%s    %6s: 0x%016llx  %.13g\n", indentation, #_regName, *u, *d); \
    5756    }
    5857    FOR_EACH_CPU_FPREGISTER(DUMP_FPREGISTER)
Note: See TracChangeset for help on using the changeset viewer.