From c747a25d66f1ad5f0fbac44e89b7e998423b9bae Mon Sep 17 00:00:00 2001 From: Ryan Macnak Date: Mon, 22 May 2023 16:43:04 +0000 Subject: [PATCH] [vm] Add arch-specific bits for Android RISCV64. TEST=local AOSP build Bug: https://github.com/flutter/flutter/issues/117973 CoreLibraryReviewExempt: VM-only Change-Id: I9417e86f025bebee359d8ba50ee6b5c8589c2744 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/303011 Reviewed-by: Daco Harkes Reviewed-by: Johnni Winther Commit-Queue: Ryan Macnak --- .../ffi_sample.dart.strong.transformed.expect | 8 +- .../ffi_sample.dart.weak.transformed.expect | 8 +- .../incremental/crash_05.yaml.world.1.expect | 4 +- .../incremental/crash_05.yaml.world.2.expect | 4 +- .../incremental/crash_06.yaml.world.1.expect | 2 +- .../incremental/crash_06.yaml.world.2.expect | 2 +- .../incremental/ffi_01.yaml.world.1.expect | 8 +- .../incremental/ffi_01.yaml.world.2.expect | 8 +- .../incremental/ffi_02.yaml.world.1.expect | 8 +- .../issue_46666.yaml.world.1.expect | 10 +- .../issue_46666.yaml.world.2.expect | 10 +- .../no_outline_change_35.yaml.world.1.expect | 8 +- .../no_outline_change_35.yaml.world.2.expect | 8 +- .../no_outline_change_35.yaml.world.3.expect | 8 +- ..._outline_change_48_ffi.yaml.world.1.expect | 12 +- ..._outline_change_48_ffi.yaml.world.2.expect | 12 +- ..._outline_change_49_ffi.yaml.world.1.expect | 12 +- ..._outline_change_49_ffi.yaml.world.2.expect | 12 +- ..._outline_change_50_ffi.yaml.world.1.expect | 12 +- ..._outline_change_50_ffi.yaml.world.2.expect | 12 +- .../regress_46004.yaml.world.1.expect | 4 +- .../regress_46004.yaml.world.2.expect | 4 +- .../ffi_sample.dart.strong.transformed.expect | 8 +- .../ffi_sample.dart.weak.transformed.expect | 8 +- ...nline_array.dart.strong.transformed.expect | 4 +- ..._inline_array.dart.weak.transformed.expect | 4 +- ...dimensional.dart.strong.transformed.expect | 4 +- ...i_dimensional.dart.weak.transformed.expect | 4 +- pkg/vm/lib/transformations/ffi/abi.dart | 9 +- .../transformations/ffi/abi_specific_int.dart | 1 + .../ffi/abi_specific_int.dart.aot.expect | 10 +- .../ffi/abi_specific_int.dart.expect | 209 +++++++++--------- ...bi_specific_int_incomplete.dart.aot.expect | 10 +- .../abi_specific_int_incomplete.dart.expect | 10 +- .../ffi/compound_copies.dart.expect | 6 +- .../ffi_struct_constructors.dart.expect | 4 +- runtime/tools/bin_to_assembly.py | 2 +- runtime/vm/compiler/ffi/abi.h | 5 +- runtime/vm/cpuinfo_android.cc | 41 +++- runtime/vm/os_android.cc | 2 +- runtime/vm/signal_handler_android.cc | 8 + sdk/lib/_internal/vm/lib/ffi_patch.dart | 1 + sdk/lib/ffi/abi.dart | 7 +- sdk/lib/ffi/abi_specific.dart | 1 + sdk/lib/ffi/c_type.dart | 15 ++ 45 files changed, 304 insertions(+), 245 deletions(-) diff --git a/pkg/front_end/testcases/general/ffi_sample.dart.strong.transformed.expect b/pkg/front_end/testcases/general/ffi_sample.dart.strong.transformed.expect index f1184cd2dd9..c9d1d562d28 100644 --- a/pkg/front_end/testcases/general/ffi_sample.dart.strong.transformed.expect +++ b/pkg/front_end/testcases/general/ffi_sample.dart.strong.transformed.expect @@ -66,16 +66,16 @@ constants { #C7 = core::pragma {name:#C1, options:#C6} #C8 = ffi::Double {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 8 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = 16 - #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] + #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] #C15 = "vm:prefer-inline" #C16 = core::pragma {name:#C15, options:#C5} #C17 = 24 #C18 = 20 - #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] + #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] } diff --git a/pkg/front_end/testcases/general/ffi_sample.dart.weak.transformed.expect b/pkg/front_end/testcases/general/ffi_sample.dart.weak.transformed.expect index dad54f11e00..bb45612bf53 100644 --- a/pkg/front_end/testcases/general/ffi_sample.dart.weak.transformed.expect +++ b/pkg/front_end/testcases/general/ffi_sample.dart.weak.transformed.expect @@ -59,16 +59,16 @@ constants { #C7 = core::pragma {name:#C1, options:#C6} #C8 = ffi::Double {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 8 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = 16 - #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] + #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] #C15 = "vm:prefer-inline" #C16 = core::pragma {name:#C15, options:#C5} #C17 = 24 #C18 = 20 - #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] + #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] } diff --git a/pkg/front_end/testcases/incremental/crash_05.yaml.world.1.expect b/pkg/front_end/testcases/incremental/crash_05.yaml.world.1.expect index a42fec4e496..6338c7ed000 100644 --- a/pkg/front_end/testcases/incremental/crash_05.yaml.world.1.expect +++ b/pkg/front_end/testcases/incremental/crash_05.yaml.world.1.expect @@ -56,11 +56,11 @@ constants { #C6 = dart.core::pragma {name:#C1, options:#C5} #C7 = dart.ffi::Uint32 {} #C8 = 0 - #C9 = [#C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8] + #C9 = [#C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8] #C10 = "vm:prefer-inline" #C11 = dart.core::pragma {name:#C10, options:#C4} #C12 = 4 - #C13 = [#C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12] + #C13 = [#C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12] #C14 = TypeLiteralConstant(lib::Y) #C15 = [#C14] #C16 = dart.ffi::_FfiStructLayout {fieldTypes:#C15, packing:#C4} diff --git a/pkg/front_end/testcases/incremental/crash_05.yaml.world.2.expect b/pkg/front_end/testcases/incremental/crash_05.yaml.world.2.expect index a42fec4e496..6338c7ed000 100644 --- a/pkg/front_end/testcases/incremental/crash_05.yaml.world.2.expect +++ b/pkg/front_end/testcases/incremental/crash_05.yaml.world.2.expect @@ -56,11 +56,11 @@ constants { #C6 = dart.core::pragma {name:#C1, options:#C5} #C7 = dart.ffi::Uint32 {} #C8 = 0 - #C9 = [#C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8] + #C9 = [#C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8] #C10 = "vm:prefer-inline" #C11 = dart.core::pragma {name:#C10, options:#C4} #C12 = 4 - #C13 = [#C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12] + #C13 = [#C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12] #C14 = TypeLiteralConstant(lib::Y) #C15 = [#C14] #C16 = dart.ffi::_FfiStructLayout {fieldTypes:#C15, packing:#C4} diff --git a/pkg/front_end/testcases/incremental/crash_06.yaml.world.1.expect b/pkg/front_end/testcases/incremental/crash_06.yaml.world.1.expect index 6b565d751d6..69ed2f2ec48 100644 --- a/pkg/front_end/testcases/incremental/crash_06.yaml.world.1.expect +++ b/pkg/front_end/testcases/incremental/crash_06.yaml.world.1.expect @@ -62,7 +62,7 @@ constants { #C5 = dart.ffi::_FfiStructLayout {fieldTypes:#C3, packing:#C4} #C6 = dart.core::pragma {name:#C1, options:#C5} #C7 = 0 - #C8 = [#C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7] + #C8 = [#C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7] #C9 = "vm:prefer-inline" #C10 = dart.core::pragma {name:#C9, options:#C4} } diff --git a/pkg/front_end/testcases/incremental/crash_06.yaml.world.2.expect b/pkg/front_end/testcases/incremental/crash_06.yaml.world.2.expect index 6b565d751d6..69ed2f2ec48 100644 --- a/pkg/front_end/testcases/incremental/crash_06.yaml.world.2.expect +++ b/pkg/front_end/testcases/incremental/crash_06.yaml.world.2.expect @@ -62,7 +62,7 @@ constants { #C5 = dart.ffi::_FfiStructLayout {fieldTypes:#C3, packing:#C4} #C6 = dart.core::pragma {name:#C1, options:#C5} #C7 = 0 - #C8 = [#C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7] + #C8 = [#C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7] #C9 = "vm:prefer-inline" #C10 = dart.core::pragma {name:#C9, options:#C4} } diff --git a/pkg/front_end/testcases/incremental/ffi_01.yaml.world.1.expect b/pkg/front_end/testcases/incremental/ffi_01.yaml.world.1.expect index 493098144b3..53eb404fd5c 100644 --- a/pkg/front_end/testcases/incremental/ffi_01.yaml.world.1.expect +++ b/pkg/front_end/testcases/incremental/ffi_01.yaml.world.1.expect @@ -53,16 +53,16 @@ constants { #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = dart.ffi::Double {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 8 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = 16 - #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] + #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] #C15 = "vm:prefer-inline" #C16 = dart.core::pragma {name:#C15, options:#C5} #C17 = 24 #C18 = 20 - #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] + #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] } diff --git a/pkg/front_end/testcases/incremental/ffi_01.yaml.world.2.expect b/pkg/front_end/testcases/incremental/ffi_01.yaml.world.2.expect index 5c4ed2490f1..f56c32ef34f 100644 --- a/pkg/front_end/testcases/incremental/ffi_01.yaml.world.2.expect +++ b/pkg/front_end/testcases/incremental/ffi_01.yaml.world.2.expect @@ -57,16 +57,16 @@ constants { #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = dart.ffi::Double {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 8 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = 16 - #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] + #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] #C15 = "vm:prefer-inline" #C16 = dart.core::pragma {name:#C15, options:#C5} #C17 = 24 #C18 = 20 - #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] + #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] } diff --git a/pkg/front_end/testcases/incremental/ffi_02.yaml.world.1.expect b/pkg/front_end/testcases/incremental/ffi_02.yaml.world.1.expect index 4565d5b3342..dbbd1b2e2a0 100644 --- a/pkg/front_end/testcases/incremental/ffi_02.yaml.world.1.expect +++ b/pkg/front_end/testcases/incremental/ffi_02.yaml.world.1.expect @@ -54,16 +54,16 @@ constants { #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = dart.ffi::Double {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 8 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = 16 - #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] + #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] #C15 = "vm:prefer-inline" #C16 = dart.core::pragma {name:#C15, options:#C5} #C17 = 24 #C18 = 20 - #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] + #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] } diff --git a/pkg/front_end/testcases/incremental/issue_46666.yaml.world.1.expect b/pkg/front_end/testcases/incremental/issue_46666.yaml.world.1.expect index df0e2556612..e268e5a6e2c 100644 --- a/pkg/front_end/testcases/incremental/issue_46666.yaml.world.1.expect +++ b/pkg/front_end/testcases/incremental/issue_46666.yaml.world.1.expect @@ -101,19 +101,19 @@ constants { #C6 = dart.ffi::_FfiStructLayout {fieldTypes:#C4, packing:#C5} #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = 0 - #C9 = [#C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8] + #C9 = [#C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8] #C10 = 4 #C11 = 8 - #C12 = [#C10, #C11, #C10, #C11, #C11, #C11, #C11, #C10, #C11, #C11, #C10, #C11, #C10, #C11, #C10, #C11, #C11, #C11, #C11, #C10, #C11] + #C12 = [#C10, #C11, #C10, #C11, #C11, #C11, #C11, #C11, #C10, #C11, #C11, #C10, #C11, #C10, #C11, #C10, #C11, #C11, #C11, #C11, #C10, #C11] #C13 = 16 - #C14 = [#C11, #C13, #C11, #C13, #C13, #C13, #C13, #C11, #C13, #C13, #C11, #C13, #C11, #C13, #C11, #C13, #C13, #C13, #C13, #C11, #C13] + #C14 = [#C11, #C13, #C11, #C13, #C13, #C13, #C13, #C13, #C11, #C13, #C13, #C11, #C13, #C11, #C13, #C11, #C13, #C13, #C13, #C13, #C11, #C13] #C15 = 12 #C16 = 24 - #C17 = [#C15, #C16, #C15, #C16, #C16, #C16, #C16, #C15, #C16, #C16, #C15, #C16, #C15, #C16, #C15, #C16, #C16, #C16, #C16, #C15, #C16] + #C17 = [#C15, #C16, #C15, #C16, #C16, #C16, #C16, #C16, #C15, #C16, #C16, #C15, #C16, #C15, #C16, #C15, #C16, #C16, #C16, #C16, #C15, #C16] #C18 = "vm:prefer-inline" #C19 = dart.core::pragma {name:#C18, options:#C5} #C20 = 48 - #C21 = [#C16, #C20, #C16, #C20, #C20, #C20, #C20, #C16, #C20, #C20, #C16, #C20, #C16, #C20, #C16, #C20, #C20, #C20, #C20, #C16, #C20] + #C21 = [#C16, #C20, #C16, #C20, #C20, #C20, #C20, #C20, #C16, #C20, #C20, #C16, #C20, #C16, #C20, #C16, #C20, #C20, #C20, #C20, #C16, #C20] #C22 = [#C2, #C2, #C2] #C23 = dart.ffi::_FfiStructLayout {fieldTypes:#C22, packing:#C5} #C24 = dart.core::pragma {name:#C1, options:#C23} diff --git a/pkg/front_end/testcases/incremental/issue_46666.yaml.world.2.expect b/pkg/front_end/testcases/incremental/issue_46666.yaml.world.2.expect index df0e2556612..e268e5a6e2c 100644 --- a/pkg/front_end/testcases/incremental/issue_46666.yaml.world.2.expect +++ b/pkg/front_end/testcases/incremental/issue_46666.yaml.world.2.expect @@ -101,19 +101,19 @@ constants { #C6 = dart.ffi::_FfiStructLayout {fieldTypes:#C4, packing:#C5} #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = 0 - #C9 = [#C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8] + #C9 = [#C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8] #C10 = 4 #C11 = 8 - #C12 = [#C10, #C11, #C10, #C11, #C11, #C11, #C11, #C10, #C11, #C11, #C10, #C11, #C10, #C11, #C10, #C11, #C11, #C11, #C11, #C10, #C11] + #C12 = [#C10, #C11, #C10, #C11, #C11, #C11, #C11, #C11, #C10, #C11, #C11, #C10, #C11, #C10, #C11, #C10, #C11, #C11, #C11, #C11, #C10, #C11] #C13 = 16 - #C14 = [#C11, #C13, #C11, #C13, #C13, #C13, #C13, #C11, #C13, #C13, #C11, #C13, #C11, #C13, #C11, #C13, #C13, #C13, #C13, #C11, #C13] + #C14 = [#C11, #C13, #C11, #C13, #C13, #C13, #C13, #C13, #C11, #C13, #C13, #C11, #C13, #C11, #C13, #C11, #C13, #C13, #C13, #C13, #C11, #C13] #C15 = 12 #C16 = 24 - #C17 = [#C15, #C16, #C15, #C16, #C16, #C16, #C16, #C15, #C16, #C16, #C15, #C16, #C15, #C16, #C15, #C16, #C16, #C16, #C16, #C15, #C16] + #C17 = [#C15, #C16, #C15, #C16, #C16, #C16, #C16, #C16, #C15, #C16, #C16, #C15, #C16, #C15, #C16, #C15, #C16, #C16, #C16, #C16, #C15, #C16] #C18 = "vm:prefer-inline" #C19 = dart.core::pragma {name:#C18, options:#C5} #C20 = 48 - #C21 = [#C16, #C20, #C16, #C20, #C20, #C20, #C20, #C16, #C20, #C20, #C16, #C20, #C16, #C20, #C16, #C20, #C20, #C20, #C20, #C16, #C20] + #C21 = [#C16, #C20, #C16, #C20, #C20, #C20, #C20, #C20, #C16, #C20, #C20, #C16, #C20, #C16, #C20, #C16, #C20, #C20, #C20, #C20, #C16, #C20] #C22 = [#C2, #C2, #C2] #C23 = dart.ffi::_FfiStructLayout {fieldTypes:#C22, packing:#C5} #C24 = dart.core::pragma {name:#C1, options:#C23} diff --git a/pkg/front_end/testcases/incremental/no_outline_change_35.yaml.world.1.expect b/pkg/front_end/testcases/incremental/no_outline_change_35.yaml.world.1.expect index 493098144b3..53eb404fd5c 100644 --- a/pkg/front_end/testcases/incremental/no_outline_change_35.yaml.world.1.expect +++ b/pkg/front_end/testcases/incremental/no_outline_change_35.yaml.world.1.expect @@ -53,16 +53,16 @@ constants { #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = dart.ffi::Double {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 8 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = 16 - #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] + #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] #C15 = "vm:prefer-inline" #C16 = dart.core::pragma {name:#C15, options:#C5} #C17 = 24 #C18 = 20 - #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] + #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] } diff --git a/pkg/front_end/testcases/incremental/no_outline_change_35.yaml.world.2.expect b/pkg/front_end/testcases/incremental/no_outline_change_35.yaml.world.2.expect index 2d2e604f53f..ff8987768b0 100644 --- a/pkg/front_end/testcases/incremental/no_outline_change_35.yaml.world.2.expect +++ b/pkg/front_end/testcases/incremental/no_outline_change_35.yaml.world.2.expect @@ -54,16 +54,16 @@ constants { #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = dart.ffi::Double {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 8 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = 16 - #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] + #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] #C15 = "vm:prefer-inline" #C16 = dart.core::pragma {name:#C15, options:#C5} #C17 = 24 #C18 = 20 - #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] + #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] } diff --git a/pkg/front_end/testcases/incremental/no_outline_change_35.yaml.world.3.expect b/pkg/front_end/testcases/incremental/no_outline_change_35.yaml.world.3.expect index 5c41819ef49..f84fbdedd02 100644 --- a/pkg/front_end/testcases/incremental/no_outline_change_35.yaml.world.3.expect +++ b/pkg/front_end/testcases/incremental/no_outline_change_35.yaml.world.3.expect @@ -55,16 +55,16 @@ constants { #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = dart.ffi::Double {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 8 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = 16 - #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] + #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] #C15 = "vm:prefer-inline" #C16 = dart.core::pragma {name:#C15, options:#C5} #C17 = 24 #C18 = 20 - #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] + #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] } diff --git a/pkg/front_end/testcases/incremental/no_outline_change_48_ffi.yaml.world.1.expect b/pkg/front_end/testcases/incremental/no_outline_change_48_ffi.yaml.world.1.expect index cacd8e979b4..14d56027099 100644 --- a/pkg/front_end/testcases/incremental/no_outline_change_48_ffi.yaml.world.1.expect +++ b/pkg/front_end/testcases/incremental/no_outline_change_48_ffi.yaml.world.1.expect @@ -82,28 +82,28 @@ constants { #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = dart.ffi::Uint8 {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 1 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = dart.ffi::Uint64 {} #C14 = 8 #C15 = 4 - #C16 = [#C14, #C14, #C15, #C14, #C14, #C14, #C14, #C15, #C14, #C14, #C14, #C14, #C15, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14] + #C16 = [#C14, #C14, #C15, #C14, #C14, #C14, #C14, #C14, #C15, #C14, #C14, #C14, #C14, #C15, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14] #C17 = "vm:prefer-inline" #C18 = dart.core::pragma {name:#C17, options:#C5} #C19 = 16 #C20 = 12 - #C21 = [#C19, #C19, #C20, #C19, #C19, #C19, #C19, #C20, #C19, #C19, #C19, #C19, #C20, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19] + #C21 = [#C19, #C19, #C20, #C19, #C19, #C19, #C19, #C19, #C20, #C19, #C19, #C19, #C19, #C20, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19] #C22 = TypeLiteralConstant(lib::Y) #C23 = [#C22, #C22, #C2] #C24 = dart.ffi::_FfiStructLayout {fieldTypes:#C23, packing:#C5} #C25 = dart.core::pragma {name:#C1, options:#C24} #C26 = 32 #C27 = 24 - #C28 = [#C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C26, #C26, #C26] + #C28 = [#C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C26, #C26, #C26] #C29 = 40 #C30 = 28 - #C31 = [#C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29] + #C31 = [#C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29] } diff --git a/pkg/front_end/testcases/incremental/no_outline_change_48_ffi.yaml.world.2.expect b/pkg/front_end/testcases/incremental/no_outline_change_48_ffi.yaml.world.2.expect index e0898a88c6c..e46ec00519c 100644 --- a/pkg/front_end/testcases/incremental/no_outline_change_48_ffi.yaml.world.2.expect +++ b/pkg/front_end/testcases/incremental/no_outline_change_48_ffi.yaml.world.2.expect @@ -82,28 +82,28 @@ constants { #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = dart.ffi::Uint8 {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = dart.ffi::Uint64 {} #C12 = 8 #C13 = 4 - #C14 = [#C12, #C12, #C13, #C12, #C12, #C12, #C12, #C13, #C12, #C12, #C12, #C12, #C13, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12] + #C14 = [#C12, #C12, #C13, #C12, #C12, #C12, #C12, #C12, #C13, #C12, #C12, #C12, #C12, #C13, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12] #C15 = 16 #C16 = 12 - #C17 = [#C15, #C15, #C16, #C15, #C15, #C15, #C15, #C16, #C15, #C15, #C15, #C15, #C16, #C15, #C15, #C15, #C15, #C15, #C15, #C15, #C15] + #C17 = [#C15, #C15, #C16, #C15, #C15, #C15, #C15, #C15, #C16, #C15, #C15, #C15, #C15, #C16, #C15, #C15, #C15, #C15, #C15, #C15, #C15, #C15] #C18 = "vm:prefer-inline" #C19 = dart.core::pragma {name:#C18, options:#C5} #C20 = 24 - #C21 = [#C20, #C20, #C15, #C20, #C20, #C20, #C20, #C15, #C20, #C20, #C20, #C20, #C15, #C20, #C20, #C20, #C20, #C20, #C20, #C20, #C20] + #C21 = [#C20, #C20, #C15, #C20, #C20, #C20, #C20, #C20, #C15, #C20, #C20, #C20, #C20, #C15, #C20, #C20, #C20, #C20, #C20, #C20, #C20, #C20] #C22 = TypeLiteralConstant(lib::Y) #C23 = [#C22, #C22, #C2] #C24 = dart.ffi::_FfiStructLayout {fieldTypes:#C23, packing:#C5} #C25 = dart.core::pragma {name:#C1, options:#C24} #C26 = 48 #C27 = 32 - #C28 = [#C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C26, #C26, #C26] + #C28 = [#C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C26, #C26, #C26] #C29 = 56 #C30 = 36 - #C31 = [#C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29] + #C31 = [#C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29] } diff --git a/pkg/front_end/testcases/incremental/no_outline_change_49_ffi.yaml.world.1.expect b/pkg/front_end/testcases/incremental/no_outline_change_49_ffi.yaml.world.1.expect index cacd8e979b4..14d56027099 100644 --- a/pkg/front_end/testcases/incremental/no_outline_change_49_ffi.yaml.world.1.expect +++ b/pkg/front_end/testcases/incremental/no_outline_change_49_ffi.yaml.world.1.expect @@ -82,28 +82,28 @@ constants { #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = dart.ffi::Uint8 {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 1 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = dart.ffi::Uint64 {} #C14 = 8 #C15 = 4 - #C16 = [#C14, #C14, #C15, #C14, #C14, #C14, #C14, #C15, #C14, #C14, #C14, #C14, #C15, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14] + #C16 = [#C14, #C14, #C15, #C14, #C14, #C14, #C14, #C14, #C15, #C14, #C14, #C14, #C14, #C15, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14] #C17 = "vm:prefer-inline" #C18 = dart.core::pragma {name:#C17, options:#C5} #C19 = 16 #C20 = 12 - #C21 = [#C19, #C19, #C20, #C19, #C19, #C19, #C19, #C20, #C19, #C19, #C19, #C19, #C20, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19] + #C21 = [#C19, #C19, #C20, #C19, #C19, #C19, #C19, #C19, #C20, #C19, #C19, #C19, #C19, #C20, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19] #C22 = TypeLiteralConstant(lib::Y) #C23 = [#C22, #C22, #C2] #C24 = dart.ffi::_FfiStructLayout {fieldTypes:#C23, packing:#C5} #C25 = dart.core::pragma {name:#C1, options:#C24} #C26 = 32 #C27 = 24 - #C28 = [#C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C26, #C26, #C26] + #C28 = [#C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C26, #C26, #C26] #C29 = 40 #C30 = 28 - #C31 = [#C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29] + #C31 = [#C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29] } diff --git a/pkg/front_end/testcases/incremental/no_outline_change_49_ffi.yaml.world.2.expect b/pkg/front_end/testcases/incremental/no_outline_change_49_ffi.yaml.world.2.expect index e0898a88c6c..e46ec00519c 100644 --- a/pkg/front_end/testcases/incremental/no_outline_change_49_ffi.yaml.world.2.expect +++ b/pkg/front_end/testcases/incremental/no_outline_change_49_ffi.yaml.world.2.expect @@ -82,28 +82,28 @@ constants { #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = dart.ffi::Uint8 {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = dart.ffi::Uint64 {} #C12 = 8 #C13 = 4 - #C14 = [#C12, #C12, #C13, #C12, #C12, #C12, #C12, #C13, #C12, #C12, #C12, #C12, #C13, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12] + #C14 = [#C12, #C12, #C13, #C12, #C12, #C12, #C12, #C12, #C13, #C12, #C12, #C12, #C12, #C13, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12] #C15 = 16 #C16 = 12 - #C17 = [#C15, #C15, #C16, #C15, #C15, #C15, #C15, #C16, #C15, #C15, #C15, #C15, #C16, #C15, #C15, #C15, #C15, #C15, #C15, #C15, #C15] + #C17 = [#C15, #C15, #C16, #C15, #C15, #C15, #C15, #C15, #C16, #C15, #C15, #C15, #C15, #C16, #C15, #C15, #C15, #C15, #C15, #C15, #C15, #C15] #C18 = "vm:prefer-inline" #C19 = dart.core::pragma {name:#C18, options:#C5} #C20 = 24 - #C21 = [#C20, #C20, #C15, #C20, #C20, #C20, #C20, #C15, #C20, #C20, #C20, #C20, #C15, #C20, #C20, #C20, #C20, #C20, #C20, #C20, #C20] + #C21 = [#C20, #C20, #C15, #C20, #C20, #C20, #C20, #C20, #C15, #C20, #C20, #C20, #C20, #C15, #C20, #C20, #C20, #C20, #C20, #C20, #C20, #C20] #C22 = TypeLiteralConstant(lib::Y) #C23 = [#C22, #C22, #C2] #C24 = dart.ffi::_FfiStructLayout {fieldTypes:#C23, packing:#C5} #C25 = dart.core::pragma {name:#C1, options:#C24} #C26 = 48 #C27 = 32 - #C28 = [#C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C26, #C26, #C26] + #C28 = [#C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C26, #C26, #C26] #C29 = 56 #C30 = 36 - #C31 = [#C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29] + #C31 = [#C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29] } diff --git a/pkg/front_end/testcases/incremental/no_outline_change_50_ffi.yaml.world.1.expect b/pkg/front_end/testcases/incremental/no_outline_change_50_ffi.yaml.world.1.expect index ad40d2e640c..e81e2acc2d3 100644 --- a/pkg/front_end/testcases/incremental/no_outline_change_50_ffi.yaml.world.1.expect +++ b/pkg/front_end/testcases/incremental/no_outline_change_50_ffi.yaml.world.1.expect @@ -274,28 +274,28 @@ constants { #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = dart.ffi::Uint8 {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 1 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = dart.ffi::Uint64 {} #C14 = 8 #C15 = 4 - #C16 = [#C14, #C14, #C15, #C14, #C14, #C14, #C14, #C15, #C14, #C14, #C14, #C14, #C15, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14] + #C16 = [#C14, #C14, #C15, #C14, #C14, #C14, #C14, #C14, #C15, #C14, #C14, #C14, #C14, #C15, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14] #C17 = "vm:prefer-inline" #C18 = dart.core::pragma {name:#C17, options:#C5} #C19 = 16 #C20 = 12 - #C21 = [#C19, #C19, #C20, #C19, #C19, #C19, #C19, #C20, #C19, #C19, #C19, #C19, #C20, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19] + #C21 = [#C19, #C19, #C20, #C19, #C19, #C19, #C19, #C19, #C20, #C19, #C19, #C19, #C19, #C20, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19] #C22 = TypeLiteralConstant(lib::Y) #C23 = [#C22, #C22, #C2] #C24 = dart.ffi::_FfiStructLayout {fieldTypes:#C23, packing:#C5} #C25 = dart.core::pragma {name:#C1, options:#C24} #C26 = 32 #C27 = 24 - #C28 = [#C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C26, #C26, #C26] + #C28 = [#C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C26, #C26, #C26] #C29 = 40 #C30 = 28 - #C31 = [#C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29] + #C31 = [#C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29] } diff --git a/pkg/front_end/testcases/incremental/no_outline_change_50_ffi.yaml.world.2.expect b/pkg/front_end/testcases/incremental/no_outline_change_50_ffi.yaml.world.2.expect index 4580f448da6..982dfc43062 100644 --- a/pkg/front_end/testcases/incremental/no_outline_change_50_ffi.yaml.world.2.expect +++ b/pkg/front_end/testcases/incremental/no_outline_change_50_ffi.yaml.world.2.expect @@ -274,28 +274,28 @@ constants { #C7 = dart.core::pragma {name:#C1, options:#C6} #C8 = dart.ffi::Uint8 {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = dart.ffi::Uint64 {} #C12 = 8 #C13 = 4 - #C14 = [#C12, #C12, #C13, #C12, #C12, #C12, #C12, #C13, #C12, #C12, #C12, #C12, #C13, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12] + #C14 = [#C12, #C12, #C13, #C12, #C12, #C12, #C12, #C12, #C13, #C12, #C12, #C12, #C12, #C13, #C12, #C12, #C12, #C12, #C12, #C12, #C12, #C12] #C15 = 16 #C16 = 12 - #C17 = [#C15, #C15, #C16, #C15, #C15, #C15, #C15, #C16, #C15, #C15, #C15, #C15, #C16, #C15, #C15, #C15, #C15, #C15, #C15, #C15, #C15] + #C17 = [#C15, #C15, #C16, #C15, #C15, #C15, #C15, #C15, #C16, #C15, #C15, #C15, #C15, #C16, #C15, #C15, #C15, #C15, #C15, #C15, #C15, #C15] #C18 = "vm:prefer-inline" #C19 = dart.core::pragma {name:#C18, options:#C5} #C20 = 24 - #C21 = [#C20, #C20, #C15, #C20, #C20, #C20, #C20, #C15, #C20, #C20, #C20, #C20, #C15, #C20, #C20, #C20, #C20, #C20, #C20, #C20, #C20] + #C21 = [#C20, #C20, #C15, #C20, #C20, #C20, #C20, #C20, #C15, #C20, #C20, #C20, #C20, #C15, #C20, #C20, #C20, #C20, #C20, #C20, #C20, #C20] #C22 = TypeLiteralConstant(lib::Y) #C23 = [#C22, #C22, #C2] #C24 = dart.ffi::_FfiStructLayout {fieldTypes:#C23, packing:#C5} #C25 = dart.core::pragma {name:#C1, options:#C24} #C26 = 48 #C27 = 32 - #C28 = [#C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C26, #C26, #C26] + #C28 = [#C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C27, #C26, #C26, #C26, #C26, #C26, #C26, #C26, #C26] #C29 = 56 #C30 = 36 - #C31 = [#C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29] + #C31 = [#C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C30, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29] } diff --git a/pkg/front_end/testcases/incremental/regress_46004.yaml.world.1.expect b/pkg/front_end/testcases/incremental/regress_46004.yaml.world.1.expect index 1065be5d40c..a00dcc2bf1d 100644 --- a/pkg/front_end/testcases/incremental/regress_46004.yaml.world.1.expect +++ b/pkg/front_end/testcases/incremental/regress_46004.yaml.world.1.expect @@ -55,12 +55,12 @@ constants { #C5 = dart.ffi::_FfiStructLayout {fieldTypes:#C3, packing:#C4} #C6 = dart.core::pragma {name:#C1, options:#C5} #C7 = 0 - #C8 = [#C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7] + #C8 = [#C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7] #C9 = "vm:prefer-inline" #C10 = dart.core::pragma {name:#C9, options:#C4} #C11 = 4 #C12 = 8 - #C13 = [#C11, #C12, #C11, #C12, #C12, #C12, #C12, #C11, #C12, #C12, #C11, #C12, #C11, #C12, #C11, #C12, #C12, #C12, #C12, #C11, #C12] + #C13 = [#C11, #C12, #C11, #C12, #C12, #C12, #C12, #C12, #C11, #C12, #C12, #C11, #C12, #C11, #C12, #C11, #C12, #C12, #C12, #C12, #C11, #C12] #C14 = TypeLiteralConstant(lib::COMObject) #C15 = [#C14] #C16 = dart.ffi::_FfiStructLayout {fieldTypes:#C15, packing:#C4} diff --git a/pkg/front_end/testcases/incremental/regress_46004.yaml.world.2.expect b/pkg/front_end/testcases/incremental/regress_46004.yaml.world.2.expect index 1065be5d40c..a00dcc2bf1d 100644 --- a/pkg/front_end/testcases/incremental/regress_46004.yaml.world.2.expect +++ b/pkg/front_end/testcases/incremental/regress_46004.yaml.world.2.expect @@ -55,12 +55,12 @@ constants { #C5 = dart.ffi::_FfiStructLayout {fieldTypes:#C3, packing:#C4} #C6 = dart.core::pragma {name:#C1, options:#C5} #C7 = 0 - #C8 = [#C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7] + #C8 = [#C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7, #C7] #C9 = "vm:prefer-inline" #C10 = dart.core::pragma {name:#C9, options:#C4} #C11 = 4 #C12 = 8 - #C13 = [#C11, #C12, #C11, #C12, #C12, #C12, #C12, #C11, #C12, #C12, #C11, #C12, #C11, #C12, #C11, #C12, #C12, #C12, #C12, #C11, #C12] + #C13 = [#C11, #C12, #C11, #C12, #C12, #C12, #C12, #C12, #C11, #C12, #C12, #C11, #C12, #C11, #C12, #C11, #C12, #C12, #C12, #C12, #C11, #C12] #C14 = TypeLiteralConstant(lib::COMObject) #C15 = [#C14] #C16 = dart.ffi::_FfiStructLayout {fieldTypes:#C15, packing:#C4} diff --git a/pkg/front_end/testcases/nnbd/ffi_sample.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/ffi_sample.dart.strong.transformed.expect index 817d64c06eb..428591fb70a 100644 --- a/pkg/front_end/testcases/nnbd/ffi_sample.dart.strong.transformed.expect +++ b/pkg/front_end/testcases/nnbd/ffi_sample.dart.strong.transformed.expect @@ -50,16 +50,16 @@ constants { #C7 = core::pragma {name:#C1, options:#C6} #C8 = ffi::Double {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 8 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = 16 - #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] + #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] #C15 = "vm:prefer-inline" #C16 = core::pragma {name:#C15, options:#C5} #C17 = 24 #C18 = 20 - #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] + #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] } diff --git a/pkg/front_end/testcases/nnbd/ffi_sample.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/ffi_sample.dart.weak.transformed.expect index 817d64c06eb..428591fb70a 100644 --- a/pkg/front_end/testcases/nnbd/ffi_sample.dart.weak.transformed.expect +++ b/pkg/front_end/testcases/nnbd/ffi_sample.dart.weak.transformed.expect @@ -50,16 +50,16 @@ constants { #C7 = core::pragma {name:#C1, options:#C6} #C8 = ffi::Double {} #C9 = 0 - #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] + #C10 = [#C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9, #C9] #C11 = 8 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = 16 - #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] + #C14 = [#C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13, #C13] #C15 = "vm:prefer-inline" #C16 = core::pragma {name:#C15, options:#C5} #C17 = 24 #C18 = 20 - #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] + #C19 = [#C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C18, #C17, #C17, #C17, #C17, #C17, #C17, #C17, #C17] } diff --git a/pkg/front_end/testcases/nnbd/ffi_struct_inline_array.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/ffi_struct_inline_array.dart.strong.transformed.expect index 0ff4b8a0f33..c9db1138219 100644 --- a/pkg/front_end/testcases/nnbd/ffi_struct_inline_array.dart.strong.transformed.expect +++ b/pkg/front_end/testcases/nnbd/ffi_struct_inline_array.dart.strong.transformed.expect @@ -42,8 +42,8 @@ constants { #C8 = core::pragma {name:#C1, options:#C7} #C9 = ffi::_ArraySize {dimension1:#C3, dimension2:#C6, dimension3:#C6, dimension4:#C6, dimension5:#C6, dimensions:#C6} #C10 = 0 - #C11 = [#C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10] - #C12 = [#C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3] + #C11 = [#C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10] + #C12 = [#C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3] #C13 = [] #C14 = "vm:prefer-inline" #C15 = core::pragma {name:#C14, options:#C6} diff --git a/pkg/front_end/testcases/nnbd/ffi_struct_inline_array.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/ffi_struct_inline_array.dart.weak.transformed.expect index 61724fe11ce..f753741ce45 100644 --- a/pkg/front_end/testcases/nnbd/ffi_struct_inline_array.dart.weak.transformed.expect +++ b/pkg/front_end/testcases/nnbd/ffi_struct_inline_array.dart.weak.transformed.expect @@ -42,8 +42,8 @@ constants { #C8 = core::pragma {name:#C1, options:#C7} #C9 = ffi::_ArraySize {dimension1:#C3, dimension2:#C6, dimension3:#C6, dimension4:#C6, dimension5:#C6, dimensions:#C6} #C10 = 0 - #C11 = [#C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10] - #C12 = [#C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3] + #C11 = [#C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10] + #C12 = [#C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3] #C13 = [] #C14 = "vm:prefer-inline" #C15 = core::pragma {name:#C14, options:#C6} diff --git a/pkg/front_end/testcases/nnbd/ffi_struct_inline_array_multi_dimensional.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/ffi_struct_inline_array_multi_dimensional.dart.strong.transformed.expect index 3bd25c78bc1..2bc2c885fc5 100644 --- a/pkg/front_end/testcases/nnbd/ffi_struct_inline_array_multi_dimensional.dart.strong.transformed.expect +++ b/pkg/front_end/testcases/nnbd/ffi_struct_inline_array_multi_dimensional.dart.strong.transformed.expect @@ -67,8 +67,8 @@ constants { #C9 = 2 #C10 = ffi::_ArraySize {dimension1:#C9, dimension2:#C9, dimension3:#C9, dimension4:#C6, dimension5:#C6, dimensions:#C6} #C11 = 0 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] - #C13 = [#C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C13 = [#C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3] #C14 = [#C9, #C9] #C15 = "vm:prefer-inline" #C16 = core::pragma {name:#C15, options:#C6} diff --git a/pkg/front_end/testcases/nnbd/ffi_struct_inline_array_multi_dimensional.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/ffi_struct_inline_array_multi_dimensional.dart.weak.transformed.expect index ea0ec399710..e6655f3ca1d 100644 --- a/pkg/front_end/testcases/nnbd/ffi_struct_inline_array_multi_dimensional.dart.weak.transformed.expect +++ b/pkg/front_end/testcases/nnbd/ffi_struct_inline_array_multi_dimensional.dart.weak.transformed.expect @@ -67,8 +67,8 @@ constants { #C9 = 2 #C10 = ffi::_ArraySize {dimension1:#C9, dimension2:#C9, dimension3:#C9, dimension4:#C6, dimension5:#C6, dimensions:#C6} #C11 = 0 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] - #C13 = [#C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C13 = [#C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3, #C3] #C14 = [#C9, #C9] #C15 = "vm:prefer-inline" #C16 = core::pragma {name:#C15, options:#C6} diff --git a/pkg/vm/lib/transformations/ffi/abi.dart b/pkg/vm/lib/transformations/ffi/abi.dart index 810497503d5..68cbb9edf60 100644 --- a/pkg/vm/lib/transformations/ffi/abi.dart +++ b/pkg/vm/lib/transformations/ffi/abi.dart @@ -60,9 +60,12 @@ class Abi { /// The application binary interface for Android on the IA32 architecture. static const androidIA32 = _androidIA32; - /// The application binary interface for android on the X64 architecture. + /// The application binary interface for Android on the X64 architecture. static const androidX64 = _androidX64; + /// The application binary interface for Android on 64-bit RISC-V. + static const androidRiscv64 = _androidRiscv64; + /// The application binary interface for Fuchsia on the Arm64 architecture. static const fuchsiaArm64 = _fuchsiaArm64; @@ -130,6 +133,7 @@ class Abi { androidArm64, androidIA32, androidX64, + androidRiscv64, fuchsiaArm64, fuchsiaX64, fuchsiaRiscv64, @@ -176,6 +180,7 @@ class Abi { static const _androidArm64 = Abi._(_Architecture.arm64, _OS.android); static const _androidIA32 = Abi._(_Architecture.ia32, _OS.android); static const _androidX64 = Abi._(_Architecture.x64, _OS.android); + static const _androidRiscv64 = Abi._(_Architecture.riscv64, _OS.android); static const _fuchsiaArm64 = Abi._(_Architecture.arm64, _OS.fuchsia); static const _fuchsiaX64 = Abi._(_Architecture.x64, _OS.fuchsia); static const _fuchsiaRiscv64 = Abi._(_Architecture.riscv64, _OS.fuchsia); @@ -201,6 +206,7 @@ const Map abiNames = { Abi.androidArm64: 'androidArm64', Abi.androidIA32: 'androidIA32', Abi.androidX64: 'androidX64', + Abi.androidRiscv64: 'androidRiscv64', Abi.fuchsiaArm64: 'fuchsiaArm64', Abi.fuchsiaX64: 'fuchsiaX64', Abi.fuchsiaRiscv64: 'fuchsiaRiscv64', @@ -243,6 +249,7 @@ const Map> nonSizeAlignment = { // _wordSize64 Abi.androidArm64: _wordSize64, Abi.androidX64: _wordSize64, + Abi.androidRiscv64: _wordSize64, Abi.fuchsiaArm64: _wordSize64, Abi.fuchsiaX64: _wordSize64, Abi.fuchsiaRiscv64: _wordSize64, diff --git a/pkg/vm/testcases/transformations/ffi/abi_specific_int.dart b/pkg/vm/testcases/transformations/ffi/abi_specific_int.dart index d9549479c7c..6d4e7b0871e 100644 --- a/pkg/vm/testcases/transformations/ffi/abi_specific_int.dart +++ b/pkg/vm/testcases/transformations/ffi/abi_specific_int.dart @@ -9,6 +9,7 @@ import 'dart:ffi'; Abi.androidArm64: Uint32(), Abi.androidIA32: Uint32(), Abi.androidX64: Uint32(), + Abi.androidRiscv64: Int32(), Abi.fuchsiaArm64: Uint32(), Abi.fuchsiaX64: Uint32(), Abi.fuchsiaRiscv64: Uint32(), diff --git a/pkg/vm/testcases/transformations/ffi/abi_specific_int.dart.aot.expect b/pkg/vm/testcases/transformations/ffi/abi_specific_int.dart.aot.expect index 5d4ced5e7f1..0dc6959a808 100644 --- a/pkg/vm/testcases/transformations/ffi/abi_specific_int.dart.aot.expect +++ b/pkg/vm/testcases/transformations/ffi/abi_specific_int.dart.aot.expect @@ -95,7 +95,7 @@ constants { #C2 = TypeLiteralConstant(ffi::Uint32) #C3 = TypeLiteralConstant(ffi::Int32) #C4 = TypeLiteralConstant(ffi::Uint16) - #C5 = [#C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C3, #C3, #C3, #C3, #C2, #C2, #C4, #C4, #C4] + #C5 = [#C2, #C2, #C2, #C2, #C3, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C3, #C3, #C3, #C3, #C2, #C2, #C4, #C4, #C4] #C6 = ffi::_FfiAbiSpecificMapping {nativeTypes:#C5} #C7 = core::pragma {name:#C1, options:#C6} #C8 = "vm:prefer-inline" @@ -103,16 +103,16 @@ constants { #C10 = core::pragma {name:#C8, options:#C9} #C11 = 4 #C12 = 2 - #C13 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C12, #C12, #C12] + #C13 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C12, #C12, #C12] #C14 = "vm:ffi:struct-fields" #C15 = TypeLiteralConstant(self::WChar) #C16 = [#C15, #C15] #C17 = ffi::_FfiStructLayout {fieldTypes:#C16, packing:#C9} #C18 = core::pragma {name:#C14, options:#C17} #C19 = 0 - #C20 = [#C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19] + #C20 = [#C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19, #C19] #C21 = 8 - #C22 = [#C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C11, #C11, #C11] + #C22 = [#C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C21, #C11, #C11, #C11] #C23 = 100 #C24 = ffi::_FfiInlineArray {elementType:#C15, length:#C23} #C25 = [#C24] @@ -121,6 +121,6 @@ constants { #C28 = [] #C29 = 400 #C30 = 200 - #C31 = [#C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C30, #C30, #C30] + #C31 = [#C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C29, #C30, #C30, #C30] #C32 = self::_DummyAllocator {} } diff --git a/pkg/vm/testcases/transformations/ffi/abi_specific_int.dart.expect b/pkg/vm/testcases/transformations/ffi/abi_specific_int.dart.expect index 85eb129de3e..a99e27adc23 100644 --- a/pkg/vm/testcases/transformations/ffi/abi_specific_int.dart.expect +++ b/pkg/vm/testcases/transformations/ffi/abi_specific_int.dart.expect @@ -7,17 +7,17 @@ import "dart:_internal" as _in; import "dart:ffi"; -@#C56 -@#C63 +@#C57 +@#C64 final class WChar extends ffi::AbiSpecificInteger /*hasConstConstructor*/ { const constructor •() → self::WChar : super ffi::AbiSpecificInteger::•() ; - @#C66 + @#C67 static get #sizeOf() → core::int* - return #C67.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}; + return #C68.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}; } -@#C72 +@#C73 final class WCharStruct extends ffi::Struct { synthetic constructor •() → self::WCharStruct : super ffi::Struct::•() @@ -25,23 +25,23 @@ final class WCharStruct extends ffi::Struct { constructor #fromTypedDataBase(synthesized core::Object #typedDataBase) → self::WCharStruct : super ffi::Struct::_fromTypedDataBase(#typedDataBase) ; - @#C73 + @#C74 get a0() → core::int - return ffi::_loadAbiSpecificInt(this.{ffi::_Compound::_typedDataBase}{core::Object}, #C74.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}); - @#C73 + return ffi::_loadAbiSpecificInt(this.{ffi::_Compound::_typedDataBase}{core::Object}, #C75.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}); + @#C74 set a0(core::int #externalFieldValue) → void - return ffi::_storeAbiSpecificInt(this.{ffi::_Compound::_typedDataBase}{core::Object}, #C74.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}, #externalFieldValue); - @#C73 + return ffi::_storeAbiSpecificInt(this.{ffi::_Compound::_typedDataBase}{core::Object}, #C75.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}, #externalFieldValue); + @#C74 get a1() → core::int - return ffi::_loadAbiSpecificInt(this.{ffi::_Compound::_typedDataBase}{core::Object}, #C67.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}); - @#C73 + return ffi::_loadAbiSpecificInt(this.{ffi::_Compound::_typedDataBase}{core::Object}, #C68.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}); + @#C74 set a1(core::int #externalFieldValue) → void - return ffi::_storeAbiSpecificInt(this.{ffi::_Compound::_typedDataBase}{core::Object}, #C67.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}, #externalFieldValue); - @#C66 + return ffi::_storeAbiSpecificInt(this.{ffi::_Compound::_typedDataBase}{core::Object}, #C68.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}, #externalFieldValue); + @#C67 static get #sizeOf() → core::int* - return #C76.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}; + return #C77.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}; } -@#C81 +@#C82 final class WCharArrayStruct extends ffi::Struct { synthetic constructor •() → self::WCharArrayStruct : super ffi::Struct::•() @@ -49,31 +49,31 @@ final class WCharArrayStruct extends ffi::Struct { constructor #fromTypedDataBase(synthesized core::Object #typedDataBase) → self::WCharArrayStruct : super ffi::Struct::_fromTypedDataBase(#typedDataBase) ; - @#C82 + @#C83 get a0() → ffi::Array return new ffi::Array::_( block { synthesized core::Object #typedDataBase = this.{ffi::_Compound::_typedDataBase}{core::Object}; - synthesized core::int #offset = #C74.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}; - } =>#typedDataBase is ffi::Pointer ?{core::Object} ffi::_fromAddress(#typedDataBase.{ffi::Pointer::address}{core::int}.{core::num::+}(#offset){(core::num) → core::num}) : let synthesized typ::TypedData #typedData = _in::unsafeCast(#typedDataBase) in #typedData.{typ::TypedData::buffer}{typ::ByteBuffer}.{typ::ByteBuffer::asUint8List}(#typedData.{typ::TypedData::offsetInBytes}{core::int}.{core::num::+}(#offset){(core::num) → core::num}, #C85.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}){([core::int, core::int?]) → typ::Uint8List}, #C77, #C86); - @#C82 + synthesized core::int #offset = #C75.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}; + } =>#typedDataBase is ffi::Pointer ?{core::Object} ffi::_fromAddress(#typedDataBase.{ffi::Pointer::address}{core::int}.{core::num::+}(#offset){(core::num) → core::num}) : let synthesized typ::TypedData #typedData = _in::unsafeCast(#typedDataBase) in #typedData.{typ::TypedData::buffer}{typ::ByteBuffer}.{typ::ByteBuffer::asUint8List}(#typedData.{typ::TypedData::offsetInBytes}{core::int}.{core::num::+}(#offset){(core::num) → core::num}, #C86.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}){([core::int, core::int?]) → typ::Uint8List}, #C78, #C87); + @#C83 set a0(ffi::Array #externalFieldValue) → void - return ffi::_memCopy(this.{ffi::_Compound::_typedDataBase}{core::Object}, #C74.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}, #externalFieldValue.{ffi::Array::_typedDataBase}{core::Object}, #C1, #C85.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}); - @#C66 + return ffi::_memCopy(this.{ffi::_Compound::_typedDataBase}{core::Object}, #C75.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}, #externalFieldValue.{ffi::Array::_typedDataBase}{core::Object}, #C1, #C86.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}); + @#C67 static get #sizeOf() → core::int* - return #C85.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}; + return #C86.{core::List::[]}(ffi::_abi()){(core::int) → core::int*}; } class _DummyAllocator extends core::Object implements ffi::Allocator /*hasConstConstructor*/ { const constructor •() → self::_DummyAllocator : super core::Object::•() ; - @#C87 - method allocate(core::int byteCount, {core::int? alignment = #C65}) → ffi::Pointer { + @#C88 + method allocate(core::int byteCount, {core::int? alignment = #C66}) → ffi::Pointer { return ffi::Pointer::fromAddress(0); } - @#C87 + @#C88 method free(ffi::Pointer pointer) → void {} } -static const field self::_DummyAllocator noAlloc = #C88; +static const field self::_DummyAllocator noAlloc = #C89; static method main() → void { self::testSizeOf(); self::testStoreLoad(); @@ -86,29 +86,29 @@ static method testSizeOf() → void { core::print(size); } static method testStoreLoad() → void { - final ffi::Pointer p = #C88.{ffi::Allocator::allocate}(self::WChar::#sizeOf){(core::int, {alignment: core::int?}) → ffi::Pointer}; + final ffi::Pointer p = #C89.{ffi::Allocator::allocate}(self::WChar::#sizeOf){(core::int, {alignment: core::int?}) → ffi::Pointer}; ffi::_storeAbiSpecificInt(p, #C1, 10); core::print(ffi::_loadAbiSpecificInt(p, #C1)); - #C88.{self::_DummyAllocator::free}(p){(ffi::Pointer) → void}; + #C89.{self::_DummyAllocator::free}(p){(ffi::Pointer) → void}; } static method testStoreLoadIndexed() → void { - final ffi::Pointer p = #C88.{ffi::Allocator::allocate}(2.{core::num::*}(self::WChar::#sizeOf){(core::num) → core::num}){(core::int, {alignment: core::int?}) → ffi::Pointer}; + final ffi::Pointer p = #C89.{ffi::Allocator::allocate}(2.{core::num::*}(self::WChar::#sizeOf){(core::num) → core::num}){(core::int, {alignment: core::int?}) → ffi::Pointer}; ffi::_storeAbiSpecificIntAtIndex(p, 0, 10); ffi::_storeAbiSpecificIntAtIndex(p, 1, 3); core::print(ffi::_loadAbiSpecificIntAtIndex(p, 0)); core::print(ffi::_loadAbiSpecificIntAtIndex(p, 1)); - #C88.{self::_DummyAllocator::free}(p){(ffi::Pointer) → void}; + #C89.{self::_DummyAllocator::free}(p){(ffi::Pointer) → void}; } static method testStruct() → void { - final ffi::Pointer p = #C88.{ffi::Allocator::allocate}(self::WCharStruct::#sizeOf){(core::int, {alignment: core::int?}) → ffi::Pointer}; + final ffi::Pointer p = #C89.{ffi::Allocator::allocate}(self::WCharStruct::#sizeOf){(core::int, {alignment: core::int?}) → ffi::Pointer}; new self::WCharStruct::#fromTypedDataBase(p!).{self::WCharStruct::a0} = 1; core::print(new self::WCharStruct::#fromTypedDataBase(p!).{self::WCharStruct::a0}{core::int}); new self::WCharStruct::#fromTypedDataBase(p!).{self::WCharStruct::a0} = 2; core::print(new self::WCharStruct::#fromTypedDataBase(p!).{self::WCharStruct::a0}{core::int}); - #C88.{self::_DummyAllocator::free}(p){(ffi::Pointer) → void}; + #C89.{self::_DummyAllocator::free}(p){(ffi::Pointer) → void}; } static method testInlineArray() → void { - final ffi::Pointer p = #C88.{ffi::Allocator::allocate}(self::WCharArrayStruct::#sizeOf){(core::int, {alignment: core::int?}) → ffi::Pointer}; + final ffi::Pointer p = #C89.{ffi::Allocator::allocate}(self::WCharArrayStruct::#sizeOf){(core::int, {alignment: core::int?}) → ffi::Pointer}; final ffi::Array array = new self::WCharArrayStruct::#fromTypedDataBase(p!).{self::WCharArrayStruct::a0}{ffi::Array}; for (core::int i = 0; i.{core::num::<}(100){(core::num) → core::bool}; i = i.{core::num::+}(1){(core::num) → core::int}) { ffi::_storeAbiSpecificIntAtIndex(array.{ffi::Array::_typedDataBase}{core::Object}, i, i); @@ -116,7 +116,7 @@ static method testInlineArray() → void { for (core::int i = 0; i.{core::num::<}(100){(core::num) → core::bool}; i = i.{core::num::+}(1){(core::num) → core::int}) { core::print(ffi::_loadAbiSpecificIntAtIndex(array.{ffi::Array::_typedDataBase}{core::Object}, i)); } - #C88.{self::_DummyAllocator::free}(p){(ffi::Pointer) → void}; + #C89.{self::_DummyAllocator::free}(p){(ffi::Pointer) → void}; } constants { #C1 = 0 @@ -138,73 +138,74 @@ constants { #C17 = "x64" #C18 = ffi::_Architecture {index:#C16, _name:#C17} #C19 = ffi::Abi {_os:#C3, _architecture:#C18} - #C20 = "fuchsia" - #C21 = ffi::_OS {index:#C8, _name:#C20} - #C22 = ffi::Abi {_os:#C21, _architecture:#C10} - #C23 = ffi::Abi {_os:#C21, _architecture:#C18} - #C24 = 5 - #C25 = "riscv64" - #C26 = ffi::_Architecture {index:#C24, _name:#C25} - #C27 = ffi::Abi {_os:#C21, _architecture:#C26} - #C28 = "ios" - #C29 = ffi::_OS {index:#C12, _name:#C28} - #C30 = ffi::Abi {_os:#C29, _architecture:#C5} - #C31 = ffi::Abi {_os:#C29, _architecture:#C10} - #C32 = ffi::Abi {_os:#C29, _architecture:#C18} - #C33 = "linux" - #C34 = ffi::_OS {index:#C16, _name:#C33} - #C35 = ffi::Abi {_os:#C34, _architecture:#C5} - #C36 = ffi::Abi {_os:#C34, _architecture:#C10} - #C37 = ffi::Abi {_os:#C34, _architecture:#C14} - #C38 = ffi::Int32 {} - #C39 = ffi::Abi {_os:#C34, _architecture:#C18} - #C40 = 4 - #C41 = "riscv32" - #C42 = ffi::_Architecture {index:#C40, _name:#C41} - #C43 = ffi::Abi {_os:#C34, _architecture:#C42} - #C44 = ffi::Abi {_os:#C34, _architecture:#C26} - #C45 = "macos" - #C46 = ffi::_OS {index:#C40, _name:#C45} - #C47 = ffi::Abi {_os:#C46, _architecture:#C10} - #C48 = ffi::Abi {_os:#C46, _architecture:#C18} - #C49 = "windows" - #C50 = ffi::_OS {index:#C24, _name:#C49} - #C51 = ffi::Abi {_os:#C50, _architecture:#C10} - #C52 = ffi::Uint16 {} - #C53 = ffi::Abi {_os:#C50, _architecture:#C14} - #C54 = ffi::Abi {_os:#C50, _architecture:#C18} - #C55 = {#C6:#C7, #C11:#C7, #C15:#C7, #C19:#C7, #C22:#C7, #C23:#C7, #C27:#C7, #C30:#C7, #C31:#C7, #C32:#C7, #C35:#C7, #C36:#C7, #C37:#C38, #C39:#C38, #C43:#C38, #C44:#C38, #C47:#C7, #C48:#C7, #C51:#C52, #C53:#C52, #C54:#C52} - #C56 = ffi::AbiSpecificIntegerMapping {mapping:#C55} - #C57 = "vm:ffi:abi-specific-mapping" - #C58 = TypeLiteralConstant(ffi::Uint32) - #C59 = TypeLiteralConstant(ffi::Int32) - #C60 = TypeLiteralConstant(ffi::Uint16) - #C61 = [#C58, #C58, #C58, #C58, #C58, #C58, #C58, #C58, #C58, #C58, #C58, #C58, #C59, #C59, #C59, #C59, #C58, #C58, #C60, #C60, #C60] - #C62 = ffi::_FfiAbiSpecificMapping {nativeTypes:#C61} - #C63 = core::pragma {name:#C57, options:#C62} - #C64 = "vm:prefer-inline" - #C65 = null - #C66 = core::pragma {name:#C64, options:#C65} - #C67 = [#C40, #C40, #C40, #C40, #C40, #C40, #C40, #C40, #C40, #C40, #C40, #C40, #C40, #C40, #C40, #C40, #C40, #C40, #C12, #C12, #C12] - #C68 = "vm:ffi:struct-fields" - #C69 = TypeLiteralConstant(self::WChar) - #C70 = [#C69, #C69] - #C71 = ffi::_FfiStructLayout {fieldTypes:#C70, packing:#C65} - #C72 = core::pragma {name:#C68, options:#C71} - #C73 = self::WChar {} - #C74 = [#C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1] - #C75 = 8 - #C76 = [#C75, #C75, #C75, #C75, #C75, #C75, #C75, #C75, #C75, #C75, #C75, #C75, #C75, #C75, #C75, #C75, #C75, #C75, #C40, #C40, #C40] - #C77 = 100 - #C78 = ffi::_FfiInlineArray {elementType:#C69, length:#C77} - #C79 = [#C78] - #C80 = ffi::_FfiStructLayout {fieldTypes:#C79, packing:#C65} - #C81 = core::pragma {name:#C68, options:#C80} - #C82 = ffi::_ArraySize {dimension1:#C77, dimension2:#C65, dimension3:#C65, dimension4:#C65, dimension5:#C65, dimensions:#C65} - #C83 = 400 - #C84 = 200 - #C85 = [#C83, #C83, #C83, #C83, #C83, #C83, #C83, #C83, #C83, #C83, #C83, #C83, #C83, #C83, #C83, #C83, #C83, #C83, #C84, #C84, #C84] - #C86 = [] - #C87 = core::_Override {} - #C88 = self::_DummyAllocator {} + #C20 = 5 + #C21 = "riscv64" + #C22 = ffi::_Architecture {index:#C20, _name:#C21} + #C23 = ffi::Abi {_os:#C3, _architecture:#C22} + #C24 = ffi::Int32 {} + #C25 = "fuchsia" + #C26 = ffi::_OS {index:#C8, _name:#C25} + #C27 = ffi::Abi {_os:#C26, _architecture:#C10} + #C28 = ffi::Abi {_os:#C26, _architecture:#C18} + #C29 = ffi::Abi {_os:#C26, _architecture:#C22} + #C30 = "ios" + #C31 = ffi::_OS {index:#C12, _name:#C30} + #C32 = ffi::Abi {_os:#C31, _architecture:#C5} + #C33 = ffi::Abi {_os:#C31, _architecture:#C10} + #C34 = ffi::Abi {_os:#C31, _architecture:#C18} + #C35 = "linux" + #C36 = ffi::_OS {index:#C16, _name:#C35} + #C37 = ffi::Abi {_os:#C36, _architecture:#C5} + #C38 = ffi::Abi {_os:#C36, _architecture:#C10} + #C39 = ffi::Abi {_os:#C36, _architecture:#C14} + #C40 = ffi::Abi {_os:#C36, _architecture:#C18} + #C41 = 4 + #C42 = "riscv32" + #C43 = ffi::_Architecture {index:#C41, _name:#C42} + #C44 = ffi::Abi {_os:#C36, _architecture:#C43} + #C45 = ffi::Abi {_os:#C36, _architecture:#C22} + #C46 = "macos" + #C47 = ffi::_OS {index:#C41, _name:#C46} + #C48 = ffi::Abi {_os:#C47, _architecture:#C10} + #C49 = ffi::Abi {_os:#C47, _architecture:#C18} + #C50 = "windows" + #C51 = ffi::_OS {index:#C20, _name:#C50} + #C52 = ffi::Abi {_os:#C51, _architecture:#C10} + #C53 = ffi::Uint16 {} + #C54 = ffi::Abi {_os:#C51, _architecture:#C14} + #C55 = ffi::Abi {_os:#C51, _architecture:#C18} + #C56 = {#C6:#C7, #C11:#C7, #C15:#C7, #C19:#C7, #C23:#C24, #C27:#C7, #C28:#C7, #C29:#C7, #C32:#C7, #C33:#C7, #C34:#C7, #C37:#C7, #C38:#C7, #C39:#C24, #C40:#C24, #C44:#C24, #C45:#C24, #C48:#C7, #C49:#C7, #C52:#C53, #C54:#C53, #C55:#C53} + #C57 = ffi::AbiSpecificIntegerMapping {mapping:#C56} + #C58 = "vm:ffi:abi-specific-mapping" + #C59 = TypeLiteralConstant(ffi::Uint32) + #C60 = TypeLiteralConstant(ffi::Int32) + #C61 = TypeLiteralConstant(ffi::Uint16) + #C62 = [#C59, #C59, #C59, #C59, #C60, #C59, #C59, #C59, #C59, #C59, #C59, #C59, #C59, #C60, #C60, #C60, #C60, #C59, #C59, #C61, #C61, #C61] + #C63 = ffi::_FfiAbiSpecificMapping {nativeTypes:#C62} + #C64 = core::pragma {name:#C58, options:#C63} + #C65 = "vm:prefer-inline" + #C66 = null + #C67 = core::pragma {name:#C65, options:#C66} + #C68 = [#C41, #C41, #C41, #C41, #C41, #C41, #C41, #C41, #C41, #C41, #C41, #C41, #C41, #C41, #C41, #C41, #C41, #C41, #C41, #C12, #C12, #C12] + #C69 = "vm:ffi:struct-fields" + #C70 = TypeLiteralConstant(self::WChar) + #C71 = [#C70, #C70] + #C72 = ffi::_FfiStructLayout {fieldTypes:#C71, packing:#C66} + #C73 = core::pragma {name:#C69, options:#C72} + #C74 = self::WChar {} + #C75 = [#C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1, #C1] + #C76 = 8 + #C77 = [#C76, #C76, #C76, #C76, #C76, #C76, #C76, #C76, #C76, #C76, #C76, #C76, #C76, #C76, #C76, #C76, #C76, #C76, #C76, #C41, #C41, #C41] + #C78 = 100 + #C79 = ffi::_FfiInlineArray {elementType:#C70, length:#C78} + #C80 = [#C79] + #C81 = ffi::_FfiStructLayout {fieldTypes:#C80, packing:#C66} + #C82 = core::pragma {name:#C69, options:#C81} + #C83 = ffi::_ArraySize {dimension1:#C78, dimension2:#C66, dimension3:#C66, dimension4:#C66, dimension5:#C66, dimensions:#C66} + #C84 = 400 + #C85 = 200 + #C86 = [#C84, #C84, #C84, #C84, #C84, #C84, #C84, #C84, #C84, #C84, #C84, #C84, #C84, #C84, #C84, #C84, #C84, #C84, #C84, #C85, #C85, #C85] + #C87 = [] + #C88 = core::_Override {} + #C89 = self::_DummyAllocator {} } diff --git a/pkg/vm/testcases/transformations/ffi/abi_specific_int_incomplete.dart.aot.expect b/pkg/vm/testcases/transformations/ffi/abi_specific_int_incomplete.dart.aot.expect index 1b424d67eab..fb0b814814f 100644 --- a/pkg/vm/testcases/transformations/ffi/abi_specific_int_incomplete.dart.aot.expect +++ b/pkg/vm/testcases/transformations/ffi/abi_specific_int_incomplete.dart.aot.expect @@ -94,22 +94,22 @@ constants { #C1 = "vm:ffi:abi-specific-mapping" #C2 = null #C3 = TypeLiteralConstant(ffi::Uint32) - #C4 = [#C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C3, #C3, #C3, #C3, #C2, #C2, #C2, #C2, #C2, #C2, #C2] + #C4 = [#C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C3, #C3, #C3, #C3, #C2, #C2, #C2, #C2, #C2, #C2, #C2] #C5 = ffi::_FfiAbiSpecificMapping {nativeTypes:#C4} #C6 = core::pragma {name:#C1, options:#C5} #C7 = "vm:prefer-inline" #C8 = core::pragma {name:#C7, options:#C2} #C9 = 4 - #C10 = [#C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C9, #C9, #C9, #C9, #C2, #C2, #C2, #C2, #C2, #C2, #C2] + #C10 = [#C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C9, #C9, #C9, #C9, #C2, #C2, #C2, #C2, #C2, #C2, #C2] #C11 = "vm:ffi:struct-fields" #C12 = TypeLiteralConstant(self::Incomplete) #C13 = [#C12, #C12] #C14 = ffi::_FfiStructLayout {fieldTypes:#C13, packing:#C2} #C15 = core::pragma {name:#C11, options:#C14} #C16 = 0 - #C17 = [#C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16] + #C17 = [#C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16, #C16] #C18 = 8 - #C19 = [#C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C18, #C18, #C18, #C18, #C2, #C2, #C2, #C2, #C2, #C2, #C2] + #C19 = [#C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C18, #C18, #C18, #C18, #C2, #C2, #C2, #C2, #C2, #C2, #C2] #C20 = 100 #C21 = ffi::_FfiInlineArray {elementType:#C12, length:#C20} #C22 = [#C21] @@ -117,6 +117,6 @@ constants { #C24 = core::pragma {name:#C11, options:#C23} #C25 = [] #C26 = 400 - #C27 = [#C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C26, #C26, #C26, #C26, #C2, #C2, #C2, #C2, #C2, #C2, #C2] + #C27 = [#C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C2, #C26, #C26, #C26, #C26, #C2, #C2, #C2, #C2, #C2, #C2, #C2] #C28 = self::_DummyAllocator {} } diff --git a/pkg/vm/testcases/transformations/ffi/abi_specific_int_incomplete.dart.expect b/pkg/vm/testcases/transformations/ffi/abi_specific_int_incomplete.dart.expect index 04e6c534ccf..ca0c6585534 100644 --- a/pkg/vm/testcases/transformations/ffi/abi_specific_int_incomplete.dart.expect +++ b/pkg/vm/testcases/transformations/ffi/abi_specific_int_incomplete.dart.expect @@ -143,22 +143,22 @@ constants { #C22 = "vm:ffi:abi-specific-mapping" #C23 = null #C24 = TypeLiteralConstant(ffi::Uint32) - #C25 = [#C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C24, #C24, #C24, #C24, #C23, #C23, #C23, #C23, #C23, #C23, #C23] + #C25 = [#C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C24, #C24, #C24, #C24, #C23, #C23, #C23, #C23, #C23, #C23, #C23] #C26 = ffi::_FfiAbiSpecificMapping {nativeTypes:#C25} #C27 = core::pragma {name:#C22, options:#C26} #C28 = "vm:prefer-inline" #C29 = core::pragma {name:#C28, options:#C23} #C30 = 4 - #C31 = [#C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C30, #C30, #C30, #C30, #C23, #C23, #C23, #C23, #C23, #C23, #C23] + #C31 = [#C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C30, #C30, #C30, #C30, #C23, #C23, #C23, #C23, #C23, #C23, #C23] #C32 = "vm:ffi:struct-fields" #C33 = TypeLiteralConstant(self::Incomplete) #C34 = [#C33, #C33] #C35 = ffi::_FfiStructLayout {fieldTypes:#C34, packing:#C23} #C36 = core::pragma {name:#C32, options:#C35} #C37 = self::Incomplete {} - #C38 = [#C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4] + #C38 = [#C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4, #C4] #C39 = 8 - #C40 = [#C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C39, #C39, #C39, #C39, #C23, #C23, #C23, #C23, #C23, #C23, #C23] + #C40 = [#C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C39, #C39, #C39, #C39, #C23, #C23, #C23, #C23, #C23, #C23, #C23] #C41 = 100 #C42 = ffi::_FfiInlineArray {elementType:#C33, length:#C41} #C43 = [#C42] @@ -166,7 +166,7 @@ constants { #C45 = core::pragma {name:#C32, options:#C44} #C46 = ffi::_ArraySize {dimension1:#C41, dimension2:#C23, dimension3:#C23, dimension4:#C23, dimension5:#C23, dimensions:#C23} #C47 = 400 - #C48 = [#C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C47, #C47, #C47, #C47, #C23, #C23, #C23, #C23, #C23, #C23, #C23] + #C48 = [#C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C23, #C47, #C47, #C47, #C47, #C23, #C23, #C23, #C23, #C23, #C23, #C23] #C49 = [] #C50 = core::_Override {} #C51 = self::_DummyAllocator {} diff --git a/pkg/vm/testcases/transformations/ffi/compound_copies.dart.expect b/pkg/vm/testcases/transformations/ffi/compound_copies.dart.expect index 23f5e4b1d43..3d5088fadfe 100644 --- a/pkg/vm/testcases/transformations/ffi/compound_copies.dart.expect +++ b/pkg/vm/testcases/transformations/ffi/compound_copies.dart.expect @@ -72,13 +72,13 @@ constants { #C6 = core::pragma {name:#C1, options:#C5} #C7 = ffi::Int64 {} #C8 = 0 - #C9 = [#C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8] + #C9 = [#C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8, #C8] #C10 = 8 - #C11 = [#C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10] + #C11 = [#C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10, #C10] #C12 = "vm:prefer-inline" #C13 = core::pragma {name:#C12, options:#C4} #C14 = 16 - #C15 = [#C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14] + #C15 = [#C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14, #C14] #C16 = TypeLiteralConstant(self::Coordinate) #C17 = [#C16, #C2] #C18 = ffi::_FfiStructLayout {fieldTypes:#C17, packing:#C4} diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/ffi_struct_constructors.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/ffi_struct_constructors.dart.expect index 7abb48cef8b..b9a6bf5ed22 100644 --- a/pkg/vm/testcases/transformations/type_flow/transformer/ffi_struct_constructors.dart.expect +++ b/pkg/vm/testcases/transformations/type_flow/transformer/ffi_struct_constructors.dart.expect @@ -128,10 +128,10 @@ constants { #C9 = ffi::_FfiStructLayout {fieldTypes:#C8, packing:#C4} #C10 = core::pragma {name:#C1, options:#C9} #C11 = 0 - #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] + #C12 = [#C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11, #C11] #C13 = 4 #C14 = 8 - #C15 = [#C13, #C14, #C13, #C14, #C14, #C14, #C14, #C13, #C14, #C14, #C13, #C14, #C13, #C14, #C13, #C14, #C14, #C14, #C14, #C13, #C14] + #C15 = [#C13, #C14, #C13, #C14, #C14, #C14, #C14, #C14, #C13, #C14, #C14, #C13, #C14, #C13, #C14, #C13, #C14, #C14, #C14, #C14, #C13, #C14] #C16 = static-tearoff self::useStruct3 #C17 = static-tearoff self::returnStruct7 #C18 = 1 diff --git a/runtime/tools/bin_to_assembly.py b/runtime/tools/bin_to_assembly.py index 3a9257a4ccd..cd1bdd9a28a 100755 --- a/runtime/tools/bin_to_assembly.py +++ b/runtime/tools/bin_to_assembly.py @@ -108,7 +108,7 @@ def Main(): is64bit = 0 if options.target_arch: - if options.target_arch in ["arm64", "x64"]: + if options.target_arch in ["arm64", "x64", "riscv64"]: is64bit = 1 if options.target_os in ["win"]: diff --git a/runtime/vm/compiler/ffi/abi.h b/runtime/vm/compiler/ffi/abi.h index f82e36ef5f1..ff917bf55d1 100644 --- a/runtime/vm/compiler/ffi/abi.h +++ b/runtime/vm/compiler/ffi/abi.h @@ -24,6 +24,7 @@ enum class Abi { kAndroidArm64, kAndroidIA32, kAndroidX64, + kAndroidRiscv64, kFuchsiaArm64, kFuchsiaX64, kFuchsiaRiscv64, @@ -50,9 +51,9 @@ const int64_t num_abis = static_cast(Abi::kWindowsX64) + 1; // - runtime/vm/compiler/frontend/kernel_to_il.cc static_assert(static_cast(Abi::kAndroidArm) == 0, "Enum value unexpected."); -static_assert(static_cast(Abi::kWindowsX64) == 20, +static_assert(static_cast(Abi::kWindowsX64) == 21, "Enum value unexpected."); -static_assert(num_abis == 21, "Enum value unexpected."); +static_assert(num_abis == 22, "Enum value unexpected."); // The target ABI. Defines sizes and alignment of native types. Abi TargetAbi(); diff --git a/runtime/vm/cpuinfo_android.cc b/runtime/vm/cpuinfo_android.cc index b68e74c2f3b..68e09a3f2a7 100644 --- a/runtime/vm/cpuinfo_android.cc +++ b/runtime/vm/cpuinfo_android.cc @@ -16,44 +16,63 @@ CpuInfoMethod CpuInfo::method_ = kCpuInfoDefault; const char* CpuInfo::fields_[kCpuInfoMax] = {}; void CpuInfo::Init() { - // Initialize our read from /proc/cpuinfo. - method_ = kCpuInfoSystem; - ProcCpuInfo::Init(); - #if defined(HOST_ARCH_IA32) || defined(HOST_ARCH_X64) fields_[kCpuInfoProcessor] = "vendor_id"; fields_[kCpuInfoModel] = "model name"; fields_[kCpuInfoHardware] = "model name"; fields_[kCpuInfoFeatures] = "flags"; fields_[kCpuInfoArchitecture] = "CPU architecture"; + method_ = kCpuInfoSystem; + ProcCpuInfo::Init(); #elif defined(HOST_ARCH_ARM) || defined(HOST_ARCH_ARM64) fields_[kCpuInfoProcessor] = "Processor"; fields_[kCpuInfoModel] = "model name"; fields_[kCpuInfoHardware] = "Hardware"; fields_[kCpuInfoFeatures] = "Features"; fields_[kCpuInfoArchitecture] = "CPU architecture"; + method_ = kCpuInfoSystem; + ProcCpuInfo::Init(); +#elif defined(HOST_ARCH_RISCV64) + // We only rely on the base Linux configuration of IMAFDC, so don't need + // dynamic feature detection. + method_ = kCpuInfoNone; #else #error Unrecognized target architecture #endif } void CpuInfo::Cleanup() { - ProcCpuInfo::Cleanup(); + if (method_ == kCpuInfoSystem) { + ProcCpuInfo::Cleanup(); + } else { + ASSERT(method_ == kCpuInfoNone); + } } bool CpuInfo::FieldContains(CpuInfoIndices idx, const char* search_string) { - ASSERT(method_ != kCpuInfoDefault); - return ProcCpuInfo::FieldContains(FieldName(idx), search_string); + if (method_ == kCpuInfoSystem) { + return ProcCpuInfo::FieldContains(FieldName(idx), search_string); + } else { + UNREACHABLE(); + } } const char* CpuInfo::ExtractField(CpuInfoIndices idx) { - ASSERT(method_ != kCpuInfoDefault); - return ProcCpuInfo::ExtractField(FieldName(idx)); + if (method_ == kCpuInfoSystem) { + return ProcCpuInfo::ExtractField(FieldName(idx)); + } else { + UNREACHABLE(); + } } bool CpuInfo::HasField(const char* field) { - ASSERT(method_ != kCpuInfoDefault); - return ProcCpuInfo::HasField(field); + if (method_ == kCpuInfoSystem) { + return ProcCpuInfo::HasField(field); + } else if (method_ == kCpuInfoNone) { + return false; + } else { + UNREACHABLE(); + } } } // namespace dart diff --git a/runtime/vm/os_android.cc b/runtime/vm/os_android.cc index 783ca0342b8..8431d012e08 100644 --- a/runtime/vm/os_android.cc +++ b/runtime/vm/os_android.cc @@ -180,7 +180,7 @@ int64_t OS::GetCurrentMonotonicMicrosForTimeline() { // into a architecture specific file e.g: os_ia32_linux.cc intptr_t OS::ActivationFrameAlignment() { #if defined(TARGET_ARCH_IA32) || defined(TARGET_ARCH_X64) || \ - defined(TARGET_ARCH_ARM64) + defined(TARGET_ARCH_ARM64) || defined(TARGET_ARCH_RISCV64) const int kMinimumAlignment = 16; #elif defined(TARGET_ARCH_ARM) const int kMinimumAlignment = 8; diff --git a/runtime/vm/signal_handler_android.cc b/runtime/vm/signal_handler_android.cc index 99787afc48b..02b7c4cf144 100644 --- a/runtime/vm/signal_handler_android.cc +++ b/runtime/vm/signal_handler_android.cc @@ -21,6 +21,8 @@ uintptr_t SignalHandler::GetProgramCounter(const mcontext_t& mcontext) { pc = static_cast(mcontext.arm_pc); #elif defined(HOST_ARCH_ARM64) pc = static_cast(mcontext.pc); +#elif defined(HOST_ARCH_RISCV64) + pc = static_cast(mcontext.__gregs[REG_PC]); #else #error Unsupported architecture. #endif // HOST_ARCH_... @@ -45,6 +47,8 @@ uintptr_t SignalHandler::GetFramePointer(const mcontext_t& mcontext) { } #elif defined(HOST_ARCH_ARM64) fp = static_cast(mcontext.regs[29]); +#elif defined(HOST_ARCH_RISCV64) + fp = static_cast(mcontext.__gregs[REG_S0]); #else #error Unsupported architecture. #endif // HOST_ARCH_... @@ -63,6 +67,8 @@ uintptr_t SignalHandler::GetCStackPointer(const mcontext_t& mcontext) { sp = static_cast(mcontext.arm_sp); #elif defined(HOST_ARCH_ARM64) sp = static_cast(mcontext.sp); +#elif defined(HOST_ARCH_RISCV64) + sp = static_cast(mcontext.__gregs[REG_SP]); #else #error Unsupported architecture. #endif // HOST_ARCH_... @@ -88,6 +94,8 @@ uintptr_t SignalHandler::GetLinkRegister(const mcontext_t& mcontext) { lr = static_cast(mcontext.arm_lr); #elif defined(HOST_ARCH_ARM64) lr = static_cast(mcontext.regs[30]); +#elif defined(HOST_ARCH_RISCV64) + lr = static_cast(mcontext.__gregs[REG_RA]); #else #error Unsupported architecture. #endif // HOST_ARCH_... diff --git a/sdk/lib/_internal/vm/lib/ffi_patch.dart b/sdk/lib/_internal/vm/lib/ffi_patch.dart index 5f362b132de..d6d3407dba8 100644 --- a/sdk/lib/_internal/vm/lib/ffi_patch.dart +++ b/sdk/lib/_internal/vm/lib/ffi_patch.dart @@ -27,6 +27,7 @@ int get _intPtrSize => (const [ 8, // androidArm64, 4, // androidIA32, 8, // androidX64, + 8, // androidRiscv64, 8, // fuchsiaArm64, 8, // fuchsiaX64, 8, // fuchsiaRiscv64, diff --git a/sdk/lib/ffi/abi.dart b/sdk/lib/ffi/abi.dart index 6931ca37905..8450a551d4a 100644 --- a/sdk/lib/ffi/abi.dart +++ b/sdk/lib/ffi/abi.dart @@ -25,9 +25,12 @@ class Abi { /// The application binary interface for Android on the IA32 architecture. static const androidIA32 = _androidIA32; - /// The application binary interface for android on the X64 architecture. + /// The application binary interface for Android on the X64 architecture. static const androidX64 = _androidX64; + /// The application binary interface for Android on 64-bit RISC-V. + static const androidRiscv64 = _androidRiscv64; + /// The application binary interface for Fuchsia on the Arm64 architecture. static const fuchsiaArm64 = _fuchsiaArm64; @@ -90,6 +93,7 @@ class Abi { androidArm64, androidIA32, androidX64, + androidRiscv64, fuchsiaArm64, fuchsiaX64, fuchsiaRiscv64, @@ -133,6 +137,7 @@ class Abi { static const _androidArm64 = Abi._(_Architecture.arm64, _OS.android); static const _androidIA32 = Abi._(_Architecture.ia32, _OS.android); static const _androidX64 = Abi._(_Architecture.x64, _OS.android); + static const _androidRiscv64 = Abi._(_Architecture.riscv64, _OS.android); static const _fuchsiaArm64 = Abi._(_Architecture.arm64, _OS.fuchsia); static const _fuchsiaX64 = Abi._(_Architecture.x64, _OS.fuchsia); static const _fuchsiaRiscv64 = Abi._(_Architecture.riscv64, _OS.fuchsia); diff --git a/sdk/lib/ffi/abi_specific.dart b/sdk/lib/ffi/abi_specific.dart index 1e40395af9f..6ef8ab5f271 100644 --- a/sdk/lib/ffi/abi_specific.dart +++ b/sdk/lib/ffi/abi_specific.dart @@ -24,6 +24,7 @@ part of dart.ffi; /// Abi.androidArm64: Uint64(), /// Abi.androidIA32: Uint32(), /// Abi.androidX64: Uint64(), +/// Abi.androidRiscv64: Uint64(), /// Abi.fuchsiaArm64: Uint64(), /// Abi.fuchsiaX64: Uint64(), /// Abi.fuchsiaRiscv64: Uint64(), diff --git a/sdk/lib/ffi/c_type.dart b/sdk/lib/ffi/c_type.dart index 67c128e0468..dc31bc985c7 100644 --- a/sdk/lib/ffi/c_type.dart +++ b/sdk/lib/ffi/c_type.dart @@ -27,6 +27,7 @@ part of dart.ffi; Abi.androidArm64: Uint8(), Abi.androidIA32: Int8(), Abi.androidX64: Int8(), + Abi.androidRiscv64: Uint8(), Abi.fuchsiaArm64: Uint8(), Abi.fuchsiaX64: Int8(), Abi.fuchsiaRiscv64: Uint8(), @@ -65,6 +66,7 @@ final class Char extends AbiSpecificInteger { Abi.androidArm64: Int8(), Abi.androidIA32: Int8(), Abi.androidX64: Int8(), + Abi.androidRiscv64: Int8(), Abi.fuchsiaArm64: Int8(), Abi.fuchsiaX64: Int8(), Abi.fuchsiaRiscv64: Int8(), @@ -103,6 +105,7 @@ final class SignedChar extends AbiSpecificInteger { Abi.androidArm64: Uint8(), Abi.androidIA32: Uint8(), Abi.androidX64: Uint8(), + Abi.androidRiscv64: Uint8(), Abi.fuchsiaArm64: Uint8(), Abi.fuchsiaX64: Uint8(), Abi.fuchsiaRiscv64: Uint8(), @@ -141,6 +144,7 @@ final class UnsignedChar extends AbiSpecificInteger { Abi.androidArm64: Int16(), Abi.androidIA32: Int16(), Abi.androidX64: Int16(), + Abi.androidRiscv64: Int16(), Abi.fuchsiaArm64: Int16(), Abi.fuchsiaX64: Int16(), Abi.fuchsiaRiscv64: Int16(), @@ -179,6 +183,7 @@ final class Short extends AbiSpecificInteger { Abi.androidArm64: Uint16(), Abi.androidIA32: Uint16(), Abi.androidX64: Uint16(), + Abi.androidRiscv64: Uint16(), Abi.fuchsiaArm64: Uint16(), Abi.fuchsiaX64: Uint16(), Abi.fuchsiaRiscv64: Uint16(), @@ -217,6 +222,7 @@ final class UnsignedShort extends AbiSpecificInteger { Abi.androidArm64: Int32(), Abi.androidIA32: Int32(), Abi.androidX64: Int32(), + Abi.androidRiscv64: Int32(), Abi.fuchsiaArm64: Int32(), Abi.fuchsiaX64: Int32(), Abi.fuchsiaRiscv64: Int32(), @@ -255,6 +261,7 @@ final class Int extends AbiSpecificInteger { Abi.androidArm64: Uint32(), Abi.androidIA32: Uint32(), Abi.androidX64: Uint32(), + Abi.androidRiscv64: Uint32(), Abi.fuchsiaArm64: Uint32(), Abi.fuchsiaX64: Uint32(), Abi.fuchsiaRiscv64: Uint32(), @@ -294,6 +301,7 @@ final class UnsignedInt extends AbiSpecificInteger { Abi.androidArm64: Int64(), Abi.androidIA32: Int32(), Abi.androidX64: Int64(), + Abi.androidRiscv64: Int64(), Abi.fuchsiaArm64: Int64(), Abi.fuchsiaX64: Int64(), Abi.fuchsiaRiscv64: Int64(), @@ -333,6 +341,7 @@ final class Long extends AbiSpecificInteger { Abi.androidArm64: Uint64(), Abi.androidIA32: Uint32(), Abi.androidX64: Uint64(), + Abi.androidRiscv64: Uint64(), Abi.fuchsiaArm64: Uint64(), Abi.fuchsiaX64: Uint64(), Abi.fuchsiaRiscv64: Uint64(), @@ -371,6 +380,7 @@ final class UnsignedLong extends AbiSpecificInteger { Abi.androidArm64: Int64(), Abi.androidIA32: Int64(), Abi.androidX64: Int64(), + Abi.androidRiscv64: Int64(), Abi.fuchsiaArm64: Int64(), Abi.fuchsiaX64: Int64(), Abi.fuchsiaRiscv64: Int64(), @@ -409,6 +419,7 @@ final class LongLong extends AbiSpecificInteger { Abi.androidArm64: Uint64(), Abi.androidIA32: Uint64(), Abi.androidX64: Uint64(), + Abi.androidRiscv64: Uint64(), Abi.fuchsiaArm64: Uint64(), Abi.fuchsiaX64: Uint64(), Abi.fuchsiaRiscv64: Uint64(), @@ -442,6 +453,7 @@ final class UnsignedLongLong extends AbiSpecificInteger { Abi.androidArm64: Int64(), Abi.androidIA32: Int32(), Abi.androidX64: Int64(), + Abi.androidRiscv64: Int64(), Abi.fuchsiaArm64: Int64(), Abi.fuchsiaX64: Int64(), Abi.fuchsiaRiscv64: Int64(), @@ -476,6 +488,7 @@ final class IntPtr extends AbiSpecificInteger { Abi.androidArm64: Uint64(), Abi.androidIA32: Uint32(), Abi.androidX64: Uint64(), + Abi.androidRiscv64: Uint64(), Abi.fuchsiaArm64: Uint64(), Abi.fuchsiaX64: Uint64(), Abi.fuchsiaRiscv64: Uint64(), @@ -510,6 +523,7 @@ final class UintPtr extends AbiSpecificInteger { Abi.androidArm64: Uint64(), Abi.androidIA32: Uint32(), Abi.androidX64: Uint64(), + Abi.androidRiscv64: Uint64(), Abi.fuchsiaArm64: Uint64(), Abi.fuchsiaX64: Uint64(), Abi.fuchsiaRiscv64: Uint64(), @@ -547,6 +561,7 @@ final class Size extends AbiSpecificInteger { Abi.androidArm64: Uint32(), Abi.androidIA32: Uint32(), Abi.androidX64: Uint32(), + Abi.androidRiscv64: Int32(), Abi.fuchsiaArm64: Uint32(), Abi.fuchsiaX64: Int32(), Abi.fuchsiaRiscv64: Int32(),