0af232924c
This CL introduces new IL instruction, CheckNullInstr, for testing if an object is null. This instruction will be used to ensure correctness when AOT relies on strong mode types, which are nullable by default (unless proven otherwise). Code generation of CheckNullInstr is implemented without major code duplication between different CPUs using common macro-assembler pseudo-instructions implemented by all platforms. Also, code generation of GenericCheckBoundInstr is refactored in the similar way. Issue: https://github.com/dart-lang/sdk/issues/30480 Change-Id: I35e9b556302fe7db98ce5167b3601f08ddbee642 Reviewed-on: https://dart-review.googlesource.com/4540 Reviewed-by: Vyacheslav Egorov <vegorov@google.com> Reviewed-by: Zach Anderson <zra@google.com>
75 lines
5.1 KiB
C++
75 lines
5.1 KiB
C++
// Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
|
|
// for details. All rights reserved. Use of this source code is governed by a
|
|
// BSD-style license that can be found in the LICENSE file.
|
|
|
|
#ifndef RUNTIME_VM_RUNTIME_ENTRY_LIST_H_
|
|
#define RUNTIME_VM_RUNTIME_ENTRY_LIST_H_
|
|
|
|
namespace dart {
|
|
|
|
#define RUNTIME_ENTRY_LIST(V) \
|
|
V(AllocateArray) \
|
|
V(AllocateContext) \
|
|
V(AllocateObject) \
|
|
V(BreakpointRuntimeHandler) \
|
|
V(SingleStepHandler) \
|
|
V(CloneContext) \
|
|
V(FixCallersTarget) \
|
|
V(FixAllocationStubTarget) \
|
|
V(InlineCacheMissHandlerOneArg) \
|
|
V(InlineCacheMissHandlerTwoArgs) \
|
|
V(StaticCallMissHandlerOneArg) \
|
|
V(StaticCallMissHandlerTwoArgs) \
|
|
V(Instanceof) \
|
|
V(TypeCheck) \
|
|
V(BadTypeError) \
|
|
V(NonBoolTypeError) \
|
|
V(InstantiateType) \
|
|
V(InstantiateTypeArguments) \
|
|
V(InvokeClosureNoSuchMethod) \
|
|
V(InvokeNoSuchMethodDispatcher) \
|
|
V(MegamorphicCacheMissHandler) \
|
|
V(OptimizeInvokedFunction) \
|
|
V(TraceICCall) \
|
|
V(PatchStaticCall) \
|
|
V(RangeError) \
|
|
V(NullError) \
|
|
V(ReThrow) \
|
|
V(StackOverflow) \
|
|
V(Throw) \
|
|
V(TraceFunctionEntry) \
|
|
V(TraceFunctionExit) \
|
|
V(DeoptimizeMaterialize) \
|
|
V(RewindPostDeopt) \
|
|
V(UpdateFieldCid) \
|
|
V(InitStaticField) \
|
|
V(CompileFunction) \
|
|
V(MonomorphicMiss) \
|
|
V(SingleTargetMiss) \
|
|
V(UnlinkedCall)
|
|
|
|
#define LEAF_RUNTIME_ENTRY_LIST(V) \
|
|
V(void, PrintStopMessage, const char*) \
|
|
V(intptr_t, DeoptimizeCopyFrame, uword, uword) \
|
|
V(void, DeoptimizeFillFrame, uword) \
|
|
V(void, StoreBufferBlockProcess, Thread*) \
|
|
V(intptr_t, BigintCompare, RawBigint*, RawBigint*) \
|
|
V(double, LibcPow, double, double) \
|
|
V(double, DartModulo, double, double) \
|
|
V(double, LibcFloor, double) \
|
|
V(double, LibcCeil, double) \
|
|
V(double, LibcTrunc, double) \
|
|
V(double, LibcRound, double) \
|
|
V(double, LibcCos, double) \
|
|
V(double, LibcSin, double) \
|
|
V(double, LibcTan, double) \
|
|
V(double, LibcAcos, double) \
|
|
V(double, LibcAsin, double) \
|
|
V(double, LibcAtan, double) \
|
|
V(double, LibcAtan2, double, double) \
|
|
V(RawBool*, CaseInsensitiveCompareUC16, RawString*, RawSmi*, RawSmi*, RawSmi*)
|
|
|
|
} // namespace dart
|
|
|
|
#endif // RUNTIME_VM_RUNTIME_ENTRY_LIST_H_
|