dart-sdk/benchmarks
Daco Harkes 85a87ca7ae [vm/ffi] Add common C types
We're adding these types to `dart:ffi` rather than `package:ffi` so that
they can be used with `FfiNative`s.

Adds `NativeType`s for the following C types:

* char
* unsigned char
* signed char
* short
* unsigned short
* int
* unsigned int
* long
* unsigned long
* long long
* unsigned long long
* uintptr_t
* size_t
* wchar_t

Because the C standard only defines minimum sizes for many of these
types, future platforms might diverge from the typical size even if all
platforms currently agree on a size. To avoid having to reification
later, we define all types as AbiSpecificIntegers rather than typedefs,
even if all current target platforms agree on the size.

Closes: https://github.com/dart-lang/sdk/issues/36140

TEST=tests/ffi/c_types_test.dart

Change-Id: Ie97d253856d787386529231e8060f879069be886
Cq-Include-Trybots: luci.dart.try:dart-sdk-linux-try,dart-sdk-mac-try,dart-sdk-win-try,vm-ffi-android-debug-arm64c-try,vm-ffi-android-debug-arm-try,vm-canary-linux-debug-try,vm-fuchsia-release-x64-try,vm-kernel-gcc-linux-try,vm-kernel-asan-linux-release-x64-try,vm-kernel-linux-debug-x64-try,vm-kernel-linux-debug-ia32-try,vm-kernel-mac-debug-x64-try,vm-kernel-mac-release-arm64-try,vm-kernel-nnbd-win-release-ia32-try,vm-kernel-nnbd-win-release-x64-try,vm-precomp-ffi-qemu-linux-release-arm-try,vm-kernel-win-release-x64-try
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/228541
Reviewed-by: Martin Kustermann <kustermann@google.com>
2022-01-20 14:41:46 +00:00
..
BigIntParsePrint [benchmark] BigIntParsePrint: fix lints 2021-01-11 17:42:06 +00:00
Calls [benchmarks/vm] Add benchmarks for #45908 2021-05-27 07:54:14 +00:00
DartCLIStartup [ Benchmarks ] Add benchmarks for SDK snapshot sizes and Dart CLI 2021-05-25 17:52:41 +00:00
Dynamic [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
EventLoopLatencyJson [vm] Change EventLoopLatency benchmark to use RunTimeRaw latency 2020-10-23 18:31:01 +00:00
EventLoopLatencyJson350KB [vm/concurrency] Add EventLoopLatencyJson350KB bechmark 2020-10-28 16:28:38 +00:00
EventLoopLatencyRegexp [benchmark] Fix import statement in dart2/EventLoopLatencyRegexp benchmark. 2021-08-24 15:54:14 +00:00
Example [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
FfiAsTypedList [vm/ffi] Optimize Pointer<T>.asTypedList() 2021-11-29 17:38:04 +00:00
FfiBoringssl Reland "[vm/ffi] Roll package:ffi to Allocator and Opaque" 2021-02-10 10:19:28 +00:00
FfiCall [VM/FFI] Adds FFI leaf calls. 2021-05-21 11:12:02 +00:00
FfiMemory [vm/ffi] Add common C types 2022-01-20 14:41:46 +00:00
FfiStruct Reland "[vm/ffi] Roll package:ffi to Allocator and Opaque" 2021-02-10 10:19:28 +00:00
Isolate [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
IsolateFibonacci [vm/concurrency] Remove --(no-)enable-isolate-groups flag usage in tests 2021-11-04 18:57:21 +00:00
IsolateJson [vm/sendandexit] Introduce Isolate.exit([port, message]). 2021-09-30 20:20:24 +00:00
IsolateSpawn [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
IsolateSpawnMemory [vm/concurrency] Remove --(no-)enable-isolate-groups flag usage in tests 2021-11-04 18:57:21 +00:00
ListCopy [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
MapCopy [benchmark] Add MapCopy benchmark 2022-01-06 03:32:34 +00:00
MapLookup [benchmarks/vm] Add benchmarks for #45908 2021-05-27 07:54:14 +00:00
MD5 [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
NativeCall [benchmark] Adds native call benchmark. 2021-11-04 15:16:24 +00:00
ObjectHash Add benchmark for Object.hash 2021-06-30 21:06:34 +00:00
Omnibus [benchmarks] Fix lints in Omnibus benchmarks 2021-04-23 20:11:52 +00:00
OmnibusDeferred [benchmarks] Fix lints in Omnibus benchmarks 2021-04-23 20:11:52 +00:00
Richards [benchmarks] Move Richards from internal benchmarks to SDK benchmarks 2021-04-15 22:29:07 +00:00
RuntimeType [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
SDKArtifactSizes Remove dartfmt from SDK artifact size benchmark. 2021-10-01 15:45:53 +00:00
SendPort [vm] Prevent tree shaking of fields in SendPort benchmark 2021-07-16 04:39:37 +00:00
SHA1 [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
SHA256 [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
SkeletalAnimation [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
SkeletalAnimationSIMD [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
SoundSplayTreeSieve [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
StringPool [benchmarks] Add benchmark to measure dart2js string pool cost 2021-06-03 03:11:44 +00:00
TypedDataDuplicate [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
Utf8Decode [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
Utf8Encode [benchmark] Add language version comments to benchmarks. 2020-10-13 01:43:22 +00:00
analysis_options.yaml