mirror of
https://github.com/dart-lang/sdk
synced 2024-09-05 00:13:50 +00:00
![Alexander Markov](/assets/img/avatar_default.png)
This change introduces separate stubs for suspending sync* functions at start and at yield/yield*. Suspend stub for yield/yield* no longer calls Dart callback (in order to make it faster). Also, ReturnSyncStar stub is removed - sync* functions now directly return false instead of going through the stub. TEST=ci Issue: https://github.com/dart-lang/sdk/issues/48378 Change-Id: Iee9a1f48cab2812cf0f9f0e4e6d8e847547e49f7 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/250420 Reviewed-by: Slava Egorov <vegorov@google.com> Reviewed-by: Martin Kustermann <kustermann@google.com> Commit-Queue: Alexander Markov <alexmarkov@google.com>
171 lines
13 KiB
C++
171 lines
13 KiB
C++
// Copyright (c) 2019, 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_STUB_CODE_LIST_H_
|
|
#define RUNTIME_VM_STUB_CODE_LIST_H_
|
|
|
|
namespace dart {
|
|
|
|
#define VM_TYPE_TESTING_STUB_CODE_LIST(V) \
|
|
V(DefaultTypeTest) \
|
|
V(DefaultNullableTypeTest) \
|
|
V(TopTypeTypeTest) \
|
|
V(UnreachableTypeTest) \
|
|
V(TypeParameterTypeTest) \
|
|
V(NullableTypeParameterTypeTest) \
|
|
V(SlowTypeTest) \
|
|
V(LazySpecializeTypeTest) \
|
|
V(LazySpecializeNullableTypeTest)
|
|
|
|
// List of stubs created in the VM isolate, these stubs are shared by different
|
|
// isolates running in this dart process.
|
|
#define VM_STUB_CODE_LIST(V) \
|
|
V(GetCStackPointer) \
|
|
V(JumpToFrame) \
|
|
V(RunExceptionHandler) \
|
|
V(DeoptForRewind) \
|
|
V(WriteBarrier) \
|
|
V(WriteBarrierWrappers) \
|
|
V(ArrayWriteBarrier) \
|
|
V(AllocateArray) \
|
|
V(AllocateMint) \
|
|
V(AllocateDouble) \
|
|
V(AllocateFloat32x4) \
|
|
V(AllocateFloat64x2) \
|
|
V(AllocateInt32x4) \
|
|
V(AllocateInt8Array) \
|
|
V(AllocateUint8Array) \
|
|
V(AllocateUint8ClampedArray) \
|
|
V(AllocateInt16Array) \
|
|
V(AllocateUint16Array) \
|
|
V(AllocateInt32Array) \
|
|
V(AllocateUint32Array) \
|
|
V(AllocateInt64Array) \
|
|
V(AllocateUint64Array) \
|
|
V(AllocateFloat32Array) \
|
|
V(AllocateFloat64Array) \
|
|
V(AllocateFloat32x4Array) \
|
|
V(AllocateInt32x4Array) \
|
|
V(AllocateFloat64x2Array) \
|
|
V(AllocateMintSharedWithFPURegs) \
|
|
V(AllocateMintSharedWithoutFPURegs) \
|
|
V(AllocateClosure) \
|
|
V(AllocateContext) \
|
|
V(AllocateGrowableArray) \
|
|
V(AllocateObject) \
|
|
V(AllocateObjectParameterized) \
|
|
V(AllocateObjectSlow) \
|
|
V(AllocateUnhandledException) \
|
|
V(BoxDouble) \
|
|
V(CloneContext) \
|
|
V(CallToRuntime) \
|
|
V(LazyCompile) \
|
|
V(CallBootstrapNative) \
|
|
V(CallNoScopeNative) \
|
|
V(CallAutoScopeNative) \
|
|
V(FixCallersTarget) \
|
|
V(CallStaticFunction) \
|
|
V(OptimizeFunction) \
|
|
V(InvokeDartCode) \
|
|
V(DebugStepCheck) \
|
|
V(SwitchableCallMiss) \
|
|
V(MonomorphicSmiableCheck) \
|
|
V(SingleTargetCall) \
|
|
V(ICCallThroughCode) \
|
|
V(MegamorphicCall) \
|
|
V(FixAllocationStubTarget) \
|
|
V(FixParameterizedAllocationStubTarget) \
|
|
V(Deoptimize) \
|
|
V(DeoptimizeLazyFromReturn) \
|
|
V(DeoptimizeLazyFromThrow) \
|
|
V(UnoptimizedIdenticalWithNumberCheck) \
|
|
V(OptimizedIdenticalWithNumberCheck) \
|
|
V(ICCallBreakpoint) \
|
|
V(UnoptStaticCallBreakpoint) \
|
|
V(RuntimeCallBreakpoint) \
|
|
V(OneArgCheckInlineCache) \
|
|
V(TwoArgsCheckInlineCache) \
|
|
V(SmiAddInlineCache) \
|
|
V(SmiLessInlineCache) \
|
|
V(SmiEqualInlineCache) \
|
|
V(OneArgOptimizedCheckInlineCache) \
|
|
V(TwoArgsOptimizedCheckInlineCache) \
|
|
V(ZeroArgsUnoptimizedStaticCall) \
|
|
V(OneArgUnoptimizedStaticCall) \
|
|
V(TwoArgsUnoptimizedStaticCall) \
|
|
V(AssertSubtype) \
|
|
V(AssertAssignable) \
|
|
V(TypeIsTopTypeForSubtyping) \
|
|
V(TypeIsTopTypeForSubtypingNullSafe) \
|
|
V(NullIsAssignableToType) \
|
|
V(NullIsAssignableToTypeNullSafe) \
|
|
V(Subtype1TestCache) \
|
|
V(Subtype3TestCache) \
|
|
V(Subtype5TestCache) \
|
|
V(Subtype7TestCache) \
|
|
VM_TYPE_TESTING_STUB_CODE_LIST(V) \
|
|
V(CallClosureNoSuchMethod) \
|
|
V(FrameAwaitingMaterialization) \
|
|
V(AsynchronousGapMarker) \
|
|
V(NotLoaded) \
|
|
V(DispatchTableNullError) \
|
|
V(LateInitializationErrorSharedWithFPURegs) \
|
|
V(LateInitializationErrorSharedWithoutFPURegs) \
|
|
V(NullErrorSharedWithFPURegs) \
|
|
V(NullErrorSharedWithoutFPURegs) \
|
|
V(NullArgErrorSharedWithFPURegs) \
|
|
V(NullArgErrorSharedWithoutFPURegs) \
|
|
V(NullCastErrorSharedWithFPURegs) \
|
|
V(NullCastErrorSharedWithoutFPURegs) \
|
|
V(RangeErrorSharedWithFPURegs) \
|
|
V(RangeErrorSharedWithoutFPURegs) \
|
|
V(StackOverflowSharedWithFPURegs) \
|
|
V(StackOverflowSharedWithoutFPURegs) \
|
|
V(DoubleToInteger) \
|
|
V(OneArgCheckInlineCacheWithExactnessCheck) \
|
|
V(OneArgOptimizedCheckInlineCacheWithExactnessCheck) \
|
|
V(EnterSafepoint) \
|
|
V(ExitSafepoint) \
|
|
V(ExitSafepointIgnoreUnwindInProgress) \
|
|
V(CallNativeThroughSafepoint) \
|
|
V(InitStaticField) \
|
|
V(InitLateStaticField) \
|
|
V(InitLateFinalStaticField) \
|
|
V(InitInstanceField) \
|
|
V(InitLateInstanceField) \
|
|
V(InitLateFinalInstanceField) \
|
|
V(Throw) \
|
|
V(ReThrow) \
|
|
V(AssertBoolean) \
|
|
V(InstanceOf) \
|
|
V(InstantiateType) \
|
|
V(InstantiateTypeNonNullableClassTypeParameter) \
|
|
V(InstantiateTypeNullableClassTypeParameter) \
|
|
V(InstantiateTypeLegacyClassTypeParameter) \
|
|
V(InstantiateTypeNonNullableFunctionTypeParameter) \
|
|
V(InstantiateTypeNullableFunctionTypeParameter) \
|
|
V(InstantiateTypeLegacyFunctionTypeParameter) \
|
|
V(InstantiateTypeArguments) \
|
|
V(InstantiateTypeArgumentsMayShareInstantiatorTA) \
|
|
V(InstantiateTypeArgumentsMayShareFunctionTA) \
|
|
V(NoSuchMethodDispatcher) \
|
|
V(Await) \
|
|
V(InitAsync) \
|
|
V(Resume) \
|
|
V(ReturnAsync) \
|
|
V(ReturnAsyncNotFuture) \
|
|
V(InitAsyncStar) \
|
|
V(YieldAsyncStar) \
|
|
V(ReturnAsyncStar) \
|
|
V(InitSyncStar) \
|
|
V(SuspendSyncStarAtStart) \
|
|
V(SuspendSyncStarAtYield) \
|
|
V(AsyncExceptionHandler) \
|
|
V(CloneSuspendState) \
|
|
V(UnknownDartCode)
|
|
|
|
} // namespace dart
|
|
|
|
#endif // RUNTIME_VM_STUB_CODE_LIST_H_
|