michael@0: /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- michael@0: * vim: set ts=8 sts=4 et sw=4 tw=99: michael@0: * This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: #ifndef jit_shared_Lowering_x86_shared_h michael@0: #define jit_shared_Lowering_x86_shared_h michael@0: michael@0: #include "jit/shared/Lowering-shared.h" michael@0: michael@0: namespace js { michael@0: namespace jit { michael@0: michael@0: class LIRGeneratorX86Shared : public LIRGeneratorShared michael@0: { michael@0: protected: michael@0: LIRGeneratorX86Shared(MIRGenerator *gen, MIRGraph &graph, LIRGraph &lirGraph) michael@0: : LIRGeneratorShared(gen, graph, lirGraph) michael@0: {} michael@0: michael@0: LTableSwitch *newLTableSwitch(const LAllocation &in, const LDefinition &inputCopy, michael@0: MTableSwitch *ins); michael@0: LTableSwitchV *newLTableSwitchV(MTableSwitch *ins); michael@0: michael@0: bool visitGuardShape(MGuardShape *ins); michael@0: bool visitGuardObjectType(MGuardObjectType *ins); michael@0: bool visitPowHalf(MPowHalf *ins); michael@0: bool lowerForShift(LInstructionHelper<1, 2, 0> *ins, MDefinition *mir, MDefinition *lhs, michael@0: MDefinition *rhs); michael@0: bool lowerForALU(LInstructionHelper<1, 1, 0> *ins, MDefinition *mir, MDefinition *input); michael@0: bool lowerForALU(LInstructionHelper<1, 2, 0> *ins, MDefinition *mir, MDefinition *lhs, michael@0: MDefinition *rhs); michael@0: bool lowerForFPU(LInstructionHelper<1, 2, 0> *ins, MDefinition *mir, MDefinition *lhs, michael@0: MDefinition *rhs); michael@0: bool lowerForBitAndAndBranch(LBitAndAndBranch *baab, MInstruction *mir, michael@0: MDefinition *lhs, MDefinition *rhs); michael@0: bool visitConstant(MConstant *ins); michael@0: bool visitAsmJSNeg(MAsmJSNeg *ins); michael@0: bool lowerMulI(MMul *mul, MDefinition *lhs, MDefinition *rhs); michael@0: bool lowerDivI(MDiv *div); michael@0: bool lowerModI(MMod *mod); michael@0: bool lowerUDiv(MDiv *div); michael@0: bool lowerUMod(MMod *mod); michael@0: bool lowerUrshD(MUrsh *mir); michael@0: bool lowerConstantDouble(double d, MInstruction *ins); michael@0: bool lowerConstantFloat32(float d, MInstruction *ins); michael@0: bool lowerTruncateDToInt32(MTruncateToInt32 *ins); michael@0: bool lowerTruncateFToInt32(MTruncateToInt32 *ins); michael@0: bool visitForkJoinGetSlice(MForkJoinGetSlice *ins); michael@0: }; michael@0: michael@0: } // namespace jit michael@0: } // namespace js michael@0: michael@0: #endif /* jit_shared_Lowering_x86_shared_h */