-
Notifications
You must be signed in to change notification settings - Fork 122
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add benchmark for some dart:ffi code that was slow in the old formatter.
In the new formatter, it's about 3000x faster. Fix #1066.
- Loading branch information
1 parent
8a8e4f5
commit fc134cd
Showing
3 changed files
with
255 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
final passInt32x8Doublex8Int64Int8Struct1ByteIntInt64IntLeaf = ffiTestFunctions | ||
.lookupFunction< | ||
Double Function( | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Int64, | ||
Int8, | ||
Struct1ByteInt, | ||
Int64, | ||
Int8, | ||
Struct4BytesHomogeneousInt16, | ||
Int64, | ||
Int8, | ||
Struct8BytesInt, | ||
Int64, | ||
Int8, | ||
Struct8BytesHomogeneousFloat, | ||
Int64, | ||
Int8, | ||
Struct8BytesMixed, | ||
Int64, | ||
Int8, | ||
StructAlignmentInt16, | ||
Int64, | ||
Int8, | ||
StructAlignmentInt32, | ||
Int64, | ||
Int8, | ||
StructAlignmentInt64, | ||
), | ||
double Function( | ||
int, | ||
int, | ||
int, | ||
int, | ||
int, | ||
int, | ||
int, | ||
int, | ||
double, | ||
double, | ||
double, | ||
double, | ||
double, | ||
double, | ||
double, | ||
double, | ||
int, | ||
int, | ||
Struct1ByteInt, | ||
int, | ||
int, | ||
Struct4BytesHomogeneousInt16, | ||
int, | ||
int, | ||
Struct8BytesInt, | ||
int, | ||
int, | ||
Struct8BytesHomogeneousFloat, | ||
int, | ||
int, | ||
Struct8BytesMixed, | ||
int, | ||
int, | ||
StructAlignmentInt16, | ||
int, | ||
int, | ||
StructAlignmentInt32, | ||
int, | ||
int, | ||
StructAlignmentInt64, | ||
) | ||
>("PassInt32x8Doublex8Int64Int8Struct1ByteIntInt64Int", isLeaf: true); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
final passInt32x8Doublex8Int64Int8Struct1ByteIntInt64IntLeaf = | ||
ffiTestFunctions.lookupFunction< | ||
Double Function( | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Int64, | ||
Int8, | ||
Struct1ByteInt, | ||
Int64, | ||
Int8, | ||
Struct4BytesHomogeneousInt16, | ||
Int64, | ||
Int8, | ||
Struct8BytesInt, | ||
Int64, | ||
Int8, | ||
Struct8BytesHomogeneousFloat, | ||
Int64, | ||
Int8, | ||
Struct8BytesMixed, | ||
Int64, | ||
Int8, | ||
StructAlignmentInt16, | ||
Int64, | ||
Int8, | ||
StructAlignmentInt32, | ||
Int64, | ||
Int8, | ||
StructAlignmentInt64), | ||
double Function( | ||
int, | ||
int, | ||
int, | ||
int, | ||
int, | ||
int, | ||
int, | ||
int, | ||
double, | ||
double, | ||
double, | ||
double, | ||
double, | ||
double, | ||
double, | ||
double, | ||
int, | ||
int, | ||
Struct1ByteInt, | ||
int, | ||
int, | ||
Struct4BytesHomogeneousInt16, | ||
int, | ||
int, | ||
Struct8BytesInt, | ||
int, | ||
int, | ||
Struct8BytesHomogeneousFloat, | ||
int, | ||
int, | ||
Struct8BytesMixed, | ||
int, | ||
int, | ||
StructAlignmentInt16, | ||
int, | ||
int, | ||
StructAlignmentInt32, | ||
int, | ||
int, | ||
StructAlignmentInt64)>("PassInt32x8Doublex8Int64Int8Struct1ByteIntInt64Int", isLeaf: true); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
final passInt32x8Doublex8Int64Int8Struct1ByteIntInt64IntLeaf = | ||
ffiTestFunctions.lookupFunction< | ||
Double Function( | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Int32, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Double, | ||
Int64, | ||
Int8, | ||
Struct1ByteInt, | ||
Int64, | ||
Int8, | ||
Struct4BytesHomogeneousInt16, | ||
Int64, | ||
Int8, | ||
Struct8BytesInt, | ||
Int64, | ||
Int8, | ||
Struct8BytesHomogeneousFloat, | ||
Int64, | ||
Int8, | ||
Struct8BytesMixed, | ||
Int64, | ||
Int8, | ||
StructAlignmentInt16, | ||
Int64, | ||
Int8, | ||
StructAlignmentInt32, | ||
Int64, | ||
Int8, | ||
StructAlignmentInt64), | ||
double Function( | ||
int, | ||
int, | ||
int, | ||
int, | ||
int, | ||
int, | ||
int, | ||
int, | ||
double, | ||
double, | ||
double, | ||
double, | ||
double, | ||
double, | ||
double, | ||
double, | ||
int, | ||
int, | ||
Struct1ByteInt, | ||
int, | ||
int, | ||
Struct4BytesHomogeneousInt16, | ||
int, | ||
int, | ||
Struct8BytesInt, | ||
int, | ||
int, | ||
Struct8BytesHomogeneousFloat, | ||
int, | ||
int, | ||
Struct8BytesMixed, | ||
int, | ||
int, | ||
StructAlignmentInt16, | ||
int, | ||
int, | ||
StructAlignmentInt32, | ||
int, | ||
int, | ||
StructAlignmentInt64)>("PassInt32x8Doublex8Int64Int8Struct1ByteIntInt64Int", isLeaf: true); |