Skip to content

Instantly share code, notes, and snippets.

@ngoldbaum
Created April 30, 2024 13:50
Show Gist options
  • Save ngoldbaum/3f4fb703eeeb44185c08ac15e2e44b45 to your computer and use it in GitHub Desktop.
Save ngoldbaum/3f4fb703eeeb44185c08ac15e2e44b45 to your computer and use it in GitHub Desktop.
| Change | Before [12aa98e0] <main> | After [080755f2] <nogil-ufunc-caches> | Ratio | Benchmark (Parameter) |
|----------|----------------------------|-----------------------------------------|---------|----------------------------------------------------------------------------------------------------------------|
| + | 634±4ns | 793±100ns | 1.25 | bench_ufunc.ArgParsingReduce.time_add_reduce_arg_parsing((array([0., 1.]), 0)) |
| + | 265±5ns | 315±6ns | 1.19 | bench_ufunc.Scalar.time_add_scalar |
| + | 344±3ns | 408±30ns | 1.18 | bench_ufunc.MethodsV1IntOnly.time_ndarray_meth('__or__', 'int64') |
| + | 241±3ns | 283±2ns | 1.17 | bench_ufunc.Custom.time_and_bool_small |
| + | 222±3ns | 257±3ns | 1.16 | bench_ufunc.UFuncSmall.time_ufunc_small_array_inplace('sqrt') |
| + | 340±6ns | 392±4ns | 1.15 | bench_ufunc.MethodsV1.time_ndarray_meth('__add__', 'int16') |
| + | 341±2ns | 393±8ns | 1.15 | bench_ufunc.MethodsV1.time_ndarray_meth('__eq__', 'int64') |
| + | 329±5ns | 378±4ns | 1.15 | bench_ufunc.MethodsV1.time_ndarray_meth('__sub__', 'int16') |
| + | 341±4ns | 394±6ns | 1.15 | bench_ufunc.MethodsV1IntOnly.time_ndarray_meth('__and__', 'int64') |
| + | 378±5ns | 435±7ns | 1.15 | bench_ufunc.Scalar.time_add_scalar_conv |
| + | 231±3ns | 265±2ns | 1.15 | bench_ufunc.UFuncSmall.time_ufunc_small_array_inplace('cos') |
| + | 372±2ns | 423±10ns | 1.14 | bench_ufunc.ArgParsing.time_add_arg_parsing((array(1.), array(2.), out=array(3.), subok=True, where=True)) |
| + | 685±6ns | 778±80ns | 1.14 | bench_ufunc.ArgParsingReduce.time_add_reduce_arg_parsing((array([0., 1.]), axis=0)) |
| + | 341±4ns | 387±3ns | 1.14 | bench_ufunc.MethodsV1.time_ndarray_meth('__gt__', 'int32') |
| + | 331±5ns | 378±9ns | 1.14 | bench_ufunc.MethodsV1.time_ndarray_meth('__mul__', 'int16') |
| + | 359±2ns | 409±2ns | 1.14 | bench_ufunc.MethodsV1.time_ndarray_meth('__ne__', 'float64') |
| + | 337±5ns | 386±9ns | 1.14 | bench_ufunc.MethodsV1.time_ndarray_meth('__ne__', 'int64') |
| + | 383±7ns | 436±7ns | 1.14 | bench_ufunc.MethodsV1.time_ndarray_meth('__sub__', 'complex128') |
| + | 351±2ns | 401±3ns | 1.14 | bench_ufunc.UFuncSmall.time_ufunc_python_float('cos') |
| + | 247±3ns | 281±3ns | 1.14 | bench_ufunc.UFuncSmall.time_ufunc_small_int_array('abs') |
| + | 343±5ns | 389±9ns | 1.13 | bench_ufunc.ArgParsing.time_add_arg_parsing((array(1.), array(2.))) |
| + | 327±5ns | 370±4ns | 1.13 | bench_ufunc.ArgParsing.time_add_arg_parsing((array(1.), array(2.), out=(array(3.),))) |
| + | 328±2ns | 372±6ns | 1.13 | bench_ufunc.CustomArrayFloorDivideInt.time_floor_divide_int(<class 'numpy.uint8'>, 100) |
| + | 292±3ns | 328±2ns | 1.13 | bench_ufunc.MethodsV0.time_ndarray_meth('__abs__', 'float32') |
| + | 293±1ns | 330±2ns | 1.13 | bench_ufunc.MethodsV0.time_ndarray_meth('__neg__', 'float64') |
| + | 291±2ns | 329±3ns | 1.13 | bench_ufunc.MethodsV0.time_ndarray_meth('__neg__', 'int64') |
| + | 339±2ns | 382±3ns | 1.13 | bench_ufunc.MethodsV1.time_ndarray_meth('__eq__', 'int16') |
| + | 359±4ns | 406±8ns | 1.13 | bench_ufunc.MethodsV1.time_ndarray_meth('__ge__', 'float64') |
| + | 342±6ns | 388±3ns | 1.13 | bench_ufunc.MethodsV1.time_ndarray_meth('__ge__', 'int64') |
| + | 362±6ns | 411±7ns | 1.13 | bench_ufunc.MethodsV1.time_ndarray_meth('__gt__', 'float32') |
| + | 348±4ns | 392±3ns | 1.13 | bench_ufunc.MethodsV1.time_ndarray_meth('__lt__', 'int32') |
| + | 353±4ns | 398±3ns | 1.13 | bench_ufunc.MethodsV1.time_ndarray_meth('__mul__', 'float64') |
| + | 364±6ns | 410±3ns | 1.13 | bench_ufunc.MethodsV1.time_ndarray_meth('__mul__', 'int64') |
| + | 368±4ns | 415±6ns | 1.13 | bench_ufunc.MethodsV1.time_ndarray_meth('__ne__', 'complex128') |
| + | 350±5ns | 395±7ns | 1.13 | bench_ufunc.MethodsV1.time_ndarray_meth('__sub__', 'float64') |
| + | 341±2ns | 386±3ns | 1.13 | bench_ufunc.MethodsV1.time_ndarray_meth('__sub__', 'int64') |
| + | 338±3ns | 381±4ns | 1.13 | bench_ufunc.MethodsV1.time_ndarray_meth('__truediv__', 'float64') |
| + | 337±3ns | 381±4ns | 1.13 | bench_ufunc.MethodsV1IntOnly.time_ndarray_meth('__or__', 'int32') |
| + | 335±3ns | 377±3ns | 1.13 | bench_ufunc.MethodsV1IntOnly.time_ndarray_meth('__xor__', 'int16') |
| + | 406±3ns | 459±10ns | 1.13 | bench_ufunc.Scalar.time_add_scalar_conv_complex |
| + | 259±3ns | 294±4ns | 1.13 | bench_ufunc.UFuncSmall.time_ufunc_small_array('cos') |
| + | 404±5ns | 454±10ns | 1.12 | bench_ufunc.ArgParsing.time_add_arg_parsing((array(1.), array(2.), subok=True)) |
| + | 332±3ns | 372±6ns | 1.12 | bench_ufunc.CustomArrayFloorDivideInt.time_floor_divide_int(<class 'numpy.uint64'>, 100) |
| + | 291±3ns | 325±4ns | 1.12 | bench_ufunc.MethodsV0.time_ndarray_meth('__abs__', 'float16') |
| + | 298±3ns | 333±4ns | 1.12 | bench_ufunc.MethodsV0.time_ndarray_meth('__abs__', 'float64') |
| + | 285±4ns | 319±3ns | 1.12 | bench_ufunc.MethodsV0.time_ndarray_meth('__abs__', 'int32') |
| + | 352±6ns | 394±4ns | 1.12 | bench_ufunc.MethodsV1.time_ndarray_meth('__add__', 'float64') |
| + | 374±1ns | 421±6ns | 1.12 | bench_ufunc.MethodsV1.time_ndarray_meth('__eq__', 'complex128') |
| + | 430±3ns | 483±5ns | 1.12 | bench_ufunc.MethodsV1.time_ndarray_meth('__ge__', 'complex128') |
| + | 346±5ns | 385±4ns | 1.12 | bench_ufunc.MethodsV1.time_ndarray_meth('__ge__', 'int16') |
| + | 362±4ns | 404±2ns | 1.12 | bench_ufunc.MethodsV1.time_ndarray_meth('__gt__', 'float64') |
| + | 350±1ns | 391±2ns | 1.12 | bench_ufunc.MethodsV1.time_ndarray_meth('__gt__', 'int64') |
| + | 368±3ns | 412±4ns | 1.12 | bench_ufunc.MethodsV1.time_ndarray_meth('__le__', 'float32') |
| + | 339±6ns | 379±5ns | 1.12 | bench_ufunc.MethodsV1.time_ndarray_meth('__le__', 'int32') |
| + | 342±3ns | 383±4ns | 1.12 | bench_ufunc.MethodsV1.time_ndarray_meth('__le__', 'int64') |
| + | 372±4ns | 416±3ns | 1.12 | bench_ufunc.MethodsV1.time_ndarray_meth('__ne__', 'complex64') |
| + | 335±5ns | 376±3ns | 1.12 | bench_ufunc.MethodsV1.time_ndarray_meth('__sub__', 'int32') |
| + | 341±5ns | 381±4ns | 1.12 | bench_ufunc.MethodsV1IntOnly.time_ndarray_meth('__or__', 'int16') |
| + | 248±3ns | 277±4ns | 1.12 | bench_ufunc.UFuncSmall.time_ufunc_small_array('sqrt') |
| + | 366±6ns | 406±4ns | 1.11 | bench_ufunc.ArgParsing.time_add_arg_parsing((array(1.), array(2.), array(3.), subok=True, where=True)) |
| + | 335±2ns | 373±6ns | 1.11 | bench_ufunc.CustomArrayFloorDivideInt.time_floor_divide_int(<class 'numpy.uint32'>, 100) |
| + | 1.21±0.01μs | 1.34±0.1μs | 1.11 | bench_ufunc.CustomScalarFloorDivideInt.time_floor_divide_int(<class 'numpy.int8'>, -43) |
| + | 287±3ns | 319±5ns | 1.11 | bench_ufunc.MethodsV0.time_ndarray_meth('__abs__', 'int16') |
| + | 293±5ns | 324±3ns | 1.11 | bench_ufunc.MethodsV0.time_ndarray_meth('__abs__', 'int64') |
| + | 294±3ns | 325±3ns | 1.11 | bench_ufunc.MethodsV0.time_ndarray_meth('__neg__', 'float32') |
| + | 286±3ns | 317±4ns | 1.11 | bench_ufunc.MethodsV0.time_ndarray_meth('__neg__', 'int16') |
| + | 288±2ns | 319±7ns | 1.11 | bench_ufunc.MethodsV0.time_ndarray_meth('__neg__', 'int32') |
| + | 286±3ns | 318±2ns | 1.11 | bench_ufunc.MethodsV0.time_ndarray_meth('__pos__', 'int16') |
| + | 387±4ns | 428±4ns | 1.11 | bench_ufunc.MethodsV1.time_ndarray_meth('__add__', 'complex128') |
| + | 346±2ns | 382±3ns | 1.11 | bench_ufunc.MethodsV1.time_ndarray_meth('__add__', 'float32') |
| + | 350±3ns | 387±1ns | 1.11 | bench_ufunc.MethodsV1.time_ndarray_meth('__add__', 'int64') |
| + | 361±4ns | 400±2ns | 1.11 | bench_ufunc.MethodsV1.time_ndarray_meth('__eq__', 'float64') |
| + | 339±4ns | 377±9ns | 1.11 | bench_ufunc.MethodsV1.time_ndarray_meth('__eq__', 'int32') |
| + | 341±4ns | 380±6ns | 1.11 | bench_ufunc.MethodsV1.time_ndarray_meth('__ge__', 'int32') |
| + | 431±4ns | 477±6ns | 1.11 | bench_ufunc.MethodsV1.time_ndarray_meth('__gt__', 'complex64') |
| + | 362±5ns | 400±1ns | 1.11 | bench_ufunc.MethodsV1.time_ndarray_meth('__le__', 'float64') |
| + | 343±2ns | 380±2ns | 1.11 | bench_ufunc.MethodsV1.time_ndarray_meth('__le__', 'int16') |
| + | 352±3ns | 391±3ns | 1.11 | bench_ufunc.MethodsV1.time_ndarray_meth('__sub__', 'complex64') |
| + | 343±6ns | 381±3ns | 1.11 | bench_ufunc.MethodsV1.time_ndarray_meth('__sub__', 'float32') |
| + | 340±2ns | 378±6ns | 1.11 | bench_ufunc.MethodsV1IntOnly.time_ndarray_meth('__and__', 'int32') |
| + | 345±3ns | 381±2ns | 1.11 | bench_ufunc.MethodsV1IntOnly.time_ndarray_meth('__xor__', 'int32') |
| + | 350±2ns | 387±3ns | 1.11 | bench_ufunc.MethodsV1IntOnly.time_ndarray_meth('__xor__', 'int64') |
| + | 233±4ns | 259±3ns | 1.11 | bench_ufunc.UFuncSmall.time_ufunc_small_array_inplace('abs') |
| + | 383±4ns | 426±4ns | 1.11 | bench_ufunc.UFuncSmall.time_ufunc_small_int_array('cos') |
| + | 335±2ns | 367±3ns | 1.1 | bench_ufunc.CustomArrayFloorDivideInt.time_floor_divide_int(<class 'numpy.uint16'>, 100) |
| + | 290±4ns | 320±6ns | 1.1 | bench_ufunc.Methods0DInvert.time_ndarray__0d__('int64') |
| + | 316±2ns | 348±5ns | 1.1 | bench_ufunc.MethodsV0.time_ndarray_meth('__pos__', 'float64') |
| + | 356±5ns | 393±3ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__add__', 'complex64') |
| + | 369±2ns | 406±6ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__eq__', 'float32') |
| + | 373±3ns | 412±4ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__ge__', 'float32') |
| + | 472±1ns | 519±7ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__gt__', 'float16') |
| + | 405±3ns | 446±5ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__le__', 'complex64') |
| + | 370±2ns | 409±8ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__lt__', 'float32') |
| + | 368±6ns | 407±5ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__lt__', 'float64') |
| + | 340±2ns | 373±9ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__lt__', 'int16') |
| + | 346±3ns | 380±3ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__lt__', 'int64') |
| + | 578±4ns | 638±10ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__matmul__', 'int32') |
| + | 392±6ns | 431±2ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__mul__', 'complex128') |
| + | 343±4ns | 378±7ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__mul__', 'float32') |
| + | 456±2ns | 502±2ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__ne__', 'float16') |
| + | 428±5ns | 470±4ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__truediv__', 'complex64') |
| + | 335±4ns | 369±4ns | 1.1 | bench_ufunc.MethodsV1.time_ndarray_meth('__truediv__', 'float32') |
| + | 416±7ns | 458±7ns | 1.1 | bench_ufunc.MethodsV1NoComplex.time_ndarray_meth('__floordiv__', 'int16') |
| + | 426±2ns | 469±3ns | 1.1 | bench_ufunc.MethodsV1NoComplex.time_ndarray_meth('__mod__', 'int32') |
| + | 428±3ns | 470±4ns | 1.1 | bench_ufunc.MethodsV1NoComplex.time_ndarray_meth('__mod__', 'int64') |
| + | 367±6ns | 403±4ns | 1.1 | bench_ufunc.UFuncSmall.time_ufunc_numpy_scalar('sqrt') |
| + | 366±4ns | 402±3ns | 1.1 | bench_ufunc.UFuncSmall.time_ufunc_python_float('abs') |
| + | 377±6ns | 415±2ns | 1.1 | bench_ufunc.UFuncSmall.time_ufunc_small_int_array('sqrt') |
| + | 640±10ns | 699±6ns | 1.09 | bench_ufunc.ArgParsingReduce.time_add_reduce_arg_parsing((array([0., 1.]), axis=0, dtype=None, out=array(0.))) |
| + | 388±8ns | 421±2ns | 1.09 | bench_ufunc.CustomArrayFloorDivideInt.time_floor_divide_int(<class 'numpy.int16'>, 100) |
| + | 291±1ns | 318±4ns | 1.09 | bench_ufunc.Methods0DInvert.time_ndarray__0d__('int32') |
| + | 400±6ns | 435±10ns | 1.09 | bench_ufunc.MethodsV0.time_ndarray_meth('__neg__', 'complex128') |
| + | 383±2ns | 419±40ns | 1.09 | bench_ufunc.MethodsV0.time_ndarray_meth('__neg__', 'complex64') |
| + | 397±2ns | 431±2ns | 1.09 | bench_ufunc.MethodsV0.time_ndarray_meth('__pos__', 'complex128') |
| + | 454±5ns | 496±5ns | 1.09 | bench_ufunc.MethodsV1.time_ndarray_meth('__eq__', 'float16') |
| + | 433±6ns | 472±5ns | 1.09 | bench_ufunc.MethodsV1.time_ndarray_meth('__gt__', 'complex128') |
| + | 412±3ns | 450±3ns | 1.09 | bench_ufunc.MethodsV1.time_ndarray_meth('__le__', 'complex128') |
| + | 469±4ns | 512±10ns | 1.09 | bench_ufunc.MethodsV1.time_ndarray_meth('__le__', 'float16') |
| + | 408±5ns | 446±4ns | 1.09 | bench_ufunc.MethodsV1.time_ndarray_meth('__lt__', 'complex64') |
| + | 598±4ns | 651±20ns | 1.09 | bench_ufunc.MethodsV1.time_ndarray_meth('__matmul__', 'complex128') |
| + | 592±6ns | 643±10ns | 1.09 | bench_ufunc.MethodsV1.time_ndarray_meth('__matmul__', 'int64') |
| + | 365±5ns | 398±2ns | 1.09 | bench_ufunc.MethodsV1.time_ndarray_meth('__mul__', 'complex64') |
| + | 343±3ns | 375±4ns | 1.09 | bench_ufunc.MethodsV1.time_ndarray_meth('__mul__', 'int32') |
| + | 348±10ns | 380±10ns | 1.09 | bench_ufunc.MethodsV1.time_ndarray_meth('__ne__', 'int16') |
| + | 348±5ns | 379±7ns | 1.09 | bench_ufunc.MethodsV1IntOnly.time_ndarray_meth('__and__', 'int16') |
| + | 417±1ns | 457±4ns | 1.09 | bench_ufunc.MethodsV1NoComplex.time_ndarray_meth('__floordiv__', 'int32') |
| + | 427±6ns | 466±8ns | 1.09 | bench_ufunc.MethodsV1NoComplex.time_ndarray_meth('__mod__', 'int16') |
| + | 376±4ns | 410±7ns | 1.09 | bench_ufunc.UFuncSmall.time_ufunc_numpy_scalar('abs') |
| + | 367±3ns | 401±2ns | 1.09 | bench_ufunc.UFuncSmall.time_ufunc_numpy_scalar('cos') |
| + | 627±4ns | 676±30ns | 1.08 | bench_ufunc.ArgParsingReduce.time_add_reduce_arg_parsing((array([0., 1.]))) |
| + | 643±5ns | 694±4ns | 1.08 | bench_ufunc.Custom.time_and_bool |
| + | 384±3ns | 416±4ns | 1.08 | bench_ufunc.CustomArrayFloorDivideInt.time_floor_divide_int(<class 'numpy.int8'>, 100) |
| + | 319±3ns | 345±4ns | 1.08 | bench_ufunc.MethodsV0.time_ndarray_meth('__neg__', 'float16') |
| + | 379±4ns | 410±7ns | 1.08 | bench_ufunc.MethodsV0.time_ndarray_meth('__pos__', 'complex64') |
| + | 431±6ns | 467±8ns | 1.08 | bench_ufunc.MethodsV1.time_ndarray_meth('__ge__', 'complex64') |
| + | 370±2ns | 400±5ns | 1.08 | bench_ufunc.MethodsV1.time_ndarray_meth('__ne__', 'float32') |
| + | 344±1ns | 372±6ns | 1.08 | bench_ufunc.MethodsV1.time_ndarray_meth('__ne__', 'int32') |
| + | 452±8ns | 489±4ns | 1.08 | bench_ufunc.MethodsV1.time_ndarray_meth('__truediv__', 'complex128') |
| + | 421±3ns | 453±6ns | 1.07 | bench_ufunc.ArgParsing.time_add_arg_parsing((array(1.), array(2.), subok=True, where=True)) |
| + | 481±8ns | 514±4ns | 1.07 | bench_ufunc.Custom.time_not_bool |
| + | 304±10ns | 326±3ns | 1.07 | bench_ufunc.Methods0DInvert.time_ndarray__0d__('int16') |
| + | 443±4ns | 472±5ns | 1.07 | bench_ufunc.MethodsV0.time_ndarray_meth('__abs__', 'complex64') |
| + | 590±9ns | 634±10ns | 1.07 | bench_ufunc.MethodsV1.time_ndarray_meth('__matmul__', 'float64') |
| + | 734±7ns | 783±6ns | 1.07 | bench_ufunc.MethodsV1.time_ndarray_meth('__pow__', 'float32') |
| + | 580±7ns | 623±2ns | 1.07 | bench_ufunc.MethodsV1.time_ndarray_meth('__pow__', 'int32') |
| + | 579±8ns | 621±9ns | 1.07 | bench_ufunc.MethodsV1.time_ndarray_meth('__pow__', 'int64') |
| + | 429±5ns | 461±4ns | 1.07 | bench_ufunc.MethodsV1NoComplex.time_ndarray_meth('__floordiv__', 'int64') |
| + | 643±3ns | 679±5ns | 1.06 | bench_ufunc.ArgParsingReduce.time_add_reduce_arg_parsing((array([0., 1.]), 0, None)) |
| + | 615±6ns | 654±6ns | 1.06 | bench_ufunc.ArgParsingReduce.time_add_reduce_arg_parsing((array([0., 1.]), out=array(0.))) |
| + | 563±6ns | 597±10ns | 1.06 | bench_ufunc.Custom.time_or_bool |
| + | 1.51±0.01μs | 1.59±0.02μs | 1.06 | bench_ufunc.CustomComparison.time_less_than_scalar1(<class 'numpy.uint8'>) |
| + | 484±6ns | 511±6ns | 1.06 | bench_ufunc.MethodsV0.time_ndarray_meth('__abs__', 'complex128') |
| + | 579±4ns | 611±9ns | 1.06 | bench_ufunc.MethodsV1.time_ndarray_meth('__pow__', 'int16') |
| + | 742±8ns | 783±10ns | 1.06 | bench_ufunc.MethodsV1NoComplex.time_ndarray_meth('__floordiv__', 'float64') |
| + | 748±20ns | 793±10ns | 1.06 | bench_ufunc.MethodsV1NoComplex.time_ndarray_meth('__mod__', 'float64') |
| + | 41.6±0.3μs | 44.1±0.5μs | 1.06 | bench_ufunc.UFunc.time_ufunc_types('logical_not') |
| + | 572±4ns | 602±7ns | 1.05 | bench_ufunc.ArgParsingReduce.time_add_reduce_arg_parsing((array([0., 1.]), 0, None, array(0.))) |
| + | 1.70±0.03μs | 1.79±0.03μs | 1.05 | bench_ufunc.CustomComparison.time_less_than_scalar2(<class 'numpy.int16'>) |
| + | 482±5ns | 507±6ns | 1.05 | bench_ufunc.MethodsV1.time_ndarray_meth('__lt__', 'float16') |
| + | 992±5ns | 1.04±0.01μs | 1.05 | bench_ufunc.MethodsV1.time_ndarray_meth('__pow__', 'float64') |
| - | 1.38±0.01ms | 1.29±0.05ms | 0.93 | bench_ufunc.CustomArrayFloorDivideInt.time_floor_divide_int(<class 'numpy.int64'>, 1000000) |
| - | 6.68±0.9μs | 6.11±0.01μs | 0.91 | bench_ufunc.CustomArrayFloorDivideInt.time_floor_divide_int(<class 'numpy.uint32'>, 10000) |
| - | 4.83±0.01μs | 4.38±0.03μs | 0.91 | bench_ufunc.NDArrayAsType.time_astype(('int16', 'complex64')) |
| Change | Before [12aa98e0] <main> | After [e94ed561] <nogil-pymutex-lock> | Ratio | Benchmark (Parameter) |
|----------|----------------------------|-----------------------------------------|---------|-----------------------------------------------------------------------------|
| + | 1.74±0.03μs | 2.41±0.01μs | 1.39 | bench_ufunc.CustomComparison.time_less_than_scalar1(<class 'numpy.uint16'>) |
| + | 143±3μs | 160±3μs | 1.13 | bench_ufunc.UFunc.time_ufunc_types('nextafter') |
| + | 3.53±0.03μs | 3.85±0.3μs | 1.09 | bench_ufunc.NDArrayAsType.time_astype(('float64', 'complex128')) |
| - | 71.5±1μs | 67.9±0.8μs | 0.95 | bench_ufunc.UFunc.time_ufunc_types('logical_and') |
| - | 163±10ns | 152±0.9ns | 0.93 | bench_ufunc.DLPMethods.time_ndarray_dlp('__dlpack__', 'float16') |
| - | 203±3μs | 187±1μs | 0.92 | bench_ufunc.UFunc.time_ufunc_types('divmod') |
| Change | Before [12aa98e0] <main> | After [8f5b0c5d] <nogil-pythreadtype-lock> | Ratio | Benchmark (Parameter) |
|----------|----------------------------|----------------------------------------------|---------|--------------------------------------------------------------------------------------------------------|
| + | 41.6±0.3μs | 47.2±0.4μs | 1.13 | bench_ufunc.UFunc.time_ufunc_types('logical_not') |
| + | 361±5ns | 396±20ns | 1.09 | bench_ufunc.MethodsV1.time_ndarray_meth('__gt__', 'float64') |
| + | 346±3ns | 373±6ns | 1.08 | bench_ufunc.MethodsV1.time_ndarray_meth('__add__', 'int64') |
| + | 371±5ns | 403±30ns | 1.08 | bench_ufunc.MethodsV1.time_ndarray_meth('__eq__', 'complex64') |
| + | 340±6ns | 366±4ns | 1.08 | bench_ufunc.MethodsV1.time_ndarray_meth('__le__', 'int64') |
| + | 257±1ns | 279±4ns | 1.08 | bench_ufunc.UFuncSmall.time_ufunc_small_array('cos') |
| + | 333±9ns | 355±4ns | 1.07 | bench_ufunc.ArgParsing.time_add_arg_parsing((array(1.), array(2.), out=array(3.))) |
| + | 334±9ns | 356±7ns | 1.07 | bench_ufunc.CustomArrayFloorDivideInt.time_floor_divide_int(<class 'numpy.uint16'>, 100) |
| + | 287±3ns | 308±3ns | 1.07 | bench_ufunc.MethodsV0.time_ndarray_meth('__abs__', 'int16') |
| + | 289±2ns | 308±4ns | 1.07 | bench_ufunc.MethodsV0.time_ndarray_meth('__neg__', 'float32') |
| + | 287±3ns | 306±4ns | 1.07 | bench_ufunc.MethodsV0.time_ndarray_meth('__pos__', 'int32') |
| + | 338±5ns | 363±9ns | 1.07 | bench_ufunc.MethodsV1.time_ndarray_meth('__ne__', 'int32') |
| + | 331±3ns | 354±4ns | 1.07 | bench_ufunc.MethodsV1.time_ndarray_meth('__truediv__', 'float32') |
| + | 229±2ns | 244±6ns | 1.07 | bench_ufunc.UFuncSmall.time_ufunc_small_array_inplace('cos') |
| + | 242±2ns | 257±1ns | 1.06 | bench_ufunc.Custom.time_and_bool_small |
| + | 383±3ns | 404±6ns | 1.06 | bench_ufunc.CustomArrayFloorDivideInt.time_floor_divide_int(<class 'numpy.int8'>, 100) |
| + | 292±3ns | 310±4ns | 1.06 | bench_ufunc.MethodsV0.time_ndarray_meth('__abs__', 'float16') |
| + | 282±5ns | 300±4ns | 1.06 | bench_ufunc.MethodsV0.time_ndarray_meth('__neg__', 'int16') |
| + | 430±4ns | 455±3ns | 1.06 | bench_ufunc.MethodsV1.time_ndarray_meth('__ge__', 'complex128') |
| + | 331±4ns | 351±3ns | 1.06 | bench_ufunc.MethodsV1.time_ndarray_meth('__le__', 'int16') |
| + | 366±8ns | 386±6ns | 1.06 | bench_ufunc.MethodsV1.time_ndarray_meth('__lt__', 'float32') |
| + | 382±6ns | 405±3ns | 1.06 | bench_ufunc.MethodsV1.time_ndarray_meth('__mul__', 'complex128') |
| + | 343±2ns | 364±9ns | 1.06 | bench_ufunc.MethodsV1.time_ndarray_meth('__mul__', 'float32') |
| + | 344±4ns | 365±2ns | 1.06 | bench_ufunc.MethodsV1.time_ndarray_meth('__sub__', 'float64') |
| + | 424±5ns | 448±7ns | 1.06 | bench_ufunc.MethodsV1NoComplex.time_ndarray_meth('__mod__', 'int32') |
| + | 655±7ns | 695±8ns | 1.06 | bench_ufunc.NDArrayLRShifts.time_ndarray_meth('__lshift__', 'int64') |
| + | 244±3ns | 259±4ns | 1.06 | bench_ufunc.UFuncSmall.time_ufunc_small_array('sqrt') |
| + | 248±2ns | 262±2ns | 1.06 | bench_ufunc.UFuncSmall.time_ufunc_small_int_array('abs') |
| + | 363±5ns | 382±5ns | 1.05 | bench_ufunc.ArgParsing.time_add_arg_parsing((array(1.), array(2.), array(3.), subok=True, where=True)) |
| + | 375±4ns | 395±3ns | 1.05 | bench_ufunc.CustomArrayFloorDivideInt.time_floor_divide_int(<class 'numpy.int32'>, 100) |
| + | 393±4ns | 413±3ns | 1.05 | bench_ufunc.MethodsV0.time_ndarray_meth('__neg__', 'complex128') |
| + | 315±1ns | 331±4ns | 1.05 | bench_ufunc.MethodsV0.time_ndarray_meth('__neg__', 'float16') |
| + | 342±6ns | 360±3ns | 1.05 | bench_ufunc.MethodsV1.time_ndarray_meth('__eq__', 'int64') |
| + | 359±3ns | 378±3ns | 1.05 | bench_ufunc.MethodsV1.time_ndarray_meth('__le__', 'float64') |
| + | 348±1ns | 366±2ns | 1.05 | bench_ufunc.MethodsV1.time_ndarray_meth('__mul__', 'float64') |
| + | 357±5ns | 375±2ns | 1.05 | bench_ufunc.MethodsV1.time_ndarray_meth('__ne__', 'float64') |
| + | 577±4ns | 608±6ns | 1.05 | bench_ufunc.MethodsV1.time_ndarray_meth('__pow__', 'int32') |
| + | 350±2ns | 368±3ns | 1.05 | bench_ufunc.MethodsV1.time_ndarray_meth('__sub__', 'complex64') |
| + | 409±9ns | 431±4ns | 1.05 | bench_ufunc.MethodsV1NoComplex.time_ndarray_meth('__floordiv__', 'int16') |
| - | 4.11±0.06μs | 3.71±0.04μs | 0.9 | bench_ufunc.NDArrayAsType.time_astype(('int16', 'float64')) |
SOME BENCHMARKS HAVE CHANGED SIGNIFICANTLY.
PERFORMANCE DECREASED.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment