2 // Copyright (c) Microsoft. All rights reserved.
3 // Licensed under the MIT license. See LICENSE file in the project root for full license information.
6 /*XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
7 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
11 XX This encapsulates all the logic for lowering trees for the ARM XX
12 XX architecture. For a more detailed view of what is lowering, please XX
13 XX take a look at Lower.cpp XX
16 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
17 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
25 #ifndef LEGACY_BACKEND // This file is ONLY used for the RyuJIT backend that uses the linear scan register allocator
27 // The ARM backend is not yet implemented, so the methods here are all NYI.
28 // TODO-ARM-NYI: Lowering for ARM.
35 /* Lowering of GT_CAST nodes */
36 void Lowering::LowerCast(GenTreePtr *ppTree) { }
39 void Lowering::LowerCntBlockOp(GenTreePtr *ppTree)
41 NYI_ARM("ARM Lowering for BlockOp");
44 void Lowering::LowerRotate(GenTreePtr tree)
46 NYI_ARM("ARM Lowering for ROL and ROR");
49 void Lowering::TreeNodeInfoInitCall(GenTree *tree, TreeNodeInfo &info,
54 NYI_ARM("ARM TreeNodeInfoInit for Call");
57 Compiler::fgWalkResult Lowering::TreeInfoInitHelper(GenTreePtr* pTree, Compiler::fgWalkData* data)
59 Lowering* lower = (Lowering*)data->pCallbackData;
60 lower->TreeNodeInfoInit(pTree, data->parent);
61 return Compiler::WALK_CONTINUE;
64 void Lowering::TreeNodeInfoInit(GenTree* stmt)
66 comp->fgWalkTreePost(&stmt->gtStmt.gtStmtExpr, &Lowering::TreeInfoInitHelper, this);
69 void Lowering::TreeNodeInfoInit(GenTreePtr *pTree, GenTree* parent)
71 NYI("ARM TreeNodInfoInit");
74 // returns true if the tree can use the read-modify-write memory instruction form
75 bool Lowering::isRMWRegOper(GenTreePtr tree)
80 bool Lowering::IsCallTargetInRange(void *addr)
82 return comp->codeGen->validImmForBL ((ssize_t)addr);
85 // return true if the immediate can be folded into an instruction, for example small enough and non-relocatable
86 bool Lowering:: IsContainableImmed(GenTree* parentNode, GenTree* childNode)
88 NYI_ARM("ARM IsContainableImmed");
92 #endif // _TARGET_ARM_
94 #endif // !LEGACY_BACKEND